diff options
author | Frank Haverkamp <haver@linux.vnet.ibm.com> | 2014-03-20 10:11:03 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-04-16 15:12:38 -0400 |
commit | 68fe8acc204c7fbefd4c01b8929fedb244ec283d (patch) | |
tree | 51f8a953eb1505cbf9a356655ebfc770393bdc53 /drivers/misc/genwqe | |
parent | 5c5e0589038537848849fc827f5234a31a10f899 (diff) |
GenWQE: Add wmb before DDCB is started
Needed to add wmb() before we send the DDCB for execution.
Without the syncronizing it failed on System p.
Signed-off-by: Frank Haverkamp <haver@linux.vnet.ibm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/misc/genwqe')
-rw-r--r-- | drivers/misc/genwqe/card_ddcb.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/misc/genwqe/card_ddcb.c b/drivers/misc/genwqe/card_ddcb.c index 6f1acc0ccf88..29a1a28be02a 100644 --- a/drivers/misc/genwqe/card_ddcb.c +++ b/drivers/misc/genwqe/card_ddcb.c | |||
@@ -305,6 +305,8 @@ static int enqueue_ddcb(struct genwqe_dev *cd, struct ddcb_queue *queue, | |||
305 | break; | 305 | break; |
306 | 306 | ||
307 | new = (old | DDCB_NEXT_BE32); | 307 | new = (old | DDCB_NEXT_BE32); |
308 | |||
309 | wmb(); | ||
308 | icrc_hsi_shi = cmpxchg(&prev_ddcb->icrc_hsi_shi_32, old, new); | 310 | icrc_hsi_shi = cmpxchg(&prev_ddcb->icrc_hsi_shi_32, old, new); |
309 | 311 | ||
310 | if (icrc_hsi_shi == old) | 312 | if (icrc_hsi_shi == old) |
@@ -314,6 +316,8 @@ static int enqueue_ddcb(struct genwqe_dev *cd, struct ddcb_queue *queue, | |||
314 | /* Queue must be re-started by updating QUEUE_OFFSET */ | 316 | /* Queue must be re-started by updating QUEUE_OFFSET */ |
315 | ddcb_mark_tapped(pddcb); | 317 | ddcb_mark_tapped(pddcb); |
316 | num = (u64)ddcb_no << 8; | 318 | num = (u64)ddcb_no << 8; |
319 | |||
320 | wmb(); | ||
317 | __genwqe_writeq(cd, queue->IO_QUEUE_OFFSET, num); /* start queue */ | 321 | __genwqe_writeq(cd, queue->IO_QUEUE_OFFSET, num); /* start queue */ |
318 | 322 | ||
319 | return RET_DDCB_TAPPED; | 323 | return RET_DDCB_TAPPED; |