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

Issue virtual timer interrupt

Hi,

I am facing an issue where I am setting virtual timer to fire at particular interval (Juno PPI4 , interrupt no 27) from EL1NS mode and

when the timer interrupt happens the control is falling to EL2t IRQ handler rather than guest aarch64 IRQ handler. I confirm that I am setting EL1 to aarch64 state into HCR_EL2 register (RW = 1).

I see below register values -

PC = 0x80214480

VBAR_EL2 = 0x80214400

ESR_EL2 = 0x356ABA3B { EC = 13, IL = 16 bit instruction trapped, ISS = 23771707 }

                 

Does any one knows how to resolve this ?  I am not sure if i am missing anything ?

Thanks,

Parents
  • Hi Martin,

    My question is actually regarding which IRQ entry of vector table control will jump once it goes to EL2 mode ?

    I understand that all IRQs will be routed to EL2 mode if i set HCR_EL2.IMO = 1 but the vector table at EL2 mode has 4 entries for IRQ as below -

    0x80   (EL2/SP_EL0)

    0x280 (EL2/SP_EL2)

    0x480 (Guest OS aarch64)

    0x680 (Guest OS aarch32)

    Based on my understanding when IRQ arrives at EL1NS (aarch64) mode then control should jump to 0x480 vector entry ?

    What I am observing in my scenario is that it is reaching 0x80 (EL2/SP_EL0).

    So I am facing two issues -

    1) Why it is 0x80 if I am selecting SPSel = 1 and my Mode.M = 9 when I break through DS-5 ?

    2) It should reach to 0x480 ?

    Thanks.

Reply
  • Hi Martin,

    My question is actually regarding which IRQ entry of vector table control will jump once it goes to EL2 mode ?

    I understand that all IRQs will be routed to EL2 mode if i set HCR_EL2.IMO = 1 but the vector table at EL2 mode has 4 entries for IRQ as below -

    0x80   (EL2/SP_EL0)

    0x280 (EL2/SP_EL2)

    0x480 (Guest OS aarch64)

    0x680 (Guest OS aarch32)

    Based on my understanding when IRQ arrives at EL1NS (aarch64) mode then control should jump to 0x480 vector entry ?

    What I am observing in my scenario is that it is reaching 0x80 (EL2/SP_EL0).

    So I am facing two issues -

    1) Why it is 0x80 if I am selecting SPSel = 1 and my Mode.M = 9 when I break through DS-5 ?

    2) It should reach to 0x480 ?

    Thanks.

Children
  • If you put a breakpoint on both IRQ vector entries.  When you hit on the 0x80 entry, what do SPSR_EL2 and ELR_EL2 report?

    "1) Why it is 0x80 if I am selecting SPSel = 1 and my Mode.M = 9 when I break through DS-5 ?"

    Where/when are you selecting Mode.M=0x9?  Not sure I follow - but 0x9 is the value for EL2 not EL1.