Skip to content

Commit

Permalink
rw_semaphore: remove up/down_read_non_owner
Browse files Browse the repository at this point in the history
Now that the last users is gone these can be removed.

Signed-off-by: Christoph Hellwig <[email protected]>
Signed-off-by: Al Viro <[email protected]>
  • Loading branch information
Christoph Hellwig authored and Al Viro committed Jul 21, 2011
1 parent bd5fe6c commit 11b80f4
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 26 deletions.
10 changes: 0 additions & 10 deletions include/linux/rwsem.h
Original file line number Diff line number Diff line change
Expand Up @@ -124,19 +124,9 @@ extern void downgrade_write(struct rw_semaphore *sem);
*/
extern void down_read_nested(struct rw_semaphore *sem, int subclass);
extern void down_write_nested(struct rw_semaphore *sem, int subclass);
/*
* Take/release a lock when not the owner will release it.
*
* [ This API should be avoided as much as possible - the
* proper abstraction for this case is completions. ]
*/
extern void down_read_non_owner(struct rw_semaphore *sem);
extern void up_read_non_owner(struct rw_semaphore *sem);
#else
# define down_read_nested(sem, subclass) down_read(sem)
# define down_write_nested(sem, subclass) down_write(sem)
# define down_read_non_owner(sem) down_read(sem)
# define up_read_non_owner(sem) up_read(sem)
#endif

#endif /* _LINUX_RWSEM_H */
16 changes: 0 additions & 16 deletions kernel/rwsem.c
Original file line number Diff line number Diff line change
Expand Up @@ -117,15 +117,6 @@ void down_read_nested(struct rw_semaphore *sem, int subclass)

EXPORT_SYMBOL(down_read_nested);

void down_read_non_owner(struct rw_semaphore *sem)
{
might_sleep();

__down_read(sem);
}

EXPORT_SYMBOL(down_read_non_owner);

void down_write_nested(struct rw_semaphore *sem, int subclass)
{
might_sleep();
Expand All @@ -136,13 +127,6 @@ void down_write_nested(struct rw_semaphore *sem, int subclass)

EXPORT_SYMBOL(down_write_nested);

void up_read_non_owner(struct rw_semaphore *sem)
{
__up_read(sem);
}

EXPORT_SYMBOL(up_read_non_owner);

#endif


0 comments on commit 11b80f4

Please sign in to comment.