]> git.baikalelectronics.ru Git - kernel.git/commit
file locks: Use wait_event_interruptible_timeout()
authorMatthew Wilcox <matthew@wil.cx>
Tue, 15 Jan 2008 04:28:30 +0000 (21:28 -0700)
committerJ. Bruce Fields <bfields@citi.umich.edu>
Sun, 3 Feb 2008 22:51:36 +0000 (17:51 -0500)
commite0641ae9746d379e170f722931abc14ae5fb9883
tree32b7b1a4af4b28c3ce1fc013bc7a2da4f2e21fde
parent760c5f1b1ddcd51225170e62c81434ab190e8dec
file locks: Use wait_event_interruptible_timeout()

interruptible_sleep_on_locked() is just an open-coded
wait_event_interruptible_timeout(), with the one difference that
interruptible_sleep_on_locked() doesn't bother to check the condition on
which it is waiting, depending instead on the BKL to avoid the case
where it blocks after the wakeup has already been called.

locks_block_on_timeout() is only used in one place, so it's actually
simpler to inline it into its caller.

Signed-off-by: Matthew Wilcox <willy@linux.intel.com>
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu>
fs/locks.c