greybus: operation: suppress response submission on connection tear down
Suppress response submission on connection tear down as we do with requests. Signed-off-by: Johan Hovold <johan@hovoldconsulting.com> Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
This commit is contained in:
parent
c600e535a7
commit
886c6069bc
|
@ -705,6 +705,9 @@ static int gb_operation_response_send(struct gb_operation *operation,
|
|||
struct gb_connection *connection = operation->connection;
|
||||
int ret;
|
||||
|
||||
if (connection->state != GB_CONNECTION_STATE_ENABLED)
|
||||
return -ENOTCONN;
|
||||
|
||||
if (!operation->response &&
|
||||
!gb_operation_is_unidirectional(operation)) {
|
||||
if (!gb_operation_response_alloc(operation, 0))
|
||||
|
|
Loading…
Reference in New Issue