AnsweredAssumed Answered

Using generic timer on LS1043ARBD

Question asked by Jouni Sillanpää on Sep 22, 2016
Latest reply on Sep 22, 2016 by Pavel Chubakov

Hi,

 

I want to use ARM generic timer for triggering interrupt after a certain period but I'm having difficulties understanding how to set it up.  First of all it seems that there is no support for accessing the CompareValue registers (in arch/arm64/include/asm/arch_timer.h) so I guess I have to use the TimeValue view (TVAL) register? Another thing is that apparently Linux is using the non-secure physical counter so I should probaply use the virtual counters?  Now, if I configure the CNTV_TVAL_EL0, Counter-timer Virtual Timer TimerValue register it should trigger interrupt in GIC 27, right? If I check the /proc/interrupts there are only lines GIC 29 and 30 for arch_timer which means (to my understanding) that they are used by the arch_timer driver. Now, should the interrupt from Virtual timer counter be visible in /proc/stat or do I have to do some tricks to enable/unmask it?

Outcomes