powerpc/machdep: Define 'compatible' property in ppc_md and use it
authorChristophe Leroy <christophe.leroy@csgroup.eu>
Sat, 18 Feb 2023 09:15:45 +0000 (10:15 +0100)
committerMichael Ellerman <mpe@ellerman.id.au>
Tue, 14 Mar 2023 13:52:10 +0000 (00:52 +1100)
commit2fc39acfcacf3dc1392d8062f6d7b7d94eb2537c
tree0f7ac1efaf52ebe3a4e602a06e1ac45511dd9709
parent35e175bdd52e75d4f9b1a6b3cea870c728acf344
powerpc/machdep: Define 'compatible' property in ppc_md and use it

Most probe functions do nothing else than checking whether
the machine is compatible to a given string.

Define that string in ppc_md structure and check it directly from
probe_machine() instead of using ppc_md.probe() for that.

Keep checking in ppc_md.probe() only for more complex probing.

Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://msgid.link/6cb9865d916231c38401ba34ad1a98c249fae135.1676711562.git.christophe.leroy@csgroup.eu
arch/powerpc/include/asm/machdep.h
arch/powerpc/kernel/setup-common.c