Page MenuHomeFreeBSD

[PPC64] Fix NUMA on POWER8
ClosedPublic

Authored by luporl on Jan 29 2020, 4:16 PM.
Referenced Files
Unknown Object (File)
Dec 20 2023, 3:22 AM
Unknown Object (File)
Nov 27 2023, 9:36 AM
Unknown Object (File)
Sep 6 2023, 9:50 AM
Unknown Object (File)
Sep 6 2023, 9:49 AM
Unknown Object (File)
Sep 6 2023, 9:48 AM
Unknown Object (File)
Sep 6 2023, 9:47 AM
Unknown Object (File)
Sep 6 2023, 9:46 AM
Unknown Object (File)
Sep 1 2023, 8:06 AM

Details

Summary

On some POWER8 machines, 'ibm,associativity' property may have 6
cells, which would overflow the 5 cells buffer being used.
There was also an issue with the "check if node is root" part,
that have been fixed too.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

sys/powerpc/powernv/platform_powernv.c
535–536 ↗(On Diff #67458)

I would suggest you just move this up, and not bother with the OF_getproplen(), just do

res = OF_getencprop(...)

if (res < 0) {
  ...
}
luporl added inline comments.
sys/powerpc/powernv/platform_powernv.c
535–536 ↗(On Diff #67458)

Right, it's better indeed.

sys/powerpc/powernv/platform_powernv.c
532–534 ↗(On Diff #67462)

I think this KASSERT() is unnecessary. A violation of this "invariant" is really a broken device tree, not a kernel bug. Maybe "if (res < sizeof(cell_t) * (platform_associativity + 1))" up above instead?

We can limp along with a busted device tree, we don't need to panic.

  • Address review comments
sys/powerpc/powernv/platform_powernv.c
532–534 ↗(On Diff #67462)

Right, do you think it's ok now?

This revision is now accepted and ready to land.Jan 29 2020, 5:59 PM
This revision was automatically updated to reflect the committed changes.