mirror of
https://github.com/torvalds/linux.git
synced 2024-12-29 14:21:47 +00:00
77ba83bb1b
This patch adds a clocksource/clockevent driver for the timer found on some models in the TI-Nspire calculator series. The timer has two 16bit subtimers within its memory mapped I/O interface but only the first can generate interrupts. The first subtimer is used to generate clockevents but only if an interrupt number and register is given. The interrupt acknowledgement mechanism is a little strange because the interrupt mask and acknowledge registers are located in another memory mapped I/O peripheral. The address of this register is passed to the driver through device tree bindings. The second subtimer is used as a clocksource because it isn't capable of generating an interrupt. This subtimer is always added. Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Daniel Tang <dt.tangr@gmail.com> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
34 lines
719 B
Plaintext
34 lines
719 B
Plaintext
TI-NSPIRE timer
|
|
|
|
Required properties:
|
|
|
|
- compatible : should be "lsi,zevio-timer".
|
|
- reg : The physical base address and size of the timer (always first).
|
|
- clocks: phandle to the source clock.
|
|
|
|
Optional properties:
|
|
|
|
- interrupts : The interrupt number of the first timer.
|
|
- reg : The interrupt acknowledgement registers
|
|
(always after timer base address)
|
|
|
|
If any of the optional properties are not given, the timer is added as a
|
|
clock-source only.
|
|
|
|
Example:
|
|
|
|
timer {
|
|
compatible = "lsi,zevio-timer";
|
|
reg = <0x900D0000 0x1000>, <0x900A0020 0x8>;
|
|
interrupts = <19>;
|
|
clocks = <&timer_clk>;
|
|
};
|
|
|
|
Example (no clock-events):
|
|
|
|
timer {
|
|
compatible = "lsi,zevio-timer";
|
|
reg = <0x900D0000 0x1000>;
|
|
clocks = <&timer_clk>;
|
|
};
|