]> rtime.felk.cvut.cz Git - linux-imx.git/commitdiff
SUNRPC: Add barriers to ensure read ordering in rpc_wake_up_task_queue_locked
authorTrond Myklebust <Trond.Myklebust@netapp.com>
Mon, 25 Mar 2013 15:23:40 +0000 (11:23 -0400)
committerTrond Myklebust <Trond.Myklebust@netapp.com>
Mon, 25 Mar 2013 15:23:40 +0000 (11:23 -0400)
We need to be careful when testing task->tk_waitqueue in
rpc_wake_up_task_queue_locked, because it can be changed while we
are holding the queue->lock.
By adding appropriate memory barriers, we can ensure that it is safe to
test task->tk_waitqueue for equality if the RPC_TASK_QUEUED bit is set.

Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Cc: stable@vger.kernel.org

No differences found