rtc: omap: add helper to read 32-bit registers
authorJohan Hovold <[email protected]>
Wed, 10 Dec 2014 23:53:10 +0000 (15:53 -0800)
committerLinus Torvalds <[email protected]>
Thu, 11 Dec 2014 01:41:14 +0000 (17:41 -0800)
Add helper to read full register width.

Signed-off-by: Johan Hovold <[email protected]>
Cc: Alessandro Zummo <[email protected]>
Cc: Tony Lindgren <[email protected]>
Cc: Benot Cousson <[email protected]>
Cc: Lokesh Vutla <[email protected]>
Cc: Guenter Roeck <[email protected]>
Cc: Sekhar Nori <[email protected]>
Cc: Tero Kristo <[email protected]>
Cc: Keerthy J <[email protected]>
Tested-by: Felipe Balbi <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
drivers/rtc/rtc-omap.c

index bcdf3c5962149ec3d61f1c0e4377bd1f52bd67a4..c508e45ca3ce798e3c321d78814b5f20b18f73c0 100644 (file)
@@ -123,6 +123,11 @@ static inline u8 rtc_read(struct omap_rtc *rtc, unsigned int reg)
        return readb(rtc->base + reg);
 }
 
+static inline u32 rtc_readl(struct omap_rtc *rtc, unsigned int reg)
+{
+       return readl(rtc->base + reg);
+}
+
 static inline void rtc_write(struct omap_rtc *rtc, unsigned int reg, u8 val)
 {
        writeb(val, rtc->base + reg);