summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorRussell King <rmk+kernel@armlinux.org.uk>2017-09-23 10:31:33 +0100
committerRussell King (Oracle) <rmk+kernel@armlinux.org.uk>2022-01-12 12:13:30 +0000
commit556ae44baf9ad0d6b9ee0daabc850e0dbf9e2bd3 (patch)
tree05253edc9a81fb296a052bd32f9bbdf1891d26b6 /include
parent346def82f72d61787918e02cccfb1678d5533e2b (diff)
rtc: pre-register hook
Add a pre-register hook to allow RTC drivers to adjust the default set_offset_nsec value. Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Diffstat (limited to 'include')
-rw-r--r--include/linux/rtc.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/rtc.h b/include/linux/rtc.h
index 47fd1c2d3a57..e864cf861bb4 100644
--- a/include/linux/rtc.h
+++ b/include/linux/rtc.h
@@ -44,6 +44,8 @@ static inline time64_t rtc_tm_sub(struct rtc_time *lhs, struct rtc_time *rhs)
extern struct class *rtc_class;
+struct rtc_device;
+
/*
* For these RTC methods the device parameter is the physical device
* on whatever bus holds the hardware (I2C, Platform, SPI, etc), which
@@ -68,6 +70,7 @@ struct rtc_class_ops {
int (*set_offset)(struct device *, long offset);
int (*param_get)(struct device *, struct rtc_param *param);
int (*param_set)(struct device *, struct rtc_param *param);
+ void (*pre_register)(struct rtc_device *);
};
struct rtc_device;