Re: [PATCH 3/4] sunrpc: make rpc_wait_bit_killable handle freezeevents

From: Jeff Layton
Date: Tue Oct 11 2011 - 06:13:14 EST


On Tue, 11 Oct 2011 08:19:23 +0200
Pavel Machek <pavel@xxxxxx> wrote:

> On Wed 2011-09-28 07:52:40, Jeff Layton wrote:
> > Allow the wait_on_bit_killable sleeps in SUNRPC layer to respect the
> > freezer. This should allow suspend and hibernate events to occur, even
> > when there are RPC's pending on the wire.
>
> Will the RPC protocols used handle that correctly? What will happen
> during resume?
>

That depends on the state of the socket during resume. If the
suspend/resume is quick enough, then the socket may still be connected,
or if we're using UDP then we might just get the reply and carry on
successfully. Otherwise, the call will eventually time out, or will be
cancelled when the kernel finds that the socket has been closed.

Either way, this should do the right thing.

--
Jeff Layton <jlayton@xxxxxxxxxx>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/