OSDN Git Service

target/arm: generate a custom MIDR for -cpu max
authorAlex Bennée <alex.bennee@linaro.org>
Thu, 15 Aug 2019 08:46:41 +0000 (09:46 +0100)
committerPeter Maydell <peter.maydell@linaro.org>
Fri, 16 Aug 2019 13:02:48 +0000 (14:02 +0100)
commit2bd5f41c00686a1f847a60824d0375f3df2c26bf
tree47f74aa46b4f64f9f60f38f878bfebf15299d045
parent27608c7c66bd923eb5e5faab80e795408cbe2b51
target/arm: generate a custom MIDR for -cpu max

While most features are now detected by probing the ID_* registers
kernels can (and do) use MIDR_EL1 for working out of they have to
apply errata. This can trip up warnings in the kernel as it tries to
work out if it should apply workarounds to features that don't
actually exist in the reported CPU type.

Avoid this problem by synthesising our own MIDR value.

Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-id: 20190726113950.7499-1-alex.bennee@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
target/arm/cpu.h
target/arm/cpu64.c