diff options
author | Greg Kroah-Hartman <gregkh@suse.de> | 2009-07-16 15:34:20 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2009-09-15 15:01:48 -0400 |
commit | 28b6ca9c07787885b89972929f45084eb3197d98 (patch) | |
tree | a6b79999e6d0b1151e42efd1d6ff81f8c5a62b6a /drivers | |
parent | b4362c9c1fe8bec487e275f92fdf57c585ac236a (diff) |
Staging: hv: osd: remove MemoryFence wrapper
Use the "real" mb call instead of a wrapper function.
Cc: Hank Janssen <hjanssen@microsoft.com>
Cc: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/staging/hv/RingBuffer.c | 4 | ||||
-rw-r--r-- | drivers/staging/hv/Vmbus.c | 2 | ||||
-rw-r--r-- | drivers/staging/hv/include/osd.h | 2 | ||||
-rw-r--r-- | drivers/staging/hv/osd.c | 5 |
4 files changed, 3 insertions, 10 deletions
diff --git a/drivers/staging/hv/RingBuffer.c b/drivers/staging/hv/RingBuffer.c index 21fc4cc6326..e99546835f2 100644 --- a/drivers/staging/hv/RingBuffer.c +++ b/drivers/staging/hv/RingBuffer.c | |||
@@ -411,7 +411,7 @@ RingBufferWrite( | |||
411 | sizeof(u64)); | 411 | sizeof(u64)); |
412 | 412 | ||
413 | // Make sure we flush all writes before updating the writeIndex | 413 | // Make sure we flush all writes before updating the writeIndex |
414 | MemoryFence(); | 414 | mb(); |
415 | 415 | ||
416 | // Now, update the write location | 416 | // Now, update the write location |
417 | SetNextWriteLocation(OutRingInfo, nextWriteLocation); | 417 | SetNextWriteLocation(OutRingInfo, nextWriteLocation); |
@@ -532,7 +532,7 @@ RingBufferRead( | |||
532 | 532 | ||
533 | // Make sure all reads are done before we update the read index since | 533 | // Make sure all reads are done before we update the read index since |
534 | // the writer may start writing to the read area once the read index is updated | 534 | // the writer may start writing to the read area once the read index is updated |
535 | MemoryFence(); | 535 | mb(); |
536 | 536 | ||
537 | // Update the read index | 537 | // Update the read index |
538 | SetNextReadLocation(InRingInfo, nextReadLocation); | 538 | SetNextReadLocation(InRingInfo, nextReadLocation); |
diff --git a/drivers/staging/hv/Vmbus.c b/drivers/staging/hv/Vmbus.c index 4ad40be0bdf..72bb08f2439 100644 --- a/drivers/staging/hv/Vmbus.c +++ b/drivers/staging/hv/Vmbus.c | |||
@@ -426,7 +426,7 @@ VmbusOnMsgDPC( | |||
426 | // Make sure the write to MessageType (ie set to HvMessageTypeNone) happens | 426 | // Make sure the write to MessageType (ie set to HvMessageTypeNone) happens |
427 | // before we read the MessagePending and EOMing. Otherwise, the EOMing will not deliver | 427 | // before we read the MessagePending and EOMing. Otherwise, the EOMing will not deliver |
428 | // any more messages since there is no empty slot | 428 | // any more messages since there is no empty slot |
429 | MemoryFence(); | 429 | mb(); |
430 | 430 | ||
431 | if (msg->Header.MessageFlags.MessagePending) | 431 | if (msg->Header.MessageFlags.MessagePending) |
432 | { | 432 | { |
diff --git a/drivers/staging/hv/include/osd.h b/drivers/staging/hv/include/osd.h index 504d585e713..467196d0044 100644 --- a/drivers/staging/hv/include/osd.h +++ b/drivers/staging/hv/include/osd.h | |||
@@ -119,8 +119,6 @@ extern void PageFree(void* page, unsigned int count); | |||
119 | extern void* MemMapIO(unsigned long phys, unsigned long size); | 119 | extern void* MemMapIO(unsigned long phys, unsigned long size); |
120 | extern void MemUnmapIO(void* virt); | 120 | extern void MemUnmapIO(void* virt); |
121 | 121 | ||
122 | extern void MemoryFence(void); | ||
123 | |||
124 | extern HANDLE TimerCreate(PFN_TIMER_CALLBACK pfnTimerCB, void* context); | 122 | extern HANDLE TimerCreate(PFN_TIMER_CALLBACK pfnTimerCB, void* context); |
125 | extern void TimerClose(HANDLE hTimer); | 123 | extern void TimerClose(HANDLE hTimer); |
126 | extern int TimerStop(HANDLE hTimer); | 124 | extern int TimerStop(HANDLE hTimer); |
diff --git a/drivers/staging/hv/osd.c b/drivers/staging/hv/osd.c index 0c2ad4916cb..7a4c4381fd4 100644 --- a/drivers/staging/hv/osd.c +++ b/drivers/staging/hv/osd.c | |||
@@ -197,11 +197,6 @@ void MemUnmapIO(void *virt) | |||
197 | //iounmap(virt); | 197 | //iounmap(virt); |
198 | } | 198 | } |
199 | 199 | ||
200 | void MemoryFence() | ||
201 | { | ||
202 | mb(); | ||
203 | } | ||
204 | |||
205 | void TimerCallback(unsigned long data) | 200 | void TimerCallback(unsigned long data) |
206 | { | 201 | { |
207 | TIMER* t = (TIMER*)data; | 202 | TIMER* t = (TIMER*)data; |