From: Paul E. McKenney Date: Thu, 16 Jan 2020 03:17:02 +0000 (-0800) Subject: rcu: Remove dead code from rcu_segcblist_insert_pend_cbs() X-Git-Tag: v5.7-rc1~183^2^2^2~11 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=57721fd15a02f7df9dad1f3cca27f21e03ee118f;p=thirdparty%2Flinux.git rcu: Remove dead code from rcu_segcblist_insert_pend_cbs() The rcu_segcblist_insert_pend_cbs() function currently (partially) initializes the rcu_cblist that it pulls callbacks from. However, all the resulting stores are dead because all callers pass in the address of an on-stack cblist that is not used afterwards. This commit therefore removes this pointless initialization. Signed-off-by: Paul E. McKenney --- diff --git a/kernel/rcu/rcu_segcblist.c b/kernel/rcu/rcu_segcblist.c index 426a472e73081..9a0f66133b4b3 100644 --- a/kernel/rcu/rcu_segcblist.c +++ b/kernel/rcu/rcu_segcblist.c @@ -381,8 +381,6 @@ void rcu_segcblist_insert_pend_cbs(struct rcu_segcblist *rsclp, return; /* Nothing to do. */ WRITE_ONCE(*rsclp->tails[RCU_NEXT_TAIL], rclp->head); WRITE_ONCE(rsclp->tails[RCU_NEXT_TAIL], rclp->tail); - rclp->head = NULL; - rclp->tail = &rclp->head; } /*