]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
MFC r342852 (by cem): powerpc: Fix regression introduced in r342771
authorAlexander Motin <mav@FreeBSD.org>
Fri, 11 Sep 2020 15:30:47 +0000 (15:30 +0000)
committerAlexander Motin <mav@FreeBSD.org>
Fri, 11 Sep 2020 15:30:47 +0000 (15:30 +0000)
commitf76742c89277060d0a1830fb51068d1573893483
tree10e12feade9e37e74e8da8814ec32f83330bbc6d
parent83d5345ea83dfbd2c5a903428aedb98c21a2b51f
MFC r342852 (by cem): powerpc: Fix regression introduced in r342771

In r342771, I introduced a regression in Power by abusing the platform
smp_topo() method as a shortcut for providing the MI information needed for
the stated sysctls.  The smp_topo() method was already called later by
sched_ule (under the name cpu_topo()), and initializes a static array of
scheduler topology information.  I had skimmed the smp_topo_foo() functions
and assumed they were idempotent; empirically, they are not (or at least,
detect re-initialization and panic).

Do the cleaner thing I should have done in the first place and add a
platform method specifically for core- and thread-count probing.

PR: 249250
Approved by: re (gjb)
sys/powerpc/include/platform.h
sys/powerpc/powernv/platform_powernv.c
sys/powerpc/powerpc/mp_machdep.c
sys/powerpc/powerpc/platform.c
sys/powerpc/powerpc/platform_if.m
sys/powerpc/ps3/platform_ps3.c
sys/powerpc/pseries/platform_chrp.c