This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

ARMv8 Foundation Model: writing to switches and leds

Hi everyone,

as I asked on http://stackoverflow.com/questions/25907502/armv8-foundation-model-switches-and-leds, I am trying to write

a value to the "switches" and "leds" register of the Foundation Model, to get some feedback (I've got some UART issues to debug).

All attemps to write to these registers are failing, even just after boot at EL3 in 64 bits mode.

I recently discovered that I got a synchronous exception classified  as External.

ESR_EL3 is 0x96000250 (Exception class 0x250, Data Abort, IL is 32 bits and ISS explains that a external abort on write has occured).

ARM's user manual for the model specifies that these registers are R/W registers. Did I miss something to be able to modify them by software ?

Best,

Vincent

Parents
  • Hi Simon,

    I tried to write on the address 0x1c010004 which I got from the Foundation User guide (--version is ARM V8 Foundation Model r0p0 (model build 9.0.24)).

    The FAR_EL3 register holds the exact same address.

    For the record, I start the model using the following line:

    Foundation_v8 --no-secure-memory --cores=1 --no-gicv3 --visualization --image kernel.elf --switches=0xbb

    I first read the switches with a LDRB instruction, which goes fine and display the initial 0xbb value.

    It is only the writing that fails. I switched from STRB to STR and now the error is gone, and the switches are correctly updated, thank you very much for the suggestion.

    Do you have some hints on why using STRB instead of STR would trigger such an exception ?

    Best,

    Vincent

Reply
  • Hi Simon,

    I tried to write on the address 0x1c010004 which I got from the Foundation User guide (--version is ARM V8 Foundation Model r0p0 (model build 9.0.24)).

    The FAR_EL3 register holds the exact same address.

    For the record, I start the model using the following line:

    Foundation_v8 --no-secure-memory --cores=1 --no-gicv3 --visualization --image kernel.elf --switches=0xbb

    I first read the switches with a LDRB instruction, which goes fine and display the initial 0xbb value.

    It is only the writing that fails. I switched from STRB to STR and now the error is gone, and the switches are correctly updated, thank you very much for the suggestion.

    Do you have some hints on why using STRB instead of STR would trigger such an exception ?

    Best,

    Vincent

Children