[Pdbg] [PATCH] main: Add P8 kernel devicetree

Joel Stanley joel at jms.id.au
Mon Aug 13 16:43:56 AEST 2018


On Mon, 13 Aug 2018 at 14:48, Alistair Popple <alistair at popple.id.au> wrote:
>
> Joel do you know if there is someway to differentiate between P8 and P9 on
> OpenBMC? This patch makes it mandatory to specify p8 vs. p9 on the command line
> which feels like a step backwards. If we can't do it from the BMC then we will
> have to probe it from the host.

I spent more time than I'd like to admit looking at this last week.

We could assume that ast2400 == p8, as it is true for all the machines
that exist to date.

I looked into geteauxval etc, but it appears there's no way to detect
you're on an ast2400 (or even just an ARM9) without parsing files. So
the 'best' we have would be to open up the device tree at
/sys/firmware, or parse /proc/cpuinfo.

The device tree would be neater.

Cheers,

Joel


More information about the Pdbg mailing list