Staging: hv: remove wrapper functions for atomic operations

Previous thread: Staging: rtl8192su: remove more unused files by Linux Kernel Mailing List on Wednesday, September 16, 2009 - 9:03 am. (1 message)

Next thread: Staging: hv: rework use of workqueues in osd by Linux Kernel Mailing List on Wednesday, September 16, 2009 - 9:06 am. (1 message)
From: Linux Kernel Mailing List
Date: Wednesday, September 16, 2009 - 9:07 am

Gitweb:     http://git.kernel.org/linus/f4888417083723c4f5cbfdf4895653279ffdc31e
Commit:     f4888417083723c4f5cbfdf4895653279ffdc31e
Parent:     7c369f405bc918f3245c7ee0b0ad6c6b6c750166
Author:     Bill Pemberton <wfp5p@virginia.edu>
AuthorDate: Wed Jul 29 17:00:12 2009 -0400
Committer:  Greg Kroah-Hartman <gregkh@suse.de>
CommitDate: Tue Sep 15 12:01:53 2009 -0700

    Staging: hv: remove wrapper functions for atomic operations
    
    Signed-off-by: Bill Pemberton <wfp5p@virginia.edu>
    Cc: Hank Janssen <hjanssen@microsoft.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
---
 drivers/staging/hv/Channel.c      |    4 +-
 drivers/staging/hv/Connection.c   |    2 +-
 drivers/staging/hv/NetVsc.c       |   34 ++++++++++++-------------------
 drivers/staging/hv/NetVsc.h       |    5 +--
 drivers/staging/hv/RndisFilter.c  |    6 ++--
 drivers/staging/hv/StorVsc.c      |   40 ++++++++++++++----------------------
 drivers/staging/hv/VmbusPrivate.h |    2 +-
 drivers/staging/hv/include/osd.h  |    4 ---
 drivers/staging/hv/osd.c          |   20 ------------------
 drivers/staging/hv/vmbus_drv.c    |    4 +-
 10 files changed, 40 insertions(+), 81 deletions(-)

diff --git a/drivers/staging/hv/Channel.c b/drivers/staging/hv/Channel.c
index 4b5e3e4..61fc345 100644
--- a/drivers/staging/hv/Channel.c
+++ b/drivers/staging/hv/Channel.c
@@ -540,8 +540,8 @@ VmbusChannelEstablishGpadl(
 
 	DPRINT_ENTER(VMBUS);
 
-	nextGpadlHandle = gVmbusConnection.NextGpadlHandle;
-	InterlockedIncrement((int*)&gVmbusConnection.NextGpadlHandle);
+	nextGpadlHandle = atomic_read(&gVmbusConnection.NextGpadlHandle);
+	atomic_inc(&gVmbusConnection.NextGpadlHandle);
 
 	VmbusChannelCreateGpadlHeader(Kbuffer, Size, &msgInfo, &msgCount);
 	ASSERT(msgInfo != NULL);
diff --git a/drivers/staging/hv/Connection.c b/drivers/staging/hv/Connection.c
index b7df7e7..d7091ad 100644
--- a/drivers/staging/hv/Connection.c
+++ b/drivers/staging/hv/Connection.c
@@ -31,7 +31,7 @@
 
 struct VMBUS_CONNECTION ...
Previous thread: Staging: rtl8192su: remove more unused files by Linux Kernel Mailing List on Wednesday, September 16, 2009 - 9:03 am. (1 message)

Next thread: Staging: hv: rework use of workqueues in osd by Linux Kernel Mailing List on Wednesday, September 16, 2009 - 9:06 am. (1 message)