Messages in this thread Patch in this message | | | Date | Tue, 2 May 2017 05:56:48 -0700 | From | "Paul E. McKenney" <> | Subject | Re: [PATCH] srcu: Debloat the <linux/rcu_segcblist.h> header |
| |
On Tue, May 02, 2017 at 03:25:03AM -0700, Paul E. McKenney wrote: > On Tue, May 02, 2017 at 10:31:18AM +0200, Ingo Molnar wrote: > > > > * Ingo Molnar <mingo@kernel.org> wrote: > > > > > > I will get rid of the unused rcu_segcblist_extract_all() function and create a > > > > kernel/rcu/segcblist.c for the functions that are either non-trivial or > > > > performance-insensitive. > > > > > > > > Does that cover it, or am I missing something? > > > > > > I'd also suggest moving as much of the RCU internal data types into kernel/rcu/ > > > as possible. It's not clear to me which part of it is supposed to be a public > > > API and which bits are internal. It might make sense to keep it internal for the > > > time being, and only export things once there are users. > > > > > > I.e. a pretty good solution would be to move all of > > > include/linux/rcu_segcblist.h to kernel/rcu/rcu_segcblist.c or so - and do a > > > kernel/rcu/rcu_segcblist.h with the data types and function prototypes. > > > > I.e. the attached patch as a first step. > > > > Only minimally build tested, but it appears to be do the trick. > > > > This changes the <linux/rcu_segcblist.h> header from ~700 lines to only 90 lines - > > 60% of which is comments. > > > > The deinlining of the inline functions within kernel/rcu/ should also be done, as > > a separate patch on top of this. > > > > What do you think? > > Thank you very much! > > I have pulled this in and started a short rcutorture run. I will do > de-inline and create a .c file on top of this and retest after the > rcutorture has finished.
And I am applying the following fixlet for !SMP builds, which I am retesting. Other than that, initial rcutorture ran fine!
Thanx, Paul
------------------------------------------------------------------------
diff --git a/kernel/rcu/srcutiny.c b/kernel/rcu/srcutiny.c index b8293527ee18..36e1f82faed1 100644 --- a/kernel/rcu/srcutiny.c +++ b/kernel/rcu/srcutiny.c @@ -30,6 +30,7 @@ #include <linux/srcu.h> #include <linux/rcu_node_tree.h> +#include "rcu_segcblist.h" #include "rcu.h" static int init_srcu_struct_fields(struct srcu_struct *sp)
| |