Lines Matching refs:t
223 static int cmos_read_time(struct device *dev, struct rtc_time *t) in cmos_read_time() argument
234 ret = mc146818_get_time(t, 1000); in cmos_read_time()
243 static int cmos_set_time(struct device *dev, struct rtc_time *t) in cmos_set_time() argument
249 return mc146818_set_time(t); in cmos_set_time()
285 static int cmos_read_alarm(struct device *dev, struct rtc_wkalrm *t) in cmos_read_alarm() argument
290 .time = &t->time, in cmos_read_alarm()
314 if (((unsigned)t->time.tm_sec) < 0x60) in cmos_read_alarm()
315 t->time.tm_sec = bcd2bin(t->time.tm_sec); in cmos_read_alarm()
317 t->time.tm_sec = -1; in cmos_read_alarm()
318 if (((unsigned)t->time.tm_min) < 0x60) in cmos_read_alarm()
319 t->time.tm_min = bcd2bin(t->time.tm_min); in cmos_read_alarm()
321 t->time.tm_min = -1; in cmos_read_alarm()
322 if (((unsigned)t->time.tm_hour) < 0x24) in cmos_read_alarm()
323 t->time.tm_hour = bcd2bin(t->time.tm_hour); in cmos_read_alarm()
325 t->time.tm_hour = -1; in cmos_read_alarm()
328 if (((unsigned)t->time.tm_mday) <= 0x31) in cmos_read_alarm()
329 t->time.tm_mday = bcd2bin(t->time.tm_mday); in cmos_read_alarm()
331 t->time.tm_mday = -1; in cmos_read_alarm()
334 if (((unsigned)t->time.tm_mon) <= 0x12) in cmos_read_alarm()
335 t->time.tm_mon = bcd2bin(t->time.tm_mon)-1; in cmos_read_alarm()
337 t->time.tm_mon = -1; in cmos_read_alarm()
342 t->enabled = !!(p.rtc_control & RTC_AIE); in cmos_read_alarm()
343 t->pending = 0; in cmos_read_alarm()
406 static int cmos_validate_alarm(struct device *dev, struct rtc_wkalrm *t) in cmos_validate_alarm() argument
419 t_alrm = rtc_tm_to_time64(&t->time); in cmos_validate_alarm()
443 t_alrm = rtc_tm_to_time64(&t->time); in cmos_validate_alarm()
462 t_alrm = rtc_tm_to_time64(&t->time); in cmos_validate_alarm()
476 struct rtc_wkalrm *t; member
508 hpet_set_alarm_time(p->t->time.tm_hour, p->t->time.tm_min, in cmos_set_alarm_callback()
509 p->t->time.tm_sec); in cmos_set_alarm_callback()
512 if (p->t->enabled) in cmos_set_alarm_callback()
516 static int cmos_set_alarm(struct device *dev, struct rtc_wkalrm *t) in cmos_set_alarm() argument
521 .t = t in cmos_set_alarm()
530 ret = cmos_validate_alarm(dev, t); in cmos_set_alarm()
534 p.mon = t->time.tm_mon + 1; in cmos_set_alarm()
535 p.mday = t->time.tm_mday; in cmos_set_alarm()
536 p.hrs = t->time.tm_hour; in cmos_set_alarm()
537 p.min = t->time.tm_min; in cmos_set_alarm()
538 p.sec = t->time.tm_sec; in cmos_set_alarm()
562 cmos->alarm_expires = rtc_tm_to_time64(&t->time); in cmos_set_alarm()