Messages in this thread | | | Date | Tue, 22 Mar 2022 15:59:20 +0000 | Subject | Re: [PATCH v2] cpu/hotplug: Set st->cpu earlier | From | Vincent Donnefort <> |
| |
On 22/03/2022 15:31, Thomas Gleixner wrote: > On Wed, Mar 16 2022 at 15:36, Steven Price wrote: >> Setting the 'cpu' member of struct cpuhp_cpu_state in cpuhp_create() is >> too late as other callbacks can be made before that point. > > What? > > CPUHP_OFFLINE = 0, > CPUHP_CREATE_THREADS, > > The create threads callback is the very first callback which is invoked > for a to be plugged CPU on the control CPU. So which earlier callback > can be invoked and fail? > > Thanks, > > tglx
CPUHP_CREATE_THREADS itself can fail, before st->cpu is set. Also, that value is used outside of the callbacks (cpuhp_set_state() in _cpu_up()).
But indeed this description could be refined a bit.
| |