diff options
author | David Brownell <david-b@pacbell.net> | 2007-05-08 03:33:45 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-05-08 14:15:18 -0400 |
commit | 61a7c36acb3da406d64c0da6288eab1c414a65ea (patch) | |
tree | da99d77ca110e32586d829b88eacce80968d8460 /drivers | |
parent | 7ca1d488ffe4817adaba61cc05b972782f7d3f91 (diff) |
RTC: replace some newly-introduced macros with inlines
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/rtc/rtc-core.h | 46 |
1 files changed, 35 insertions, 11 deletions
diff --git a/drivers/rtc/rtc-core.h b/drivers/rtc/rtc-core.h index 4675a9fd5b14..d81a278fcded 100644 --- a/drivers/rtc/rtc-core.h +++ b/drivers/rtc/rtc-core.h | |||
@@ -7,22 +7,38 @@ extern void rtc_dev_del_device(struct rtc_device *rtc); | |||
7 | 7 | ||
8 | #else | 8 | #else |
9 | 9 | ||
10 | #define rtc_dev_init() do{}while(0) | 10 | static inline void rtc_dev_init(void) |
11 | #define rtc_dev_exit() do{}while(0) | 11 | { |
12 | #define rtc_dev_add_device(r) do{}while(0) | 12 | } |
13 | #define rtc_dev_del_device(r) do{}while(0) | 13 | |
14 | static inline void rtc_dev_exit(void) | ||
15 | { | ||
16 | } | ||
17 | |||
18 | static inline void rtc_dev_add_device(struct rtc_device *rtc) | ||
19 | { | ||
20 | } | ||
21 | |||
22 | static inline void rtc_dev_del_device(struct rtc_device *rtc) | ||
23 | { | ||
24 | } | ||
14 | 25 | ||
15 | #endif | 26 | #endif |
16 | 27 | ||
17 | #ifdef CONFIG_RTC_INTF_PROC | 28 | #ifdef CONFIG_RTC_INTF_PROC |
18 | 29 | ||
19 | void rtc_proc_add_device(struct rtc_device *rtc); | 30 | extern void rtc_proc_add_device(struct rtc_device *rtc); |
20 | void rtc_proc_del_device(struct rtc_device *rtc); | 31 | extern void rtc_proc_del_device(struct rtc_device *rtc); |
21 | 32 | ||
22 | #else | 33 | #else |
23 | 34 | ||
24 | #define rtc_proc_add_device(r) do{}while(0) | 35 | static inline void rtc_proc_add_device(struct rtc_device *rtc) |
25 | #define rtc_proc_del_device(r) do{}while(0) | 36 | { |
37 | } | ||
38 | |||
39 | static inline void rtc_proc_del_device(struct rtc_device *rtc) | ||
40 | { | ||
41 | } | ||
26 | 42 | ||
27 | #endif | 43 | #endif |
28 | 44 | ||
@@ -34,8 +50,16 @@ extern void rtc_sysfs_del_device(struct rtc_device *rtc); | |||
34 | 50 | ||
35 | #else | 51 | #else |
36 | 52 | ||
37 | #define rtc_sysfs_init(c) do{}while(0) | 53 | static inline void rtc_sysfs_init(struct class *rtc) |
38 | #define rtc_sysfs_add_device(r) do{}while(0) | 54 | { |
39 | #define rtc_sysfs_del_device(r) do{}while(0) | 55 | } |
56 | |||
57 | static inline void rtc_sysfs_add_device(struct rtc_device *rtc) | ||
58 | { | ||
59 | } | ||
60 | |||
61 | static inline void rtc_sysfs_del_device(struct rtc_device *rtc) | ||
62 | { | ||
63 | } | ||
40 | 64 | ||
41 | #endif | 65 | #endif |