diff options
author | K. Y. Srinivasan <kys@microsoft.com> | 2011-06-06 15:49:35 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2011-06-07 13:45:47 -0700 |
commit | 604a1eb0eb67c38e29f9efd8d20668904f93b50c (patch) | |
tree | 9b7addb89b2bb0181e70a044c626db8b07f639b0 /drivers/staging/hv/channel.c | |
parent | 2aa05dcbfbc017ac99c15de8da9d6c840a3acd5b (diff) | |
download | op-kernel-dev-604a1eb0eb67c38e29f9efd8d20668904f93b50c.zip op-kernel-dev-604a1eb0eb67c38e29f9efd8d20668904f93b50c.tar.gz |
Staging: hv: vmbus: Don't free the channel when the channel is closed
When the driver unloads, the device must persist. A channel represents the
device and so we should not free the channel when the channel is closed as
part of the driver unloading.
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Abhishek Kane <v-abkane@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/hv/channel.c')
-rw-r--r-- | drivers/staging/hv/channel.c | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/drivers/staging/hv/channel.c b/drivers/staging/hv/channel.c index f655e59..aca9ac8 100644 --- a/drivers/staging/hv/channel.c +++ b/drivers/staging/hv/channel.c @@ -552,7 +552,6 @@ void vmbus_close(struct vmbus_channel *channel) { struct vmbus_channel_close_channel *msg; struct vmbus_channel_msginfo *info; - unsigned long flags; int ret; /* Stop callback and cancel the timer asap */ @@ -591,19 +590,6 @@ void vmbus_close(struct vmbus_channel *channel) kfree(info); - /* - * If we are closing the channel during an error path in - * opening the channel, don't free the channel since the - * caller will free the channel - */ - - if (channel->state == CHANNEL_OPEN_STATE) { - spin_lock_irqsave(&vmbus_connection.channel_lock, flags); - list_del(&channel->listentry); - spin_unlock_irqrestore(&vmbus_connection.channel_lock, flags); - - free_channel(channel); - } } EXPORT_SYMBOL_GPL(vmbus_close); |