I'm running bare metal on iMx25 PDK with debug board.
I'm trying to access UART register (USR1) on user mode but each time it raise a data abort.
Is hardware register only accessible from privileged mode ?
Documentation says I can read/write as user, may be I miss to configure a register but i don't know which one.
This is the exemple code I made to read USR1 at the boot.
// After a reset, the mode is ARM, Supervisor, interrupts disabled.
// Invalidate both ICache and DCache : not done upon emulator reset
// Disable MMU translation, D cache and enable I cache
ldr r0,=CP_DIS_MASK // 0xFFFFEFFA
// Initialize clocks
// Switch to user and try access USR1
bic r0,r0,#MODE_MSK // Clear the mode bits
orr r0,r0,#USR_MODE // Set USER mode bits
ldr r3, =0x43f90098
If you have any idea why I can't access uart register in user mode, any help is welcome.
Thanks in advance.