aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/clocksource/timer-atmel-tcb.c
AgeCommit message (Collapse)Author
2018-11-28clocksource/drivers: timer-atmel-tcb: add clockevent device on separate channelAlexandre Belloni
Add an other clockevent device that uses a separate TCB channel when available. Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
2018-11-28clocksource/drivers: Add a new driver for the Atmel ARM TC blocksAlexandre Belloni
Add a driver for the Atmel Timer Counter Blocks. This driver provides a clocksource and two clockevent devices. One of the clockevent device is linked to the clocksource counter and so it will run at the same frequency. This will be used when there is only on TCB channel available for timers. The other clockevent device runs on a separate TCB channel when available. This driver uses regmap and syscon to be able to probe early in the boot and avoid having to switch on the TCB clocksource later. Using regmap also means that unused TCB channels may be used by other drivers (PWM for example). read/writel are still used to access channel specific registers to avoid the performance impact of regmap (mainly locking). Tested-by: Alexander Dahl <ada@thorsis.com> Tested-by: Andras Szemzo <szemzo.andras@gmail.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>