Skip to content

Commit 7469be9

Browse files
jbeulichDavid Vrabel
authored andcommitted
xenbus: don't bail early from xenbus_dev_request_and_reply()
xenbus_dev_request_and_reply() needs to track whether a transaction is open. For XS_TRANSACTION_START messages it calls transaction_start() and for XS_TRANSACTION_END messages it calls transaction_end(). If sending an XS_TRANSACTION_START message fails or responds with an an error, the transaction is not open and transaction_end() must be called. If sending an XS_TRANSACTION_END message fails, the transaction is still open, but if an error response is returned the transaction is closed. Commit 027bd7e ("xen/xenbus: Avoid synchronous wait on XenBus stalling shutdown/restart") introduced a regression where failed XS_TRANSACTION_START messages were leaving the transaction open. This can cause problems with suspend (and migration) as all transactions must be closed before suspending. It appears that the problematic change was added accidentally, so just remove it. Signed-off-by: Jan Beulich <[email protected]> Cc: Konrad Rzeszutek Wilk <[email protected]> Cc: <[email protected]> Signed-off-by: David Vrabel <[email protected]>
1 parent 0beef63 commit 7469be9

File tree

1 file changed

+0
-3
lines changed

1 file changed

+0
-3
lines changed

drivers/xen/xenbus/xenbus_xs.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -249,9 +249,6 @@ void *xenbus_dev_request_and_reply(struct xsd_sockmsg *msg)
249249

250250
mutex_unlock(&xs_state.request_mutex);
251251

252-
if (IS_ERR(ret))
253-
return ret;
254-
255252
if ((msg->type == XS_TRANSACTION_END) ||
256253
((req_msg.type == XS_TRANSACTION_START) &&
257254
(msg->type == XS_ERROR)))

0 commit comments

Comments
 (0)