summaryrefslogtreecommitdiff
path: root/drivers/staging/hv/Connection.c
diff options
context:
space:
mode:
authorBill Pemberton <wfp5p@virginia.edu>2009-07-29 21:00:09 (GMT)
committerGreg Kroah-Hartman <gregkh@suse.de>2009-09-15 19:01:53 (GMT)
commitde65a38406bdf712abc2a845fe1f3db7d1a083ed (patch)
treecd4d9f38dd90c6bfc5a5667bc2c4fcc4481d2f8b /drivers/staging/hv/Connection.c
parent949cadaa054588db0c4a3a0cfc3ac93f08fda913 (diff)
downloadlinux-fsl-qoriq-de65a38406bdf712abc2a845fe1f3db7d1a083ed.tar.xz
Staging: hv: rework use of workqueues in osd
Change the usage of workqueues to be consistant with other parts of the kernel. Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/hv/Connection.c')
-rw-r--r--drivers/staging/hv/Connection.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/drivers/staging/hv/Connection.c b/drivers/staging/hv/Connection.c
index a2888cb..33e5628 100644
--- a/drivers/staging/hv/Connection.c
+++ b/drivers/staging/hv/Connection.c
@@ -60,7 +60,12 @@ VmbusConnect(void)
/* Initialize the vmbus connection */
gVmbusConnection.ConnectState = Connecting;
- gVmbusConnection.WorkQueue = WorkQueueCreate("vmbusQ");
+ gVmbusConnection.WorkQueue = create_workqueue("hv_vmbus_con");
+ if (!gVmbusConnection.WorkQueue)
+ {
+ ret = -1;
+ goto Cleanup;
+ }
INITIALIZE_LIST_HEAD(&gVmbusConnection.ChannelMsgList);
spin_lock_init(&gVmbusConnection.channelmsg_lock);
@@ -160,7 +165,8 @@ Cleanup:
gVmbusConnection.ConnectState = Disconnected;
- WorkQueueClose(gVmbusConnection.WorkQueue);
+ if (gVmbusConnection.WorkQueue)
+ destroy_workqueue(gVmbusConnection.WorkQueue);
if (gVmbusConnection.InterruptPage)
{
@@ -226,7 +232,7 @@ VmbusDisconnect(
/* TODO: iterate thru the msg list and free up */
- WorkQueueClose(gVmbusConnection.WorkQueue);
+ destroy_workqueue(gVmbusConnection.WorkQueue);
gVmbusConnection.ConnectState = Disconnected;