]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commitdiff
rcu: Remove unused ->rcu_read_unlock_special.b.deferred_qs field
authorLai Jiangshan <laijs@linux.alibaba.com>
Sat, 15 Feb 2020 22:52:32 +0000 (14:52 -0800)
committerPaul E. McKenney <paulmck@kernel.org>
Mon, 27 Apr 2020 18:03:50 +0000 (11:03 -0700)
The ->rcu_read_unlock_special.b.deferred_qs field is set to true in
rcu_read_unlock_special() but never set to false.  This is not
particularly useful, so this commit removes this field.

The only possible justification for this field is to ease debugging
of RCU deferred quiscent states, but the combination of the other
->rcu_read_unlock_special fields plus ->rcu_blocked_node and of course
->rcu_read_lock_nesting should cover debugging needs.  And if this last
proves incorrect, this patch can always be reverted, along with the
required setting of ->rcu_read_unlock_special.b.deferred_qs to false
in rcu_preempt_deferred_qs_irqrestore().

Signed-off-by: Lai Jiangshan <laijs@linux.alibaba.com>
Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
include/linux/sched.h
kernel/rcu/tree_plugin.h

index 4418f5cb832431519edb88c047522c12a816fa3b..a4b727f57095dc1aada79edebd4a15a3426da713 100644 (file)
@@ -613,7 +613,7 @@ union rcu_special {
                u8                      blocked;
                u8                      need_qs;
                u8                      exp_hint; /* Hint for performance. */
-               u8                      deferred_qs;
+               u8                      pad; /* No garbage from compiler! */
        } b; /* Bits. */
        u32 s; /* Set of bits. */
 };
index 263c766b9dc1a95a22ad61bef401073b0bc57e75..f31c5992f8424e8237a3b42f365416b2647a2a61 100644 (file)
@@ -634,7 +634,6 @@ static void rcu_read_unlock_special(struct task_struct *t)
                                irq_work_queue_on(&rdp->defer_qs_iw, rdp->cpu);
                        }
                }
-               t->rcu_read_unlock_special.b.deferred_qs = true;
                local_irq_restore(flags);
                return;
        }