Home
last modified time | relevance | path

Searched hist:"740 e237a" (Results 1 – 1 of 1) sorted by relevance

/linux/drivers/clocksource/
H A Dtimer-fttmr010.c740e237a Sun Jun 11 21:26:16 GMT 2017 Linus Walleij <linus.walleij@linaro.org> clocksource/drivers/fttmr010: Optimize sched_clock()

The sched_clock() call should be really fast so we want to
avoid an extra if() clause on the read path if possible.

Implement two sched_clock_read() functions, one if the timer
counts up and one if it counts down. Incidentally this also
mirrors how clocksource_mmio_init() works and make things
simple and easy to understand.

Suggested-by: Daniel Lezcano <daniel.lezcano@linaro.org>
Cc: Andrew Jeffery <andrew@aj.id.au>
Cc: Joel Stanley <joel@jms.id.au>
Cc: Jonas Jensen <jonas.jensen@gmail.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>