greybus: connection: add helper to disable incoming operations
authorJohan Hovold <johan@hovoldconsulting.com>
Tue, 19 Jan 2016 11:51:08 +0000 (12:51 +0100)
committerGreg Kroah-Hartman <gregkh@google.com>
Tue, 19 Jan 2016 20:12:40 +0000 (12:12 -0800)
commitbeb6b7fede005ae351619b30a8940a04e797b9b2
treeb54e4842189220b612418df73f3bfb3c2decbfaa
parent570dfa7c55a76258b03a2d93f9db12dacc2ad3c6
greybus: connection: add helper to disable incoming operations

Add helper to disable and flush incoming operations.

This is intended to be used by core to flush any incoming requests
before calling driver disconnect, but could potentially later be
exported for driver use as well.

Note that we currently flush all incoming operation and allow the
request handlers to run, but cancel any responses sent. This may need to
be refined later.

Reviewed-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Johan Hovold <johan@hovoldconsulting.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
drivers/staging/greybus/connection.c
drivers/staging/greybus/connection.h