Thread (18 messages) 18 messages, 3 authors, 2018-05-22

Re: [PATCH v2 01/26] rculist: introduce list_next_or_null_rr_rcu()

From: Linus Torvalds <torvalds@linux-foundation.org>
Date: 2018-05-19 20:57:00
Also in: linux-block, lkml

On Sat, May 19, 2018 at 1:21 PM Roman Penyaev <
roman.penyaev@profitbricks.com> wrote:
I need -rr behaviour for doing IO load-balancing when I choose next RDMA
connection from the list in order to send a request, i.e. my code is
something like the following:
[ incomplete pseudoicode ]
i.e. usage of the @next pointer is under an RCU critical section.
That's not enough. The whole chain to look up the pointer you are taking
'next' of needs to be under RCU, and that's not clear from your example.

It's *probably* the case, but basically you have to prove that the starting
point is still on the same RCU list. That wasn't clear from your example.

The above is (as Paul said) true of list_next_rcu() too, so it's not like
this is anything specific to the 'rr' version.

              Linus
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help