Lines Matching defs:hour
30 * - Need fancy "hours" encoding in 12hour mode
47 /* The two alarms have only sec/min/hour/wday fields (ALM_LEN).
104 * Utilities ... tolerate 12-hour AM/PM notation in case of non-Linux
111 unsigned hour = 0;
115 hour = 12;
118 hour += bcd2bin(bcd);
119 return hour - 1;
124 static u8 hour2bcd(bool hr12, int hour)
127 hour++;
128 if (hour <= 12)
129 return DS1305_HR_12 | bin2bcd(hour);
130 hour -= 12;
131 return DS1305_HR_12 | DS1305_HR_PM | bin2bcd(hour);
133 return bin2bcd(hour);