staging: greybus: operation: add generic timeout support
authorJohan Hovold <johan@kernel.org>
Mon, 23 Jan 2017 12:04:14 +0000 (13:04 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 9 Feb 2017 10:58:56 +0000 (11:58 +0100)
commitdbec27298b0df86eaa6bc02e5df0ce55ec7d97f2
treeaaeae8679724ce4bdbe08e94e24b4660d0545ec9
parenta769f30c7bd7cf917eea05a2b448f3588a87d767
staging: greybus: operation: add generic timeout support

Add a struct timer_list to struct gb_operation and use that to implement
generic operation timeouts.

This simplifies the synchronous operation handling somewhat while also
providing a generic timeout mechanism that drivers can use for
asynchronous operations.

Signed-off-by: Johan Hovold <johan@kernel.org>
Acked-by: Bryan O'Donoghue <pure.logic@nexus-software.ie>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/greybus/loopback.c
drivers/staging/greybus/operation.c
drivers/staging/greybus/operation.h