Issue in writing a data in PMU register

Hi,

Following are the query regarding the ARM Cortex A7 MP Core.

In ARM Cortex A7 MP Core,facing a issue in memory mapping the registers and accessing the registers by read and write operations.

By means of the reference manual the base configuration address has been read and set to the respective value.

I am not able to write the values by these assembly instruction " asm volatile("mcr p15, 0, %0, c9, c12, 0" : : "r"(0x07));" 0x07 is a data to be written to the PMU register.Even though the user enable register is set before writing the value to the register.

In the manual,the system control register holds a bit "WXN" [Write permission Execute Never] . According to my board,it was 0 (Regions with write permission are not forced to be XN, this is the reset value).Is this bit setting,blocks the write permissions to the other register?

Do i need to enable any register other than "PMUSERENR" before the write operation?

Parents
  • Hi,

    to access PMU registers which are memory mapped, the CPU should be in the debug mode.

    We ordinary access them via CP15 registers by using MCR/MRC instructions.

    Could you really set EN bit of PMUSERENR?

    If you could, I think you might access PMCR.

    PMCR.C and PMCR.P are write only bits and you will see they are always 0s.

    Could not you set even PMCR.E?

    If it could not, it would be strange.

    Can you show us the more detailed procedure you had been taken?

    Best regards,

    Yasuhiko Koumoto.

Reply
  • Hi,

    to access PMU registers which are memory mapped, the CPU should be in the debug mode.

    We ordinary access them via CP15 registers by using MCR/MRC instructions.

    Could you really set EN bit of PMUSERENR?

    If you could, I think you might access PMCR.

    PMCR.C and PMCR.P are write only bits and you will see they are always 0s.

    Could not you set even PMCR.E?

    If it could not, it would be strange.

    Can you show us the more detailed procedure you had been taken?

    Best regards,

    Yasuhiko Koumoto.

Children