[PATCH 0/2] Skip offline cores when enabling SMT on PowerPC

Shrikanth Hegde sshegde at linux.ibm.com
Tue Jun 25 05:11:31 AEST 2024



On 6/24/24 1:44 AM, Thomas Gleixner wrote:
> Michael!
> 
> On Thu, Jun 13 2024 at 21:34, Michael Ellerman wrote:
>> IIUIC the regression was in the ppc64_cpu userspace tool, which switched
>> to using the new kernel interface without taking into account the way it
>> behaves.
>>
>> Or are you saying the kernel behaviour changed on x86 after the powerpc
>> HOTPLUG_SMT was added?
> 
> No. The mechanism was always this way. Only offline nodes have been
> skipped. x86 never checked for the core being online.
> 
>> It's only x86 and powerpc right?
>>
>> Having different behaviour on the only two arches that support the
>> interface does not seem like a good result.
>>
>>> What is the expected behaviour on x86 when enabling SMT and certain cores
>>> are offline? 
>>
>> AFAIK no one really touches SMT on x86 other than to turn it off for
>> security reasons.
> 
> Right. So changing it not to online a thread when the full core is
> offline should not really break stuff.
> 
> OTH, the mechanism to figure that out on x86 is definitely different and
> more complicated than on power because the sibling threads are not
> having consecutive CPU numbers.

wouldn't topology_sibling_cpumask have this info? 
If the mask is empty does it mean the core is offline? 

> 
> So I'm not sure whether it's worth to make this consistent and I
> definitely can live with the proposed patches.
> 
> Thanks,
> 
>         tglx


More information about the Linuxppc-dev mailing list