On PowerPC64 using Radix MMU, when partition or process table is not properly aligned, according to their size, an exception must be raised (DSI/ISI/HDSI/HISI) and the "Bad Radix Config" bit must be set in the appropriate register. Hardware and KVM already do this, but TCG was missing this part.
This patch series also improves the code that validates each Radix Tree level, by checking the number of levels and the size of each one. Finally, when DEBUG_MMU is defined, PDE/PTE base address alignment is also checked and reported, to make it easier to detect invalid configurations. Leandro Lupori (3): ppc: Check partition and process table alignment target/ppc: Improve Radix xlate level validation target/ppc: Check page dir/table base alignment hw/ppc/spapr.c | 5 +++ hw/ppc/spapr_hcall.c | 9 +++++ target/ppc/mmu-book3s-v3.c | 5 +++ target/ppc/mmu-radix64.c | 74 ++++++++++++++++++++++++++++++++------ 4 files changed, 82 insertions(+), 11 deletions(-) -- 2.25.1