Source
124
124
dev_dbg(dev, "PCF_TIME: %02x.%02x.%02x %02x:%02x:%02x\n",
125
125
pcf_tm.time[PCF50633_TI_DAY],
126
126
pcf_tm.time[PCF50633_TI_MONTH],
127
127
pcf_tm.time[PCF50633_TI_YEAR],
128
128
pcf_tm.time[PCF50633_TI_HOUR],
129
129
pcf_tm.time[PCF50633_TI_MIN],
130
130
pcf_tm.time[PCF50633_TI_SEC]);
131
131
132
132
pcf2rtc_time(tm, &pcf_tm);
133
133
134
-
dev_dbg(dev, "RTC_TIME: %u.%u.%u %u:%u:%u\n",
135
-
tm->tm_mday, tm->tm_mon, tm->tm_year,
136
-
tm->tm_hour, tm->tm_min, tm->tm_sec);
134
+
dev_dbg(dev, "RTC_TIME: %ptRr\n", tm);
137
135
138
136
return 0;
139
137
}
140
138
141
139
static int pcf50633_rtc_set_time(struct device *dev, struct rtc_time *tm)
142
140
{
143
141
struct pcf50633_rtc *rtc;
144
142
struct pcf50633_time pcf_tm;
145
143
int alarm_masked, ret = 0;
146
144
147
145
rtc = dev_get_drvdata(dev);
148
146
149
-
dev_dbg(dev, "RTC_TIME: %u.%u.%u %u:%u:%u\n",
150
-
tm->tm_mday, tm->tm_mon, tm->tm_year,
151
-
tm->tm_hour, tm->tm_min, tm->tm_sec);
147
+
dev_dbg(dev, "RTC_TIME: %ptRr\n", tm);
152
148
153
149
rtc2pcf_time(&pcf_tm, tm);
154
150
155
151
dev_dbg(dev, "PCF_TIME: %02x.%02x.%02x %02x:%02x:%02x\n",
156
152
pcf_tm.time[PCF50633_TI_DAY],
157
153
pcf_tm.time[PCF50633_TI_MONTH],
158
154
pcf_tm.time[PCF50633_TI_YEAR],
159
155
pcf_tm.time[PCF50633_TI_HOUR],
160
156
pcf_tm.time[PCF50633_TI_MIN],
161
157
pcf_tm.time[PCF50633_TI_SEC]);