staging: lustre: remove back_to_sleep()
authorNeilBrown <neilb@suse.com>
Mon, 12 Feb 2018 23:47:59 +0000 (10:47 +1100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 16 Feb 2018 14:19:11 +0000 (15:19 +0100)
commitcac6e45735cbe3ce7cbea64d360699d7adab7573
tree8f94e83d4c4071622d3a57e91f1d117fb9add087
parent4796293a7a0b17cb9223070fd25b009257fb5729
staging: lustre: remove back_to_sleep()

When 'back_to_sleep()' is passed as the 'timeout' function,
the effect is to wait indefinitely for the event, polling
once after the timeout.
If LWI_ON_SIGNAL_NOOP is given, then after the timeout
we allow fatal signals to interrupt the wait.

Make this more obvious in both places "back_to_sleep()" is
used but using two explicit sleeps.

The code in ptlrpcd_add_req() looks odd - why not just have one
wait_event_idle()?  However I believe this is a faithful
transformation of the existing code.

Reviewed-by: James Simmons <jsimmons@infradead.org>
Signed-off-by: NeilBrown <neilb@suse.com>
Reviewed-by: Patrick Farrell <paf@cray.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/lustre/lustre/include/lustre_lib.h
drivers/staging/lustre/lustre/ptlrpc/import.c
drivers/staging/lustre/lustre/ptlrpc/ptlrpcd.c