On 01/02/2019 14:39, Joseph Lo wrote:
On 2/1/19 8:44 PM, Jon Hunter wrote:
On 01/02/2019 03:36, Joseph Lo wrote:
Add support for the Tegra210 timer that runs at oscillator clock
(TMR10-TMR13). We need these timers to work as clock event device and to
replace the ARMv8 architected timer due to it can't survive across the
power cycle of the CPU core or CPUPORESET signal. So it can't be a
source when CPU suspends in power down state.
Also convert the original driver to use timer-of API.
It may have been nice to split this into 2 patches to make it easier to
see what is going on but not a big deal.
Cc: Daniel Lezcano <daniel.lezcano@xxxxxxxxxx>
Cc: Thomas Gleixner <tglx@xxxxxxxxxxxxx>
Signed-off-by: Joseph Lo <josephl@xxxxxxxxxx>
Acked-by: Thierry Reding <treding@xxxxxxxxxx>
This can't get the timer base address. I think you mean ...
+#define TIMER_CPU0 0x50 /* TIMER3 */
+#define TIMER_CPU0 0x90 /* TIMER10 */
+#define TIMER_BASE_FOR_CPU(cpu) (TIMER_CPU0 + (cpu) * 8)
Ah I see.
This doesn't need.How come? Don't you still need to know the timer index for a given CPU?
+#define TIMER_FOR_CPU(cpu) (TIMER_CPU0 + cpu)