diff options
author | Johan Hovold <johan@hovoldconsulting.com> | 2016-04-29 17:08:33 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@google.com> | 2016-04-29 14:27:05 -0700 |
commit | 5fdc027d5441aecb94ce44de0402bdec3a731de8 (patch) | |
tree | baa2fe96cadb37901136c6bf41e773cfa19ae851 /drivers/staging/greybus/operation.h | |
parent | 3e2ee2c1e50541b611087be9e2e55b8f77477cf6 (diff) |
greybus: operation: add helper functions for unidirectional operations
Add helper functions for initiating unidirectional operations and
waiting for them to have been acknowledged as sent by the host device.
Signed-off-by: Johan Hovold <johan@hovoldconsulting.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Diffstat (limited to 'drivers/staging/greybus/operation.h')
-rw-r--r-- | drivers/staging/greybus/operation.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/staging/greybus/operation.h b/drivers/staging/greybus/operation.h index c88efe11c22b..8ef8f514dafa 100644 --- a/drivers/staging/greybus/operation.h +++ b/drivers/staging/greybus/operation.h @@ -178,6 +178,9 @@ int gb_operation_sync_timeout(struct gb_connection *connection, int type, void *request, int request_size, void *response, int response_size, unsigned int timeout); +int gb_operation_unidirectional_timeout(struct gb_connection *connection, + int type, void *request, int request_size, + unsigned int timeout); static inline int gb_operation_sync(struct gb_connection *connection, int type, void *request, int request_size, @@ -188,6 +191,13 @@ static inline int gb_operation_sync(struct gb_connection *connection, int type, GB_OPERATION_TIMEOUT_DEFAULT); } +static inline int gb_operation_unidirectional(struct gb_connection *connection, + int type, void *request, int request_size) +{ + return gb_operation_unidirectional_timeout(connection, type, + request, request_size, GB_OPERATION_TIMEOUT_DEFAULT); +} + int gb_operation_init(void); void gb_operation_exit(void); |