On Tue, Aug 19, 2025 at 02:32:14PM +0200, Peter Zijlstra wrote: > On Tue, Aug 19, 2025 at 09:58:31AM +0800, Menglong Dong wrote: > > > diff --git a/kernel/sched/core.c b/kernel/sched/core.c > > index be00629f0ba4..00383fed9f63 100644 > > --- a/kernel/sched/core.c > > +++ b/kernel/sched/core.c > > @@ -119,6 +119,7 @@ EXPORT_TRACEPOINT_SYMBOL_GPL(sched_update_nr_running_tp); > > EXPORT_TRACEPOINT_SYMBOL_GPL(sched_compute_energy_tp); > > > > DEFINE_PER_CPU_SHARED_ALIGNED(struct rq, runqueues); > > +EXPORT_SYMBOL_GPL(runqueues); > > Oh no, absolutely not. > > You never, ever, export a variable, and certainly not this one. > > How about something like so? > > I tried 'clever' things with export inline, but the compiler hates me, > so the below is the best I could make work. extern inline, that is, obviously...