diff options
Diffstat (limited to 'drivers/rtc/rtc-max77686.c')
-rw-r--r-- | drivers/rtc/rtc-max77686.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/rtc/rtc-max77686.c b/drivers/rtc/rtc-max77686.c index 9d71328e59b9..7632a87784c3 100644 --- a/drivers/rtc/rtc-max77686.c +++ b/drivers/rtc/rtc-max77686.c | |||
@@ -12,6 +12,8 @@ | |||
12 | * | 12 | * |
13 | */ | 13 | */ |
14 | 14 | ||
15 | #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt | ||
16 | |||
15 | #include <linux/slab.h> | 17 | #include <linux/slab.h> |
16 | #include <linux/rtc.h> | 18 | #include <linux/rtc.h> |
17 | #include <linux/delay.h> | 19 | #include <linux/delay.h> |
@@ -103,8 +105,8 @@ static int max77686_rtc_tm_to_data(struct rtc_time *tm, u8 *data) | |||
103 | data[RTC_YEAR] = tm->tm_year > 100 ? (tm->tm_year - 100) : 0; | 105 | data[RTC_YEAR] = tm->tm_year > 100 ? (tm->tm_year - 100) : 0; |
104 | 106 | ||
105 | if (tm->tm_year < 100) { | 107 | if (tm->tm_year < 100) { |
106 | pr_warn("%s: MAX77686 RTC cannot handle the year %d." | 108 | pr_warn("RTC cannot handle the year %d. Assume it's 2000.\n", |
107 | "Assume it's 2000.\n", __func__, 1900 + tm->tm_year); | 109 | 1900 + tm->tm_year); |
108 | return -EINVAL; | 110 | return -EINVAL; |
109 | } | 111 | } |
110 | return 0; | 112 | return 0; |