Message ID | 2e5674d7022b539461595f0f42767baee132ed76.1454720020.git.alistair.francis@xilinx.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On 6 February 2016 at 00:55, Alistair Francis <alistair.francis@xilinx.com> wrote: > The Linux kernel accesses this register early in its setup. > > Signed-off-by: Christopher Covington <christopher.covington@linaro.org> > Signed-off-by: Alistair Francis <alistair.francis@xilinx.com> > --- > > target-arm/helper.c | 6 ++++++ > 1 file changed, 6 insertions(+) > > diff --git a/target-arm/helper.c b/target-arm/helper.c > index 8d401c6..b4bf6fa 100644 > --- a/target-arm/helper.c > +++ b/target-arm/helper.c > @@ -1094,6 +1094,12 @@ static const ARMCPRegInfo v7_cp_reginfo[] = { > .fieldoffset = offsetof(CPUARMState, cp15.c9_pmuserenr), > .resetvalue = 0, > .writefn = pmuserenr_write, .raw_writefn = raw_write }, > + { .name = "PMUSERENR_EL0", .state = ARM_CP_STATE_AA64, > + .opc0 = 3, .opc1 = 3, .crn = 9, .crm = 14, .opc2 = 0, > + .access = PL0_R | PL1_RW, > + .fieldoffset = offsetof(CPUARMState, cp15.c9_pmuserenr), > + .resetvalue = 0, > + .writefn = pmuserenr_write, .raw_writefn = raw_write }, Either this or the 32-bit version need to be marked ARM_CP_ALIAS. Otherwise Reviewed-by: Peter Maydell <peter.maydell@linaro.org> thanks -- PMM
diff --git a/target-arm/helper.c b/target-arm/helper.c index 8d401c6..b4bf6fa 100644 --- a/target-arm/helper.c +++ b/target-arm/helper.c @@ -1094,6 +1094,12 @@ static const ARMCPRegInfo v7_cp_reginfo[] = { .fieldoffset = offsetof(CPUARMState, cp15.c9_pmuserenr), .resetvalue = 0, .writefn = pmuserenr_write, .raw_writefn = raw_write }, + { .name = "PMUSERENR_EL0", .state = ARM_CP_STATE_AA64, + .opc0 = 3, .opc1 = 3, .crn = 9, .crm = 14, .opc2 = 0, + .access = PL0_R | PL1_RW, + .fieldoffset = offsetof(CPUARMState, cp15.c9_pmuserenr), + .resetvalue = 0, + .writefn = pmuserenr_write, .raw_writefn = raw_write }, { .name = "PMINTENSET", .cp = 15, .crn = 9, .crm = 14, .opc1 = 0, .opc2 = 1, .access = PL1_RW, .fieldoffset = offsetof(CPUARMState, cp15.c9_pminten),