* [PATCH 1/1] Drivers: hv: vmbus: Fix a bug in channel rescind code
@ 2013-10-12 0:27 K. Y. Srinivasan
0 siblings, 0 replies; only message in thread
From: K. Y. Srinivasan @ 2013-10-12 0:27 UTC (permalink / raw)
To: gregkh, linux-kernel, devel, olaf, apw, jasowang
Cc: K. Y. Srinivasan, stable, "[3.11+]"
Rescind of subchannels were not being correctly handled. Fix the bug.
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Cc: <stable@vger.kernel.org> [3.11+]
---
drivers/hv/channel_mgmt.c | 8 ++------
1 files changed, 2 insertions(+), 6 deletions(-)
diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c
index bbff5f2..eebf566 100644
--- a/drivers/hv/channel_mgmt.c
+++ b/drivers/hv/channel_mgmt.c
@@ -203,7 +203,8 @@ static void vmbus_process_rescind_offer(struct work_struct *work)
struct vmbus_channel *primary_channel;
struct vmbus_channel_relid_released msg;
- vmbus_device_unregister(channel->device_obj);
+ if (channel->device_obj)
+ vmbus_device_unregister(channel->device_obj);
memset(&msg, 0, sizeof(struct vmbus_channel_relid_released));
msg.child_relid = channel->offermsg.child_relid;
msg.header.msgtype = CHANNELMSG_RELID_RELEASED;
@@ -213,11 +214,6 @@ static void vmbus_process_rescind_offer(struct work_struct *work)
spin_lock_irqsave(&vmbus_connection.channel_lock, flags);
list_del(&channel->listentry);
spin_unlock_irqrestore(&vmbus_connection.channel_lock, flags);
- } else {
- primary_channel = channel->primary_channel;
- spin_lock_irqsave(&primary_channel->sc_lock, flags);
- list_del(&channel->listentry);
- spin_unlock_irqrestore(&primary_channel->sc_lock, flags);
}
free_channel(channel);
}
--
1.7.4.1
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2013-10-12 0:27 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-10-12 0:27 [PATCH 1/1] Drivers: hv: vmbus: Fix a bug in channel rescind code K. Y. Srinivasan
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).