Commit 28a5ae65 authored by Andrew Morton's avatar Andrew Morton Committed by james toy

simplify

Cc: Amerigo Wang <amwang@redhat.com>
Cc: Ben Woodard <bwoodard@llnl.gov>
Cc: Brian Behlendorf <behlendorf1@llnl.gov>
Cc: David Howells <dhowells@redhat.com>
Cc: WANG Cong <amwang@redhat.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
parent d2ce5671
...@@ -68,9 +68,7 @@ extern int __down_write_trylock(struct rw_semaphore *sem); ...@@ -68,9 +68,7 @@ extern int __down_write_trylock(struct rw_semaphore *sem);
extern void __up_read(struct rw_semaphore *sem); extern void __up_read(struct rw_semaphore *sem);
extern void __up_write(struct rw_semaphore *sem); extern void __up_write(struct rw_semaphore *sem);
extern void __downgrade_write(struct rw_semaphore *sem); extern void __downgrade_write(struct rw_semaphore *sem);
extern int __rwsem_is_locked(struct rw_semaphore *sem); extern int rwsem_is_locked(struct rw_semaphore *sem);
#define rwsem_is_locked(sem) __rwsem_is_locked(sem)
#endif /* __KERNEL__ */ #endif /* __KERNEL__ */
#endif /* _LINUX_RWSEM_SPINLOCK_H */ #endif /* _LINUX_RWSEM_SPINLOCK_H */
...@@ -17,7 +17,7 @@ struct rwsem_waiter { ...@@ -17,7 +17,7 @@ struct rwsem_waiter {
#define RWSEM_WAITING_FOR_WRITE 0x00000002 #define RWSEM_WAITING_FOR_WRITE 0x00000002
}; };
int __rwsem_is_locked(struct rw_semaphore *sem) int rwsem_is_locked(struct rw_semaphore *sem)
{ {
int ret = 1; int ret = 1;
unsigned long flags; unsigned long flags;
...@@ -28,7 +28,7 @@ int __rwsem_is_locked(struct rw_semaphore *sem) ...@@ -28,7 +28,7 @@ int __rwsem_is_locked(struct rw_semaphore *sem)
} }
return ret; return ret;
} }
EXPORT_SYMBOL(__rwsem_is_locked); EXPORT_SYMBOL(rwsem_is_locked);
/* /*
* initialise the semaphore * initialise the semaphore
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment