]> git.ipfire.org Git - thirdparty/qemu.git/commit
target/arm: Use the max page size in a 2-stage ptw
authorRichard Henderson <richard.henderson@linaro.org>
Mon, 24 Oct 2022 05:18:51 +0000 (15:18 +1000)
committerPeter Maydell <peter.maydell@linaro.org>
Thu, 27 Oct 2022 10:34:31 +0000 (11:34 +0100)
commitc8d6c286ab4bff1c5ff511f3e834fb2a713d65d2
tree5d419aef59422a08a3cbf84284cb21db4c0b3cdd
parent65c123fdf577413a7d910e6b07c10e79d118041f
target/arm: Use the max page size in a 2-stage ptw

We had only been reporting the stage2 page size.  This causes
problems if stage1 is using a larger page size (16k, 2M, etc),
but stage2 is using a smaller page size, because cputlb does
not set large_page_{addr,mask} properly.

Fix by using the max of the two page sizes.

Reported-by: Marc Zyngier <maz@kernel.org>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-id: 20221024051851.3074715-15-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
target/arm/ptw.c