summaryrefslogtreecommitdiffstats
path: root/drivers/staging/xillybus/xillybus_core.c
diff options
context:
space:
mode:
authorEli Billauer2014-08-16 17:57:57 +0200
committerGreg Kroah-Hartman2014-08-30 22:14:41 +0200
commitf66a49766fdfcb8186056bd44a407594c6a3d5ff (patch)
tree022de300eb05a08a97ab2d69cb9bb7193de40f90 /drivers/staging/xillybus/xillybus_core.c
parentstaging: xillybus: Remove mmiowb() before wait_event_*() calls (diff)
downloadkernel-qcow2-linux-f66a49766fdfcb8186056bd44a407594c6a3d5ff.tar.gz
kernel-qcow2-linux-f66a49766fdfcb8186056bd44a407594c6a3d5ff.tar.xz
kernel-qcow2-linux-f66a49766fdfcb8186056bd44a407594c6a3d5ff.zip
staging: xillybus: Removed mmiowb() before mutex_unlock()
The relevant sequences consist of two I/O memory writes. The second write depends on the first one. mmiowb() was inserted to make sure that no other thread inserts a "first write" before the current one finished its second. As a mutex protects this critical sequence, mmiowb() is unnecessary. Signed-off-by: Eli Billauer <eli.billauer@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/xillybus/xillybus_core.c')
-rw-r--r--drivers/staging/xillybus/xillybus_core.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/drivers/staging/xillybus/xillybus_core.c b/drivers/staging/xillybus/xillybus_core.c
index 93a3c61b1cd5..138c0695e290 100644
--- a/drivers/staging/xillybus/xillybus_core.c
+++ b/drivers/staging/xillybus/xillybus_core.c
@@ -908,8 +908,6 @@ static ssize_t xillybus_read(struct file *filp, char __user *userbuf,
channel->endpoint->registers +
fpga_buf_ctrl_reg);
- mmiowb(); /* Just to appear safe */
-
mutex_unlock(&channel->endpoint->
register_mutex);
}
@@ -1118,7 +1116,6 @@ static int xillybus_myflush(struct xilly_channel *channel, long timeout)
(2 << 24) | /* Opcode 2, submit buffer */
(bufidx << 12),
channel->endpoint->registers + fpga_buf_ctrl_reg);
- mmiowb(); /* Just to appear safe */
mutex_unlock(&channel->endpoint->register_mutex);
} else if (bufidx == 0)
@@ -1369,7 +1366,6 @@ static ssize_t xillybus_write(struct file *filp, const char __user *userbuf,
(bufidx << 12),
channel->endpoint->registers +
fpga_buf_ctrl_reg);
- mmiowb(); /* Just to appear safe */
mutex_unlock(&channel->endpoint->
register_mutex);