rtc-core.h 866 Bytes
Newer Older
1
/* SPDX-License-Identifier: GPL-2.0 */
2 3 4 5
#ifdef CONFIG_RTC_INTF_DEV

extern void __init rtc_dev_init(void);
extern void __exit rtc_dev_exit(void);
6
extern void rtc_dev_prepare(struct rtc_device *rtc);
7 8 9

#else

10 11 12 13 14 15 16 17
static inline void rtc_dev_init(void)
{
}

static inline void rtc_dev_exit(void)
{
}

18 19 20 21
static inline void rtc_dev_prepare(struct rtc_device *rtc)
{
}

22
#endif
23

24 25
#ifdef CONFIG_RTC_INTF_PROC

26 27
extern void rtc_proc_add_device(struct rtc_device *rtc);
extern void rtc_proc_del_device(struct rtc_device *rtc);
28 29 30

#else

31 32 33 34 35 36 37
static inline void rtc_proc_add_device(struct rtc_device *rtc)
{
}

static inline void rtc_proc_del_device(struct rtc_device *rtc)
{
}
38 39 40

#endif

41
#ifdef CONFIG_RTC_INTF_SYSFS
42
const struct attribute_group **rtc_get_dev_attribute_groups(void);
43
#else
44
static inline const struct attribute_group **rtc_get_dev_attribute_groups(void)
45
{
46
	return NULL;
47
}
48
#endif