Skip to contentSkip to conversation

net: convert to rcu_dereference_index_check()

PATCH In review Paul E. McKenney 3 participants 5 messages Aug 6, 2010

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 net: convert to rcu_dereference_index_check()

Hello, Herbert!

At long last, the following is the final patch blocking acceptance of Arnd's sparse annotations for RCU. It was itself blocked behind the definition of rcu_dereference_index_check(), which made it to mainline only just today.

Would you be willing to ack this patch so that I can push it to -tip, along with Arnd's work and a bunch of other stuff?

Thanx, Paul

------------------------------------------------------------------------

commit 34ea15566530f8e4d0c1571cc8c3554fd91d5809

Author: Paul E. McKenney <[email protected]>
Date:   Mon Jun 14 17:06:21 2010 -0700

net: convert to rcu_dereference_index_check()

The task_cls_classid() function applies rcu_dereference() to integers, which does not work with the shiny new sparse-based checking in rcu_dereference(). This commit therefore moves to the new RCU API rcu_dereference_index_check().

 cls_cgroup.h |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
include/net/cls_cgroup.h +2 -1
index 726cc35..dd1fdb8 100644
@@ -45,7 +45,8 @@ static inline u32 task_cls_classid(struct task_struct *p)
 		return 0;
 
 	rcu_read_lock();
-	id = rcu_dereference(net_cls_subsys_id);
+	id = rcu_dereference_index_check(net_cls_subsys_id,
+					 rcu_read_lock_held());
 	if (id >= 0)
 		classid = container_of(task_subsys_state(p, id),
 				       struct cgroup_cls_state, css)->classid;
maintainer Acked-by on v1 1/1
#1 lore raw

From: "Paul E. McKenney" <[email protected]>
Date: Fri, 6 Aug 2010 14:26:07 -0700

Quoted 7 lines

At long last, the following is the final patch blocking acceptance of Arnd's sparse annotations for RCU. It was itself blocked behind the definition of rcu_dereference_index_check(), which made it to mainline only just today.

Would you be willing to ack this patch so that I can push it to -tip, along with Arnd's work and a bunch of other stuff?

...

Quoted 9 lines

net: convert to rcu_dereference_index_check()

The task_cls_classid() function applies rcu_dereference() to integers, which does not work with the shiny new sparse-based checking in rcu_dereference(). This commit therefore moves to the new RCU API rcu_dereference_index_check().

You should of course wait for Herbert's ACK too, but for the record:

:-)

#2 lore raw
Quoted 21 lines · David Miller

From: "Paul E. McKenney" <[email protected]>
Date: Fri, 6 Aug 2010 14:26:07 -0700

Quoted 7 lines

At long last, the following is the final patch blocking acceptance of Arnd's sparse annotations for RCU. It was itself blocked behind the definition of rcu_dereference_index_check(), which made it to mainline only just today.

Would you be willing to ack this patch so that I can push it to -tip, along with Arnd's work and a bunch of other stuff?

...

Quoted 9 lines

net: convert to rcu_dereference_index_check()

The task_cls_classid() function applies rcu_dereference() to integers, which does not work with the shiny new sparse-based checking in rcu_dereference(). This commit therefore moves to the new RCU API rcu_dereference_index_check().

Quoted 6 lines

You should of course wait for Herbert's ACK too, but for the record:

:-)

Thank you, David!!! ;-)

Thanx, Paul

Acked-by on v1 1/1
#3 lore raw
In reply to Paul E. McKenney
Quoted 9 lines · Paul E. McKenney

Hello, Herbert!

At long last, the following is the final patch blocking acceptance of Arnd's sparse annotations for RCU. It was itself blocked behind the definition of rcu_dereference_index_check(), which made it to mainline only just today.

Would you be willing to ack this patch so that I can push it to -tip, along with Arnd's work and a bunch of other stuff?

Sure,

Thanks,

Signature · 3 lines
Email: Herbert Xu <[email protected]>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
#4 lore raw
Quoted 8 lines · Herbert Xu
Quoted 7 lines · Paul E. McKenney

Hello, Herbert!

At long last, the following is the final patch blocking acceptance of Arnd's sparse annotations for RCU. It was itself blocked behind the definition of rcu_dereference_index_check(), which made it to mainline only just today.

Quoted 6 lines
Quoted 2 lines

Would you be willing to ack this patch so that I can push it to -tip, along with Arnd's work and a bunch of other stuff?

Sure,

Thank you, Herbert!!!

Thanx, Paul