xref: /openbmc/linux/drivers/rtc/rtc-core.h (revision 33740c7f)
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifdef CONFIG_RTC_INTF_DEV
3 
4 extern void __init rtc_dev_init(void);
5 extern void rtc_dev_prepare(struct rtc_device *rtc);
6 
7 #else
8 
rtc_dev_init(void)9 static inline void rtc_dev_init(void)
10 {
11 }
12 
rtc_dev_prepare(struct rtc_device * rtc)13 static inline void rtc_dev_prepare(struct rtc_device *rtc)
14 {
15 }
16 
17 #endif
18 
19 #ifdef CONFIG_RTC_INTF_PROC
20 
21 extern void rtc_proc_add_device(struct rtc_device *rtc);
22 extern void rtc_proc_del_device(struct rtc_device *rtc);
23 
24 #else
25 
rtc_proc_add_device(struct rtc_device * rtc)26 static inline void rtc_proc_add_device(struct rtc_device *rtc)
27 {
28 }
29 
rtc_proc_del_device(struct rtc_device * rtc)30 static inline void rtc_proc_del_device(struct rtc_device *rtc)
31 {
32 }
33 
34 #endif
35 
36 #ifdef CONFIG_RTC_INTF_SYSFS
37 const struct attribute_group **rtc_get_dev_attribute_groups(void);
38 #else
rtc_get_dev_attribute_groups(void)39 static inline const struct attribute_group **rtc_get_dev_attribute_groups(void)
40 {
41 	return NULL;
42 }
43 #endif
44