Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 666b9adc authored by K. Y. Srinivasan's avatar K. Y. Srinivasan Committed by Greg Kroah-Hartman
Browse files

Drivers: hv: vmbus: Do not attempt to negoatiate a new version prematurely



The current code would attempt to negotiate a different protocol version if
the current negotiation timed out. This triggers an assert in the host (on debug
builds). Avoid this by negotiating a newer version only if the host properly
rejects the current version being negotiated.

Signed-off-by: default avatarK. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent e83736c8
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -195,7 +195,10 @@ int vmbus_connect(void)

	do {
		ret = vmbus_negotiate_version(msginfo, version);
		if (ret == 0)
		if (ret)
			goto cleanup;

		if (vmbus_connection.conn_state == CONNECTED)
			break;

		version = vmbus_get_next_version(version);