@@ -685,10 +685,8 @@ static void cortex_a9_initfn(Object *obj)
#ifndef CONFIG_USER_ONLY
static uint64_t a15_l2ctlr_read(CPUARMState *env, const ARMCPRegInfo *ri)
{
- /* Linux wants the number of processors from here.
- * Might as well set the interrupt-controller bit too.
- */
- return ((smp_cpus - 1) << 24) | (1 << 23);
+ /* Linux wants the number of processors from here. */
+ return (smp_cpus - 1) << 24;
}
#endif
@@ -741,7 +739,7 @@ static const ARMCPRegInfo cortexa15_cp_reginfo[] = {
#ifndef CONFIG_USER_ONLY
{ .name = "L2CTLR", .cp = 15, .crn = 9, .crm = 0, .opc1 = 1, .opc2 = 2,
.access = PL1_RW, .resetvalue = 0, .readfn = a15_l2ctlr_read,
- .writefn = arm_cp_write_ignore, },
+ .writefn = arm_cp_write_ignore, .attr_mask = (3 << 24),},
#endif
{ .name = "L2ECTLR", .cp = 15, .crn = 9, .crm = 0, .opc1 = 1, .opc2 = 3,
.access = PL1_RW, .type = ARM_CP_CONST, .resetvalue = 0 },
The real hardware seems to not set the Interrupt Controller bit of the L2CTLR cp register; on the contrary it could set some other bits regarding RAM features that are not modelled in TCG, so we can mask them out. Signed-off-by: Alvise Rigo <a.rigo@virtualopensystems.com> --- target-arm/cpu.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-)