diff options
Diffstat (limited to 'drivers/hv/ring_buffer.c')
-rw-r--r-- | drivers/hv/ring_buffer.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/hv/ring_buffer.c b/drivers/hv/ring_buffer.c index d6fbb5772b8d..791f45dfc85d 100644 --- a/drivers/hv/ring_buffer.c +++ b/drivers/hv/ring_buffer.c | |||
@@ -32,7 +32,7 @@ | |||
32 | void hv_begin_read(struct hv_ring_buffer_info *rbi) | 32 | void hv_begin_read(struct hv_ring_buffer_info *rbi) |
33 | { | 33 | { |
34 | rbi->ring_buffer->interrupt_mask = 1; | 34 | rbi->ring_buffer->interrupt_mask = 1; |
35 | smp_mb(); | 35 | mb(); |
36 | } | 36 | } |
37 | 37 | ||
38 | u32 hv_end_read(struct hv_ring_buffer_info *rbi) | 38 | u32 hv_end_read(struct hv_ring_buffer_info *rbi) |
@@ -41,7 +41,7 @@ u32 hv_end_read(struct hv_ring_buffer_info *rbi) | |||
41 | u32 write; | 41 | u32 write; |
42 | 42 | ||
43 | rbi->ring_buffer->interrupt_mask = 0; | 43 | rbi->ring_buffer->interrupt_mask = 0; |
44 | smp_mb(); | 44 | mb(); |
45 | 45 | ||
46 | /* | 46 | /* |
47 | * Now check to see if the ring buffer is still empty. | 47 | * Now check to see if the ring buffer is still empty. |
@@ -71,7 +71,7 @@ u32 hv_end_read(struct hv_ring_buffer_info *rbi) | |||
71 | 71 | ||
72 | static bool hv_need_to_signal(u32 old_write, struct hv_ring_buffer_info *rbi) | 72 | static bool hv_need_to_signal(u32 old_write, struct hv_ring_buffer_info *rbi) |
73 | { | 73 | { |
74 | smp_mb(); | 74 | mb(); |
75 | if (rbi->ring_buffer->interrupt_mask) | 75 | if (rbi->ring_buffer->interrupt_mask) |
76 | return false; | 76 | return false; |
77 | 77 | ||
@@ -442,7 +442,7 @@ int hv_ringbuffer_write(struct hv_ring_buffer_info *outring_info, | |||
442 | sizeof(u64)); | 442 | sizeof(u64)); |
443 | 443 | ||
444 | /* Issue a full memory barrier before updating the write index */ | 444 | /* Issue a full memory barrier before updating the write index */ |
445 | smp_mb(); | 445 | mb(); |
446 | 446 | ||
447 | /* Now, update the write location */ | 447 | /* Now, update the write location */ |
448 | hv_set_next_write_location(outring_info, next_write_location); | 448 | hv_set_next_write_location(outring_info, next_write_location); |
@@ -549,7 +549,7 @@ int hv_ringbuffer_read(struct hv_ring_buffer_info *inring_info, void *buffer, | |||
549 | /* Make sure all reads are done before we update the read index since */ | 549 | /* Make sure all reads are done before we update the read index since */ |
550 | /* the writer may start writing to the read area once the read index */ | 550 | /* the writer may start writing to the read area once the read index */ |
551 | /*is updated */ | 551 | /*is updated */ |
552 | smp_mb(); | 552 | mb(); |
553 | 553 | ||
554 | /* Update the read index */ | 554 | /* Update the read index */ |
555 | hv_set_next_read_location(inring_info, next_read_location); | 555 | hv_set_next_read_location(inring_info, next_read_location); |