Lines Matching full:alarm
24 * Bit 2: Alarm on, 0 = off, 1 = on
28 /* default setting, buffer disabled, alarm on */
30 /* Alarm when AL0-AL3 == TI0-TI3 */
112 static int ab3100_rtc_read_alarm(struct device *dev, struct rtc_wkalrm *alarm) in ab3100_rtc_read_alarm() argument
120 /* Figure out if alarm is enabled or not */ in ab3100_rtc_read_alarm()
126 alarm->enabled = 1; in ab3100_rtc_read_alarm()
128 alarm->enabled = 0; in ab3100_rtc_read_alarm()
130 alarm->pending = 0; in ab3100_rtc_read_alarm()
131 /* Read out alarm registers, only 4 bytes */ in ab3100_rtc_read_alarm()
140 rtc_time64_to_tm(time, &alarm->time); in ab3100_rtc_read_alarm()
142 return rtc_valid_tm(&alarm->time); in ab3100_rtc_read_alarm()
145 static int ab3100_rtc_set_alarm(struct device *dev, struct rtc_wkalrm *alarm) in ab3100_rtc_set_alarm() argument
154 secs = rtc_tm_to_time64(&alarm->time); in ab3100_rtc_set_alarm()
161 /* Set the alarm */ in ab3100_rtc_set_alarm()
168 /* Then enable the alarm */ in ab3100_rtc_set_alarm()
171 alarm->enabled << 2); in ab3100_rtc_set_alarm()
177 * It's not possible to enable/disable the alarm IRQ for this RTC. in ab3100_rtc_irq_enable()