]> www.infradead.org Git - users/dwmw2/qemu.git/commit
target/ppc: Reduce code duplication across Power9/10 init code
authorHarsh Prateek Bora <harshpb@linux.ibm.com>
Wed, 31 Jul 2024 05:50:18 +0000 (11:20 +0530)
committerNicholas Piggin <npiggin@gmail.com>
Sun, 3 Nov 2024 23:10:32 +0000 (09:10 +1000)
commitf41e7f7694b34e710b4d78947825734f0727683a
treebbf82aaa9a458b701cc4b7792a1eed7380078b80
parentc1a13064e3371b6ff2d8204a105a693c659afaf8
target/ppc: Reduce code duplication across Power9/10 init code

Power9/10 initialization code consists of a lot of logical OR of
various flag bits as supported by respective Power platform during its
initialization, most of which is duplicated and only selected bits are
added or removed as needed with each new platform support being added.
Remove the duplicate code and share using common macros.

Reviewed-by: Nicholas Piggin <npiggin@gmail.com>
Signed-off-by: Harsh Prateek Bora <harshpb@linux.ibm.com>
[adityag: renamed many POWERPC_* flags to PPC_* flags, checkpatch fixes]
Signed-off-by: Aditya Gupta <adityag@linux.ibm.com>
Tested-by: Amit Machhiwal <amachhiw@linux.ibm.com>
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
target/ppc/cpu_init.c
target/ppc/cpu_init.h [new file with mode: 0644]