[PATCH 16/16] rxrpc: Replace smp_read_barrier_depends() with lockless_dereference()

2014-11-13 Thread Pranith Kumar
Recently lockless_dereference() was added which can be used in place of hard-coding smp_read_barrier_depends(). The following PATCH makes the change. Signed-off-by: Pranith Kumar --- net/rxrpc/ar-ack.c | 22 +- 1 file changed, 9 insertions(+), 13 deletions(-) diff --git a/ne

Re: [PATCH 16/16] rxrpc: Replace smp_read_barrier_depends() with lockless_dereference()

2014-11-13 Thread David Howells
Pranith Kumar wrote: >loop != call->acks_head || stop; >loop = (loop + 1) & (call->acks_winsz - 1) >) { > - p_txb = call->acks_window + loop; > - smp_read_barrier_depends(); > + p_txb = lockless_dereference(call)->acks_windo

Re: [PATCH 16/16] rxrpc: Replace smp_read_barrier_depends() with lockless_dereference()

2014-11-13 Thread David Howells
Pranith Kumar wrote: > Recently lockless_dereference() was added which can be used in place of > hard-coding smp_read_barrier_depends(). The following PATCH makes the change. Actually, the use of smp_read_barrier_depends() is wrong in circular buffering. See Documentation/circular-buffers.txt

Re: [PATCH 16/16] rxrpc: Replace smp_read_barrier_depends() with lockless_dereference()

2014-11-13 Thread Pranith Kumar
On 11/13/2014 03:47 PM, David Howells wrote: > Pranith Kumar wrote: > >> Recently lockless_dereference() was added which can be used in place of >> hard-coding smp_read_barrier_depends(). The following PATCH makes the change. > > Actually, the use of smp_read_barrier_depends() is wrong in circul

Re: [PATCH 16/16] rxrpc: Replace smp_read_barrier_depends() with lockless_dereference()

2014-11-13 Thread David Howells
Pranith Kumar wrote: > OK. Should I send in a patch removing these barriers then? No. There need to be stronger barriers, at least in some of the cases. circular-buffers.txt details what is required, but not all of the cases match the pattern there, so it needs a bit more consideration. David