diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/rtc/rtc-bfin.c | 26 |
1 files changed, 12 insertions, 14 deletions
diff --git a/drivers/rtc/rtc-bfin.c b/drivers/rtc/rtc-bfin.c index 2a801f237c5d..343f2849106d 100644 --- a/drivers/rtc/rtc-bfin.c +++ b/drivers/rtc/rtc-bfin.c | |||
@@ -45,7 +45,7 @@ | |||
45 | 45 | ||
46 | #include <asm/blackfin.h> | 46 | #include <asm/blackfin.h> |
47 | 47 | ||
48 | #define stamp(fmt, args...) pr_debug("%s:%i: " fmt "\n", __FUNCTION__, __LINE__, ## args) | 48 | #define stamp(fmt, args...) pr_debug("%s:%i: " fmt "\n", __func__, __LINE__, ## args) |
49 | #define stampit() stamp("here i am") | 49 | #define stampit() stamp("here i am") |
50 | 50 | ||
51 | struct bfin_rtc { | 51 | struct bfin_rtc { |
@@ -343,22 +343,20 @@ static int bfin_rtc_set_alarm(struct device *dev, struct rtc_wkalrm *alrm) | |||
343 | 343 | ||
344 | static int bfin_rtc_proc(struct device *dev, struct seq_file *seq) | 344 | static int bfin_rtc_proc(struct device *dev, struct seq_file *seq) |
345 | { | 345 | { |
346 | #define yesno(x) (x ? "yes" : "no") | 346 | #define yesno(x) ((x) ? "yes" : "no") |
347 | u16 ictl = bfin_read_RTC_ICTL(); | 347 | u16 ictl = bfin_read_RTC_ICTL(); |
348 | stampit(); | 348 | stampit(); |
349 | seq_printf(seq, "alarm_IRQ\t: %s\n", yesno(ictl & RTC_ISTAT_ALARM)); | 349 | seq_printf(seq, |
350 | seq_printf(seq, "wkalarm_IRQ\t: %s\n", yesno(ictl & RTC_ISTAT_ALARM_DAY)); | 350 | "alarm_IRQ\t: %s\n" |
351 | seq_printf(seq, "seconds_IRQ\t: %s\n", yesno(ictl & RTC_ISTAT_SEC)); | 351 | "wkalarm_IRQ\t: %s\n" |
352 | seq_printf(seq, "periodic_IRQ\t: %s\n", yesno(ictl & RTC_ISTAT_STOPWATCH)); | 352 | "seconds_IRQ\t: %s\n" |
353 | #ifdef DEBUG | 353 | "periodic_IRQ\t: %s\n", |
354 | seq_printf(seq, "RTC_STAT\t: 0x%08X\n", bfin_read_RTC_STAT()); | 354 | yesno(ictl & RTC_ISTAT_ALARM), |
355 | seq_printf(seq, "RTC_ICTL\t: 0x%04X\n", bfin_read_RTC_ICTL()); | 355 | yesno(ictl & RTC_ISTAT_ALARM_DAY), |
356 | seq_printf(seq, "RTC_ISTAT\t: 0x%04X\n", bfin_read_RTC_ISTAT()); | 356 | yesno(ictl & RTC_ISTAT_SEC), |
357 | seq_printf(seq, "RTC_SWCNT\t: 0x%04X\n", bfin_read_RTC_SWCNT()); | 357 | yesno(ictl & RTC_ISTAT_STOPWATCH)); |
358 | seq_printf(seq, "RTC_ALARM\t: 0x%08X\n", bfin_read_RTC_ALARM()); | ||
359 | seq_printf(seq, "RTC_PREN\t: 0x%04X\n", bfin_read_RTC_PREN()); | ||
360 | #endif | ||
361 | return 0; | 358 | return 0; |
359 | #undef yesno | ||
362 | } | 360 | } |
363 | 361 | ||
364 | /** | 362 | /** |