mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2024-12-26 19:19:32 +03:00
Check for changed gaurd macro in 2.6.28+ for rwsem implementation.
As part of the 2.6.28 cleanup which moved all the linux/include/asm/ headers in to linux/arch, the guard headers for many header files changed. The i386 rwsem implementation keys off this header to ensure the internal members of the rwsem structure are interpreted correctly. This change checks for the new guard macro in addition to the only one, the implementation of the rwsem has not changed for i386 so this is safe and correct.
This commit is contained in:
parent
242f539a2e
commit
3a03ce5cbf
@ -64,7 +64,11 @@ typedef struct {
|
||||
extern void __up_read_locked(struct rw_semaphore *);
|
||||
extern int __down_write_trylock_locked(struct rw_semaphore *);
|
||||
#else
|
||||
# ifdef _I386_RWSEM_H
|
||||
/*
|
||||
* 2.6.x - 2.6.27 use guard macro _I386_RWSEM_H
|
||||
* 2.6.28 - 2.6.32+ use guard macro _ASM_X86_RWSEM_H
|
||||
*/
|
||||
# if defined(_I386_RWSEM_H) || defined(_ASM_X86_RWSEM_H)
|
||||
# define RW_COUNT(rwp) ((SEM(rwp)->count < 0) ? (-1) : \
|
||||
(SEM(rwp)->count & RWSEM_ACTIVE_MASK))
|
||||
# else
|
||||
|
Loading…
Reference in New Issue
Block a user