[Cbe-oss-dev] Current upstream crash without CONFIG_NUMA
Benjamin Herrenschmidt
benh at kernel.crashing.org
Mon Oct 9 14:59:35 EST 2006
The current upstream code (linus tree) will crash if CONFIG_NUMA is not
set at boot time. In spu_base.c, the global list of SPUs is maintained
via an array of MAX_NUMNODES. The problem is that without CONFIG_NUMA,
it is set to 1, but we do access indexes in this array based on the SPU
nodes in the device-tree without checking.
What is the proper fix here ? Use a MAX_CBE thingy like we do in a
couple of other places (like the one in cbe_regs.c) ? Make CONFIG_NUMA
mandatory (select'ed) ? We still need to validate the nodes we get from
the device-tree against the size of the array though.
Ben.
More information about the cbe-oss-dev
mailing list