]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
Drivers: hv: vmbus: Fix a bug in vmbus_open()
authorK. Y. Srinivasan <kys@microsoft.com>
Wed, 27 Aug 2014 23:25:35 +0000 (16:25 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 24 Sep 2014 06:30:38 +0000 (23:30 -0700)
Fix a bug in vmbus_open() and properly propagate the error. I would
like to thank Dexuan Cui <decui@microsoft.com> for identifying the
issue.

Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Cc: <stable@vger.kernel.org>
Tested-by: Sitsofe Wheeler <sitsofe@yahoo.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/hv/channel.c

index 3788a181f17683e150146c3e2b0e1af5e53efe39..b4eebe34ca91d9e6fc268638fb8e5b140e3dc5c0 100644 (file)
@@ -165,8 +165,10 @@ int vmbus_open(struct vmbus_channel *newchannel, u32 send_ringbuffer_size,
        ret = vmbus_post_msg(open_msg,
                               sizeof(struct vmbus_channel_open_channel));
 
-       if (ret != 0)
+       if (ret != 0) {
+               err = ret;
                goto error1;
+       }
 
        t = wait_for_completion_timeout(&open_info->waitevent, 5*HZ);
        if (t == 0) {