watchdog: orion: Use atomic access for shared registers
authorEzequiel Garcia <ezequiel.garcia@free-electrons.com>
Mon, 10 Feb 2014 23:00:21 +0000 (20:00 -0300)
committerJason Cooper <jason@lakedaemon.net>
Sat, 22 Feb 2014 03:42:42 +0000 (03:42 +0000)
commitfc8cd2ac0ad8fca1ca4699da53e635b3e9cc35ed
tree8bcfbf309e1addc002e5c8d6435a7ae5b1e03c76
parentbb02c662d641d51ea8c3ae9c828e89fbcfe04ba7
watchdog: orion: Use atomic access for shared registers

Since the timer control register is shared with the clocksource driver,
use the recently introduced atomic_io_clear_set() to access such register.
Given the watchdog core already provides serialization for all the
watchdog ops, this commit allows to remove the spinlock entirely.

Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Tested-by: Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>
Tested-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Ezequiel Garcia <ezequiel.garcia@free-electrons.com>
Acked-by: Wim Van Sebroeck <wim@iguana.be>
Tested-By: Jason Gunthorpe <jgunthorpe@obsidianresearch.com>
Signed-off-by: Jason Cooper <jason@lakedaemon.net>
drivers/watchdog/orion_wdt.c