Re: [patch 1/8] mutex subsystem, XFS namespace collision fixes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Dec 21, 2005 at 11:36:56PM +0100, Ingo Molnar wrote:
> Fixup the XFS code to avoid name clashing with the mutex code by 
> introducing xfs_mutex_ functions.
...
> --- linux.orig/fs/xfs/linux-2.6/mutex.h
> +++ linux/fs/xfs/linux-2.6/mutex.h
> @@ -30,10 +30,10 @@
>  #define MUTEX_DEFAULT		0x0
>  typedef struct semaphore	mutex_t;
>  
> -#define mutex_init(lock, type, name)		sema_init(lock, 1)
> -#define mutex_destroy(lock)			sema_init(lock, -99)
> -#define mutex_lock(lock, num)			down(lock)
> -#define mutex_trylock(lock)			(down_trylock(lock) ? 0 : 1)
> -#define mutex_unlock(lock)			up(lock)
> +#define xfs_mutex_init(lock, type, name)	arch_sema_init(lock, 1)
> +#define xfs_mutex_destroy(lock)			arch_sema_init(lock, -99)
> +#define xfs_mutex_lock(lock, num)		arch_down(lock)
> +#define xfs_mutex_trylock(lock)			(arch_down_trylock(lock) ? 0 : 1)
> +#define xfs_mutex_unlock(lock)			arch_up(lock)

This arch_ prefix seems to be a leftover from the migration helper patches?

Johannes
-
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/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux