Lines Matching refs:ctrlb
312 u8 ctrlb, seconds, minutes, hours, wday, mday, month, years, century; in ds1685_rtc_set_time() local
353 ctrlb = rtc->read(rtc, RTC_CTRL_B); in ds1685_rtc_set_time()
355 ctrlb &= ~(RTC_CTRL_B_DM); in ds1685_rtc_set_time()
357 ctrlb |= RTC_CTRL_B_DM; in ds1685_rtc_set_time()
358 rtc->write(rtc, RTC_CTRL_B, ctrlb); in ds1685_rtc_set_time()
388 u8 seconds, minutes, hours, mday, ctrlb, ctrlc; in ds1685_rtc_read_alarm() local
397 ctrlb = rtc->read(rtc, RTC_CTRL_B); in ds1685_rtc_read_alarm()
431 alrm->enabled = !!(ctrlb & RTC_CTRL_B_AIE); in ds1685_rtc_read_alarm()
446 u8 ctrlb, seconds, minutes, hours, mday; in ds1685_rtc_set_alarm() local
493 ctrlb = rtc->read(rtc, RTC_CTRL_B); in ds1685_rtc_set_alarm()
494 rtc->write(rtc, RTC_CTRL_B, (ctrlb & ~(RTC_CTRL_B_AIE))); in ds1685_rtc_set_alarm()
503 ctrlb = rtc->read(rtc, RTC_CTRL_B); in ds1685_rtc_set_alarm()
505 ctrlb &= ~(RTC_CTRL_B_DM); in ds1685_rtc_set_alarm()
507 ctrlb |= RTC_CTRL_B_DM; in ds1685_rtc_set_alarm()
508 rtc->write(rtc, RTC_CTRL_B, ctrlb); in ds1685_rtc_set_alarm()
516 ctrlb = rtc->read(rtc, RTC_CTRL_B); in ds1685_rtc_set_alarm()
517 ctrlb |= RTC_CTRL_B_AIE; in ds1685_rtc_set_alarm()
518 rtc->write(rtc, RTC_CTRL_B, ctrlb); in ds1685_rtc_set_alarm()
661 u8 ctrlb, ctrlc; in ds1685_rtc_irq_handler() local
672 ctrlb = rtc->read(rtc, RTC_CTRL_B); in ds1685_rtc_irq_handler()
686 if ((ctrlb & RTC_CTRL_B_PIE) && in ds1685_rtc_irq_handler()
693 if ((ctrlb & RTC_CTRL_B_AIE) && in ds1685_rtc_irq_handler()
700 if ((ctrlb & RTC_CTRL_B_UIE) && in ds1685_rtc_irq_handler()
755 u8 ctrla, ctrlb, ctrld, ctrl4a, ctrl4b, ssn[8]; in ds1685_rtc_proc() local
762 ctrlb = rtc->read(rtc, RTC_CTRL_B); in ds1685_rtc_proc()
806 ((ctrlb & RTC_CTRL_B_2412) ? "24-hour" : "12-hour"), in ds1685_rtc_proc()
807 ((ctrlb & RTC_CTRL_B_DSE) ? "enabled" : "disabled"), in ds1685_rtc_proc()
808 ((ctrlb & RTC_CTRL_B_DM) ? "binary" : "BCD"), in ds1685_rtc_proc()
811 ((ctrlb & RTC_CTRL_B_UIE) ? "yes" : "no"), in ds1685_rtc_proc()
812 ((ctrlb & RTC_CTRL_B_PIE) ? "yes" : "no"), in ds1685_rtc_proc()
1073 u8 ctrla, ctrlb, hours; in ds1685_rtc_probe() local
1172 ctrlb = rtc->read(rtc, RTC_CTRL_B); in ds1685_rtc_probe()
1174 ctrlb &= ~(RTC_CTRL_B_DM); in ds1685_rtc_probe()
1176 ctrlb |= RTC_CTRL_B_DM; in ds1685_rtc_probe()
1184 if (ctrlb & RTC_CTRL_B_DSE) in ds1685_rtc_probe()
1185 ctrlb &= ~(RTC_CTRL_B_DSE); in ds1685_rtc_probe()
1188 if (!(ctrlb & RTC_CTRL_B_2412)) { in ds1685_rtc_probe()
1197 ctrlb |= RTC_CTRL_B_2412; in ds1685_rtc_probe()
1200 rtc->write(rtc, RTC_CTRL_B, ctrlb); in ds1685_rtc_probe()
1222 rtc->write(rtc, RTC_CTRL_B, ctrlb); in ds1685_rtc_probe()