Re: [PATCH -rt 6/9] spinlock/rt_lock random cleanups
On Mon, 2007-07-30 at 10:28 +0530, Ankita Garg wrote: > On Sun, Jul 29, 2007 at 07:45:40PM -0700, Daniel Walker wrote: > > Signed-off-by: Daniel Walker <[EMAIL PROTECTED]> > > > > --- > > include/linux/rt_lock.h |6 -- > > include/linux/spinlock.h |5 +++-- > > 2 files changed, 7 insertions(+), 4 deletions(-) > > > > Index: linux-2.6.22/include/linux/rt_lock.h > > === > > --- linux-2.6.22.orig/include/linux/rt_lock.h > > +++ linux-2.6.22/include/linux/rt_lock.h > > @@ -128,12 +128,14 @@ struct semaphore name = \ > > */ > > #define DECLARE_MUTEX_LOCKED COMPAT_DECLARE_MUTEX_LOCKED > > > > -extern void fastcall __sema_init(struct semaphore *sem, int val, char > > *name, char *file, int line); > > +extern void fastcall > > +__sema_init(struct semaphore *sem, int val, char *name, char *file, int > > line); > > > > #define rt_sema_init(sem, val) \ > > __sema_init(sem, val, #sem, __FILE__, __LINE__) > > > > -extern void fastcall __init_MUTEX(struct semaphore *sem, char *name, char > > *file, int line); > > +extern void fastcall > > +__init_MUTEX(struct semaphore *sem, char *name, char *file, int line); > > #define rt_init_MUTEX(sem) \ > > __init_MUTEX(sem, #sem, __FILE__, __LINE__) > > > > Index: linux-2.6.22/include/linux/spinlock.h > > === > > --- linux-2.6.22.orig/include/linux/spinlock.h > > +++ linux-2.6.22/include/linux/spinlock.h > > @@ -126,7 +126,7 @@ extern int __lockfunc generic__raw_read_ > > > > #ifdef CONFIG_DEBUG_SPINLOCK > > extern __lockfunc void _raw_spin_lock(raw_spinlock_t *lock); > > -#define _raw_spin_lock_flags(lock, flags) _raw_spin_lock(lock) > > +# define _raw_spin_lock_flags(lock, flags) _raw_spin_lock(lock) > > Any reason behind including a space here? Yes . Sometimes a space is added when a define is embedded inside #ifdefs , example below. #ifdef CONFIG_DEBUG_SPINLOCK # define DEBUG_MACRO do_somedebug_here() #endif That's usually the method Ingo uses, and it matches the code surrounding it in this particular patch. Daniel - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Re: [PATCH -rt 6/9] spinlock/rt_lock random cleanups
* Daniel Walker <[EMAIL PROTECTED]> wrote: > spinlock/rt_lock random cleanups thanks, applied. Ingo - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Re: [PATCH -rt 6/9] spinlock/rt_lock random cleanups
* Daniel Walker [EMAIL PROTECTED] wrote: spinlock/rt_lock random cleanups thanks, applied. Ingo - To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Re: [PATCH -rt 6/9] spinlock/rt_lock random cleanups
On Mon, 2007-07-30 at 10:28 +0530, Ankita Garg wrote: On Sun, Jul 29, 2007 at 07:45:40PM -0700, Daniel Walker wrote: Signed-off-by: Daniel Walker [EMAIL PROTECTED] --- include/linux/rt_lock.h |6 -- include/linux/spinlock.h |5 +++-- 2 files changed, 7 insertions(+), 4 deletions(-) Index: linux-2.6.22/include/linux/rt_lock.h === --- linux-2.6.22.orig/include/linux/rt_lock.h +++ linux-2.6.22/include/linux/rt_lock.h @@ -128,12 +128,14 @@ struct semaphore name = \ */ #define DECLARE_MUTEX_LOCKED COMPAT_DECLARE_MUTEX_LOCKED -extern void fastcall __sema_init(struct semaphore *sem, int val, char *name, char *file, int line); +extern void fastcall +__sema_init(struct semaphore *sem, int val, char *name, char *file, int line); #define rt_sema_init(sem, val) \ __sema_init(sem, val, #sem, __FILE__, __LINE__) -extern void fastcall __init_MUTEX(struct semaphore *sem, char *name, char *file, int line); +extern void fastcall +__init_MUTEX(struct semaphore *sem, char *name, char *file, int line); #define rt_init_MUTEX(sem) \ __init_MUTEX(sem, #sem, __FILE__, __LINE__) Index: linux-2.6.22/include/linux/spinlock.h === --- linux-2.6.22.orig/include/linux/spinlock.h +++ linux-2.6.22/include/linux/spinlock.h @@ -126,7 +126,7 @@ extern int __lockfunc generic__raw_read_ #ifdef CONFIG_DEBUG_SPINLOCK extern __lockfunc void _raw_spin_lock(raw_spinlock_t *lock); -#define _raw_spin_lock_flags(lock, flags) _raw_spin_lock(lock) +# define _raw_spin_lock_flags(lock, flags) _raw_spin_lock(lock) Any reason behind including a space here? Yes . Sometimes a space is added when a define is embedded inside #ifdefs , example below. #ifdef CONFIG_DEBUG_SPINLOCK # define DEBUG_MACRO do_somedebug_here() #endif That's usually the method Ingo uses, and it matches the code surrounding it in this particular patch. Daniel - To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Re: [PATCH -rt 6/9] spinlock/rt_lock random cleanups
On Sun, Jul 29, 2007 at 07:45:40PM -0700, Daniel Walker wrote: > Signed-off-by: Daniel Walker <[EMAIL PROTECTED]> > > --- > include/linux/rt_lock.h |6 -- > include/linux/spinlock.h |5 +++-- > 2 files changed, 7 insertions(+), 4 deletions(-) > > Index: linux-2.6.22/include/linux/rt_lock.h > === > --- linux-2.6.22.orig/include/linux/rt_lock.h > +++ linux-2.6.22/include/linux/rt_lock.h > @@ -128,12 +128,14 @@ struct semaphore name = \ > */ > #define DECLARE_MUTEX_LOCKED COMPAT_DECLARE_MUTEX_LOCKED > > -extern void fastcall __sema_init(struct semaphore *sem, int val, char *name, > char *file, int line); > +extern void fastcall > +__sema_init(struct semaphore *sem, int val, char *name, char *file, int > line); > > #define rt_sema_init(sem, val) \ > __sema_init(sem, val, #sem, __FILE__, __LINE__) > > -extern void fastcall __init_MUTEX(struct semaphore *sem, char *name, char > *file, int line); > +extern void fastcall > +__init_MUTEX(struct semaphore *sem, char *name, char *file, int line); > #define rt_init_MUTEX(sem) \ > __init_MUTEX(sem, #sem, __FILE__, __LINE__) > > Index: linux-2.6.22/include/linux/spinlock.h > === > --- linux-2.6.22.orig/include/linux/spinlock.h > +++ linux-2.6.22/include/linux/spinlock.h > @@ -126,7 +126,7 @@ extern int __lockfunc generic__raw_read_ > > #ifdef CONFIG_DEBUG_SPINLOCK > extern __lockfunc void _raw_spin_lock(raw_spinlock_t *lock); > -#define _raw_spin_lock_flags(lock, flags) _raw_spin_lock(lock) > +# define _raw_spin_lock_flags(lock, flags) _raw_spin_lock(lock) Any reason behind including a space here? > extern __lockfunc int _raw_spin_trylock(raw_spinlock_t *lock); > extern __lockfunc void _raw_spin_unlock(raw_spinlock_t *lock); > extern __lockfunc void _raw_read_lock(raw_rwlock_t *lock); > @@ -325,7 +325,8 @@ do { > \ > > # define _read_trylock(rwl) rt_read_trylock(rwl) > # define _write_trylock(rwl) rt_write_trylock(rwl) > -#define _write_trylock_irqsave(rwl, flags) rt_write_trylock_irqsave(rwl, > flags) > +# define _write_trylock_irqsave(rwl, flags) \ > + rt_write_trylock_irqsave(rwl, flags) > > # define _read_lock(rwl) rt_read_lock(rwl) > # define _write_lock(rwl)rt_write_lock(rwl) > -- Regards, Ankita Garg ([EMAIL PROTECTED]) Linux Technology Center IBM India Systems & Technology Labs, Bangalore, India - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[PATCH -rt 6/9] spinlock/rt_lock random cleanups
Signed-off-by: Daniel Walker <[EMAIL PROTECTED]> --- include/linux/rt_lock.h |6 -- include/linux/spinlock.h |5 +++-- 2 files changed, 7 insertions(+), 4 deletions(-) Index: linux-2.6.22/include/linux/rt_lock.h === --- linux-2.6.22.orig/include/linux/rt_lock.h +++ linux-2.6.22/include/linux/rt_lock.h @@ -128,12 +128,14 @@ struct semaphore name = \ */ #define DECLARE_MUTEX_LOCKED COMPAT_DECLARE_MUTEX_LOCKED -extern void fastcall __sema_init(struct semaphore *sem, int val, char *name, char *file, int line); +extern void fastcall +__sema_init(struct semaphore *sem, int val, char *name, char *file, int line); #define rt_sema_init(sem, val) \ __sema_init(sem, val, #sem, __FILE__, __LINE__) -extern void fastcall __init_MUTEX(struct semaphore *sem, char *name, char *file, int line); +extern void fastcall +__init_MUTEX(struct semaphore *sem, char *name, char *file, int line); #define rt_init_MUTEX(sem) \ __init_MUTEX(sem, #sem, __FILE__, __LINE__) Index: linux-2.6.22/include/linux/spinlock.h === --- linux-2.6.22.orig/include/linux/spinlock.h +++ linux-2.6.22/include/linux/spinlock.h @@ -126,7 +126,7 @@ extern int __lockfunc generic__raw_read_ #ifdef CONFIG_DEBUG_SPINLOCK extern __lockfunc void _raw_spin_lock(raw_spinlock_t *lock); -#define _raw_spin_lock_flags(lock, flags) _raw_spin_lock(lock) +# define _raw_spin_lock_flags(lock, flags) _raw_spin_lock(lock) extern __lockfunc int _raw_spin_trylock(raw_spinlock_t *lock); extern __lockfunc void _raw_spin_unlock(raw_spinlock_t *lock); extern __lockfunc void _raw_read_lock(raw_rwlock_t *lock); @@ -325,7 +325,8 @@ do { \ # define _read_trylock(rwl)rt_read_trylock(rwl) # define _write_trylock(rwl) rt_write_trylock(rwl) -#define _write_trylock_irqsave(rwl, flags) rt_write_trylock_irqsave(rwl, flags) +# define _write_trylock_irqsave(rwl, flags) \ + rt_write_trylock_irqsave(rwl, flags) # define _read_lock(rwl) rt_read_lock(rwl) # define _write_lock(rwl) rt_write_lock(rwl) -- - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[PATCH -rt 6/9] spinlock/rt_lock random cleanups
Signed-off-by: Daniel Walker [EMAIL PROTECTED] --- include/linux/rt_lock.h |6 -- include/linux/spinlock.h |5 +++-- 2 files changed, 7 insertions(+), 4 deletions(-) Index: linux-2.6.22/include/linux/rt_lock.h === --- linux-2.6.22.orig/include/linux/rt_lock.h +++ linux-2.6.22/include/linux/rt_lock.h @@ -128,12 +128,14 @@ struct semaphore name = \ */ #define DECLARE_MUTEX_LOCKED COMPAT_DECLARE_MUTEX_LOCKED -extern void fastcall __sema_init(struct semaphore *sem, int val, char *name, char *file, int line); +extern void fastcall +__sema_init(struct semaphore *sem, int val, char *name, char *file, int line); #define rt_sema_init(sem, val) \ __sema_init(sem, val, #sem, __FILE__, __LINE__) -extern void fastcall __init_MUTEX(struct semaphore *sem, char *name, char *file, int line); +extern void fastcall +__init_MUTEX(struct semaphore *sem, char *name, char *file, int line); #define rt_init_MUTEX(sem) \ __init_MUTEX(sem, #sem, __FILE__, __LINE__) Index: linux-2.6.22/include/linux/spinlock.h === --- linux-2.6.22.orig/include/linux/spinlock.h +++ linux-2.6.22/include/linux/spinlock.h @@ -126,7 +126,7 @@ extern int __lockfunc generic__raw_read_ #ifdef CONFIG_DEBUG_SPINLOCK extern __lockfunc void _raw_spin_lock(raw_spinlock_t *lock); -#define _raw_spin_lock_flags(lock, flags) _raw_spin_lock(lock) +# define _raw_spin_lock_flags(lock, flags) _raw_spin_lock(lock) extern __lockfunc int _raw_spin_trylock(raw_spinlock_t *lock); extern __lockfunc void _raw_spin_unlock(raw_spinlock_t *lock); extern __lockfunc void _raw_read_lock(raw_rwlock_t *lock); @@ -325,7 +325,8 @@ do { \ # define _read_trylock(rwl)rt_read_trylock(rwl) # define _write_trylock(rwl) rt_write_trylock(rwl) -#define _write_trylock_irqsave(rwl, flags) rt_write_trylock_irqsave(rwl, flags) +# define _write_trylock_irqsave(rwl, flags) \ + rt_write_trylock_irqsave(rwl, flags) # define _read_lock(rwl) rt_read_lock(rwl) # define _write_lock(rwl) rt_write_lock(rwl) -- - To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Re: [PATCH -rt 6/9] spinlock/rt_lock random cleanups
On Sun, Jul 29, 2007 at 07:45:40PM -0700, Daniel Walker wrote: Signed-off-by: Daniel Walker [EMAIL PROTECTED] --- include/linux/rt_lock.h |6 -- include/linux/spinlock.h |5 +++-- 2 files changed, 7 insertions(+), 4 deletions(-) Index: linux-2.6.22/include/linux/rt_lock.h === --- linux-2.6.22.orig/include/linux/rt_lock.h +++ linux-2.6.22/include/linux/rt_lock.h @@ -128,12 +128,14 @@ struct semaphore name = \ */ #define DECLARE_MUTEX_LOCKED COMPAT_DECLARE_MUTEX_LOCKED -extern void fastcall __sema_init(struct semaphore *sem, int val, char *name, char *file, int line); +extern void fastcall +__sema_init(struct semaphore *sem, int val, char *name, char *file, int line); #define rt_sema_init(sem, val) \ __sema_init(sem, val, #sem, __FILE__, __LINE__) -extern void fastcall __init_MUTEX(struct semaphore *sem, char *name, char *file, int line); +extern void fastcall +__init_MUTEX(struct semaphore *sem, char *name, char *file, int line); #define rt_init_MUTEX(sem) \ __init_MUTEX(sem, #sem, __FILE__, __LINE__) Index: linux-2.6.22/include/linux/spinlock.h === --- linux-2.6.22.orig/include/linux/spinlock.h +++ linux-2.6.22/include/linux/spinlock.h @@ -126,7 +126,7 @@ extern int __lockfunc generic__raw_read_ #ifdef CONFIG_DEBUG_SPINLOCK extern __lockfunc void _raw_spin_lock(raw_spinlock_t *lock); -#define _raw_spin_lock_flags(lock, flags) _raw_spin_lock(lock) +# define _raw_spin_lock_flags(lock, flags) _raw_spin_lock(lock) Any reason behind including a space here? extern __lockfunc int _raw_spin_trylock(raw_spinlock_t *lock); extern __lockfunc void _raw_spin_unlock(raw_spinlock_t *lock); extern __lockfunc void _raw_read_lock(raw_rwlock_t *lock); @@ -325,7 +325,8 @@ do { \ # define _read_trylock(rwl) rt_read_trylock(rwl) # define _write_trylock(rwl) rt_write_trylock(rwl) -#define _write_trylock_irqsave(rwl, flags) rt_write_trylock_irqsave(rwl, flags) +# define _write_trylock_irqsave(rwl, flags) \ + rt_write_trylock_irqsave(rwl, flags) # define _read_lock(rwl) rt_read_lock(rwl) # define _write_lock(rwl)rt_write_lock(rwl) -- Regards, Ankita Garg ([EMAIL PROTECTED]) Linux Technology Center IBM India Systems Technology Labs, Bangalore, India - To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/