Module: xenomai-3
Branch: master
Commit: 148d54ff859d60174f5f676fb84c38ed3040d154
URL:    
http://git.xenomai.org/?p=xenomai-3.git;a=commit;h=148d54ff859d60174f5f676fb84c38ed3040d154

Author: Gilles Chanteperdrix <gilles.chanteperd...@xenomai.org>
Date:   Fri Oct 31 09:00:09 2014 +0100

cobalt/spinlocks: remove dead code

---

 include/cobalt/kernel/lock.h |    9 ---------
 kernel/cobalt/debug.c        |   27 ---------------------------
 2 files changed, 36 deletions(-)

diff --git a/include/cobalt/kernel/lock.h b/include/cobalt/kernel/lock.h
index e590b85..36f8168 100644
--- a/include/cobalt/kernel/lock.h
+++ b/include/cobalt/kernel/lock.h
@@ -102,10 +102,6 @@ struct xnlockinfo {
 
 void xnlock_dbg_prepare_acquire(unsigned long long *start);
 void xnlock_dbg_prepare_spin(unsigned int *spin_limit);
-void xnlock_dbg_spinning(struct xnlock *lock, int cpu,
-                        unsigned int *spin_limit,
-                        const char *file, int line,
-                        const char *function);
 void xnlock_dbg_acquired(struct xnlock *lock, int cpu,
                         unsigned long long *start,
                         const char *file, int line,
@@ -144,11 +140,6 @@ void xnlock_dbg_prepare_spin(unsigned int *spin_limit)
 }
 
 static inline void
-xnlock_dbg_spinning(struct xnlock *lock, int cpu, unsigned int *spin_limit)
-{
-}
-
-static inline void
 xnlock_dbg_acquired(struct xnlock *lock, int cpu,
                    unsigned long long *start)
 {
diff --git a/kernel/cobalt/debug.c b/kernel/cobalt/debug.c
index ef46e0b..5783b0c 100644
--- a/kernel/cobalt/debug.c
+++ b/kernel/cobalt/debug.c
@@ -536,39 +536,12 @@ static inline void init_thread_relax_trace(struct 
xnthread *thread)
 
 #if XENO_DEBUG(LOCKING)
 
-#define XNLOCK_DBG_MAX_SPINS           10000000
-
 void xnlock_dbg_prepare_acquire(unsigned long long *start)
 {
        *start = xnclock_read_raw(&nkclock);
 }
 EXPORT_SYMBOL_GPL(xnlock_dbg_prepare_acquire);
 
-void xnlock_dbg_prepare_spin(unsigned *spin_limit)
-{
-       *spin_limit = XNLOCK_DBG_MAX_SPINS;
-}
-EXPORT_SYMBOL_GPL(xnlock_dbg_prepare_spin);
-
-void xnlock_dbg_spinning(struct xnlock *lock, int cpu,
-                        unsigned int *spin_limit,
-                        const char *file, int line, const char *function)
-{
-       if (--*spin_limit == 0) {
-               ipipe_prepare_panic();
-               printk(XENO_ERR "stuck on lock %p\n"
-                               "           waiter = %s:%u (%s(), CPU #%d)\n"
-                               "           owner  = %s:%u (%s(), CPU #%d)\n",
-                      lock, file, line, function, cpu,
-                      lock->file, lock->line, lock->function, lock->cpu);
-               show_stack(NULL, NULL);
-#ifndef CONFIG_SMP
-               BUG();
-#endif
-       }
-}
-EXPORT_SYMBOL_GPL(xnlock_dbg_spinning);
-
 void xnlock_dbg_acquired(struct xnlock *lock, int cpu, unsigned long long 
*start,
                         const char *file, int line, const char *function)
 {


_______________________________________________
Xenomai-git mailing list
Xenomai-git@xenomai.org
http://www.xenomai.org/mailman/listinfo/xenomai-git

Reply via email to