On Mon, 14 Nov 2022 at 13:33, Jens Wiklander <jens.wiklan...@linaro.org> wrote: > > With commit 39f29e599355 ("hw/intc/arm_gicv3: Use correct number of > priority bits for the CPU") the number of priority bits was changed from > the maximum value 8 to typically 5. As a consequence a few of the lowest > bits in ICC_PMR_EL1 becomes RAZ/WI. However prior to this patch one of > these bits was still used since the supplied priority value is masked > before it's eventually right shifted with one bit. So the bit is not > lost as one might expect when the register is read again. > > The Linux kernel depends on lowest valid bit to be reset to zero, see > commit 33625282adaa ("irqchip/gic-v3: Probe for SCR_EL3 being clear > before resetting AP0Rn") for details. > > So fix this by masking the priority value after it may have been right > shifted by one bit. > > Fixes: 39f29e599355 ("hw/intc/arm_gicv3: Use correct number of priority bits > for the CPU") > Signed-off-by: Jens Wiklander <jens.wiklan...@linaro.org>
Thanks for the fix; applied to target-arm.next for 7.2. > I've only tested this patch on top of v7.1.0 since I couldn't get current > to run in my test setup. > > In case anyone wonders what I'm testing, it's a setup with Hafnium at > S-EL2, OP-TEE at S-EL1 and the Linux kernel at NS-EL1 (no NS-EL2 for > simplicity). Now is a good time to figure out what's not working with current QEMU, so that if it's a bug in QEMU we can fix it before the 7.2 release. Could you try a bisect of QEMU to see where it broke? Alternatively, if you have repro instructions and prebuilt image files I can have a look. thanks -- PMM