Lines Matching full:alarm

210 	struct rtc_wkalrm alarm;  in rtc_dev_ioctl()  local
251 * RTC and alarm times will be in UTC, by preference, in rtc_dev_ioctl()
260 err = rtc_read_alarm(rtc, &alarm); in rtc_dev_ioctl()
264 if (copy_to_user(uarg, &alarm.time, sizeof(tm))) in rtc_dev_ioctl()
271 if (copy_from_user(&alarm.time, uarg, sizeof(tm))) in rtc_dev_ioctl()
274 alarm.enabled = 0; in rtc_dev_ioctl()
275 alarm.pending = 0; in rtc_dev_ioctl()
276 alarm.time.tm_wday = -1; in rtc_dev_ioctl()
277 alarm.time.tm_yday = -1; in rtc_dev_ioctl()
278 alarm.time.tm_isdst = -1; in rtc_dev_ioctl()
282 * for day/month/year fields, just force the alarm to have in rtc_dev_ioctl()
287 * doesn't have the "alarm 23:59:59 in the future" race. in rtc_dev_ioctl()
290 * wildcards, exposing hardware "periodic alarm" capabilities. in rtc_dev_ioctl()
301 alarm.time.tm_mday = tm.tm_mday; in rtc_dev_ioctl()
302 alarm.time.tm_mon = tm.tm_mon; in rtc_dev_ioctl()
303 alarm.time.tm_year = tm.tm_year; in rtc_dev_ioctl()
304 err = rtc_valid_tm(&alarm.time); in rtc_dev_ioctl()
307 then = rtc_tm_to_time64(&alarm.time); in rtc_dev_ioctl()
309 /* alarm may need to wrap into tomorrow */ in rtc_dev_ioctl()
312 alarm.time.tm_mday = tm.tm_mday; in rtc_dev_ioctl()
313 alarm.time.tm_mon = tm.tm_mon; in rtc_dev_ioctl()
314 alarm.time.tm_year = tm.tm_year; in rtc_dev_ioctl()
318 return rtc_set_alarm(rtc, &alarm); in rtc_dev_ioctl()
372 if (copy_from_user(&alarm, uarg, sizeof(alarm))) in rtc_dev_ioctl()
375 return rtc_set_alarm(rtc, &alarm); in rtc_dev_ioctl()
379 err = rtc_read_alarm(rtc, &alarm); in rtc_dev_ioctl()
383 if (copy_to_user(uarg, &alarm, sizeof(alarm))) in rtc_dev_ioctl()
511 * Leave the alarm alone; it may be set to trigger a system wakeup in rtc_dev_release()