diff options
author | K. Y. Srinivasan <kys@microsoft.com> | 2015-02-28 11:18:20 -0800 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-03-01 19:31:02 -0800 |
commit | 5380b383ba10915e61e3db09341cf8193f0601ad (patch) | |
tree | 46553ab8ebd2dabedc09008de506bd9bc04fa021 | |
parent | 5b1e5b530753e660080d402b81b88684893157d5 (diff) |
Drivers: hv: util: On device remove, close the channel after de-initializing the service
When the offer is rescinded, vmbus_close() can free up the channel;
deinitialize the service before closing the channel.
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | drivers/hv/hv_util.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/hv/hv_util.c b/drivers/hv/hv_util.c index c5be7737559f..7994ec2e4151 100644 --- a/drivers/hv/hv_util.c +++ b/drivers/hv/hv_util.c @@ -380,9 +380,9 @@ static int util_remove(struct hv_device *dev) { struct hv_util_service *srv = hv_get_drvdata(dev); - vmbus_close(dev->channel); if (srv->util_deinit) srv->util_deinit(); + vmbus_close(dev->channel); kfree(srv->recv_buffer); return 0; |