diff options
author | Andy Shevchenko <andriy.shevchenko@linux.intel.com> | 2018-12-04 23:23:18 +0200 |
---|---|---|
committer | Alexandre Belloni <alexandre.belloni@bootlin.com> | 2018-12-10 22:39:54 +0100 |
commit | 8d2e6b22bbc609d08f22d3a63541d978ad729c6d (patch) | |
tree | 273f3ae724d0a6f14acb4ce2cf3bfa42133807c2 /drivers/rtc | |
parent | 1481376072460fee7f25f142f3e3dac81651dfb6 (diff) | |
download | linux-8d2e6b22bbc609d08f22d3a63541d978ad729c6d.tar.gz linux-8d2e6b22bbc609d08f22d3a63541d978ad729c6d.tar.bz2 linux-8d2e6b22bbc609d08f22d3a63541d978ad729c6d.zip |
rtc: pcf50633: Switch to use %ptR
Use %ptR instead of open coded variant to print content of
struct rtc_time in human readable format.
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Diffstat (limited to 'drivers/rtc')
-rw-r--r-- | drivers/rtc/rtc-pcf50633.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/drivers/rtc/rtc-pcf50633.c b/drivers/rtc/rtc-pcf50633.c index ef72b0c389d7..0eb05b1d0b94 100644 --- a/drivers/rtc/rtc-pcf50633.c +++ b/drivers/rtc/rtc-pcf50633.c @@ -131,9 +131,7 @@ static int pcf50633_rtc_read_time(struct device *dev, struct rtc_time *tm) pcf2rtc_time(tm, &pcf_tm); - dev_dbg(dev, "RTC_TIME: %u.%u.%u %u:%u:%u\n", - tm->tm_mday, tm->tm_mon, tm->tm_year, - tm->tm_hour, tm->tm_min, tm->tm_sec); + dev_dbg(dev, "RTC_TIME: %ptRr\n", tm); return 0; } @@ -146,9 +144,7 @@ static int pcf50633_rtc_set_time(struct device *dev, struct rtc_time *tm) rtc = dev_get_drvdata(dev); - dev_dbg(dev, "RTC_TIME: %u.%u.%u %u:%u:%u\n", - tm->tm_mday, tm->tm_mon, tm->tm_year, - tm->tm_hour, tm->tm_min, tm->tm_sec); + dev_dbg(dev, "RTC_TIME: %ptRr\n", tm); rtc2pcf_time(&pcf_tm, tm); |