Home
last modified time | relevance | path

Searched full:day (Results 1 – 25 of 273) sorted by relevance

1234567891011

/linux/drivers/rtc/
H A Drtc-rtd119x.c85 s32 day; in rtd119x_rtc_read_time() local
94 day = readl_relaxed(data->base + RTD_RTCDATE1) & RTD_RTCDATE1_RTCDATE1_MASK; in rtd119x_rtc_read_time()
95 day |= (readl_relaxed(data->base + RTD_RTCDATE2) & RTD_RTCDATE2_RTCDATE2_MASK) << 8; in rtd119x_rtc_read_time()
109 while (day >= rtd119x_rtc_days_in_year(year)) { in rtd119x_rtc_read_time()
110 day -= rtd119x_rtc_days_in_year(year); in rtd119x_rtc_read_time()
114 tm->tm_yday = day; in rtd119x_rtc_read_time()
117 while (day >= rtc_month_days(tm->tm_mon, year)) { in rtd119x_rtc_read_time()
118 day -= rtc_month_days(tm->tm_mon, year); in rtd119x_rtc_read_time()
121 tm->tm_mday = day + 1; in rtd119x_rtc_read_time()
129 unsigned int day; in rtd119x_rtc_set_time() local
[all …]
H A Dlib.c39 int rtc_year_days(unsigned int day, unsigned int month, unsigned int year) in rtc_year_days() argument
41 return rtc_ydays[is_leap_year(year)][month] + day - 1; in rtc_year_days()
58 day_of_year, month, day; in rtc_time64_to_tm() local
75 * day of the week, 0000-03-01 was a Wednesday (in the proleptic in rtc_time64_to_tm()
85 * mathematically convenient because the day of the year does not in rtc_time64_to_tm()
88 * March 1st 0-th day of the year; in rtc_time64_to_tm()
90 * April 1st 31-st day of the year; in rtc_time64_to_tm()
92 * January 1st 306-th day of the year; (Important!) in rtc_time64_to_tm()
94 * February 28th 364-th day of the year; in rtc_time64_to_tm()
95 * February 29th 365-th day of the year (if it exists). in rtc_time64_to_tm()
[all …]
H A Drtc-wilco-ec.c41 * @day: Day value (1..31)
53 u8 day; member
67 * @day: Day value (1..31)
71 * @weekday: Day of the week (0=Saturday)
82 u8 day; member
110 tm->tm_mday = rtc.day; in wilco_ec_rtc_read()
132 * schedules that depend on the day of the week. in wilco_ec_rtc_write()
142 rtc.day = bin2bcd(tm->tm_mday); in wilco_ec_rtc_write()
H A Drtc-efi.c24 * returns day of the year [0-365]
30 return rtc_year_days(eft->day, eft->month - 1, eft->year); in compute_yday()
34 * returns day of the week [0-6] 0=Sunday
57 eft->day = wtime->tm_mday; in convert_to_efi_time()
83 if (!eft->day || eft->day > 31) in convert_from_efi_time()
85 wtime->tm_mday = eft->day; in convert_from_efi_time()
95 /* day in the year [1-365]*/ in convert_from_efi_time()
98 /* day of the week [0-6], Sunday=0 */ in convert_from_efi_time()
162 eft.year, eft.month, eft.day, in efi_procfs()
H A Drtc-cpcap.c35 int day; member
56 time = tod + ((cpcap->day & DAY_MASK) * SECS_PER_DAY); in cpcap2rtc_time()
67 cpcap->day = time / SECS_PER_DAY; in rtc2cpcap_time()
100 ret |= regmap_read(rtc->regmap, CPCAP_REG_DAY, &cpcap_tm.day); in cpcap_rtc_read_time()
105 ret |= regmap_read(rtc->regmap, CPCAP_REG_DAY, &cpcap_tm.day); in cpcap_rtc_read_time()
141 DAY_MASK, cpcap_tm.day); in cpcap_rtc_set_time()
146 * to DAY, TOD2, then TOD1 (in that order) and expect RTC to be in cpcap_rtc_set_time()
153 DAY_MASK, cpcap_tm.day); in cpcap_rtc_set_time()
178 ret = regmap_read(rtc->regmap, CPCAP_REG_DAYA, &cpcap_tm.day); in cpcap_rtc_read_alarm()
205 cpcap_tm.day); in cpcap_rtc_set_alarm()
H A Drtc-m48t35.c31 u8 day; member
37 u8 day; member
100 unsigned char mon, day, hrs, min, sec; in m48t35_set_time() local
106 day = tm->tm_mday; in m48t35_set_time()
127 day = bin2bcd(day); in m48t35_set_time()
136 writeb(day, &priv->reg->date); in m48t35_set_time()
H A Drtc-mxc.c52 #define RTC_DAYALARM 0x24 /* 32bit rtc day alarm reg */
92 u32 day = 0, hr = 0, min = 0, sec = 0, hr_min = 0; in get_alarm_or_time() local
96 day = readw(ioaddr + RTC_DAYR); in get_alarm_or_time()
101 day = readw(ioaddr + RTC_DAYALARM); in get_alarm_or_time()
110 return ((((time64_t)day * 24 + hr) * 60) + min) * 60 + sec; in get_alarm_or_time()
118 u32 tod, day, hr, min, sec, temp; in set_alarm_or_time() local
122 day = div_s64_rem(time, 86400, &tod); in set_alarm_or_time()
124 /* time is within a day now */ in set_alarm_or_time()
136 writew(day, ioaddr + RTC_DAYR); in set_alarm_or_time()
141 writew(day, ioaddr + RTC_DAYALARM); in set_alarm_or_time()
H A Dtest_rtc_lib.c7 * Advance a date by one day.
32 * Check every day in specified number of years interval starting on 1970-01-01
75 * Checks every day in a 160000 years interval starting on 1900-01-01
84 * Checks every day in a 1000 years interval starting on 1900-01-01
H A Drtc-bq4802.c95 u8 sec, min, hrs, day, mon, yrs, century, val; in bq4802_set_time() local
104 day = tm->tm_mday; in bq4802_set_time()
112 day = bin2bcd(day); in bq4802_set_time()
125 p->write(p, 0x06, day); in bq4802_set_time()
H A Drtc-mc146818-lib.c215 unsigned char mon, day, hrs, min, sec; in mc146818_set_time() local
225 day = time->tm_mday; in mc146818_set_time()
272 day = bin2bcd(day); in mc146818_set_time()
292 CMOS_WRITE(day, RTC_DAY_OF_MONTH); in mc146818_set_time()
H A Drtc-ds1742.c46 /* Bits in the Day register */
83 unsigned int year, month, day, hour, minute, second, week; in ds1742_rtc_read_time() local
94 day = readb(ioaddr + RTC_DATE); in ds1742_rtc_read_time()
103 tm->tm_mday = bcd2bin(day); in ds1742_rtc_read_time()
H A Drtc-ds1286.c216 unsigned char mon, day, hrs, min, sec; in ds1286_set_time() local
223 day = tm->tm_mday; in ds1286_set_time()
241 day = bin2bcd(day); in ds1286_set_time()
251 ds1286_rtc_write(priv, day, RTC_DATE); in ds1286_set_time()
H A Drtc-ds1511.c96 u8 mon, day, dow, hrs, min, sec, yrs, cen; in ds1511_rtc_set_time() local
102 day = rtc_tm->tm_mday; in ds1511_rtc_set_time()
114 day = bin2bcd(day) & 0x3f; in ds1511_rtc_set_time()
124 rtc_write(day, DS1511_DOM); in ds1511_rtc_set_time()
/linux/kernel/time/
H A Dtimeconv.c49 u32 u32tmp, day_of_century, year_of_century, day_of_year, month, day; in time64_to_tm() local
82 * mathematically convenient because the day of the year does not in time64_to_tm()
85 * March 1st 0-th day of the year; in time64_to_tm()
87 * April 1st 31-st day of the year; in time64_to_tm()
89 * January 1st 306-th day of the year; (Important!) in time64_to_tm()
91 * February 28th 364-th day of the year; in time64_to_tm()
92 * February 29th 365-th day of the year (if it exists). in time64_to_tm()
121 day = ((u16) u32tmp) / 2141; in time64_to_tm()
124 * Recall that January 1st is the 306-th day of the year in the in time64_to_tm()
132 day = day + 1; in time64_to_tm()
[all …]
/linux/arch/sh/boards/mach-sh03/
H A Drtc.c43 unsigned int year, mon, day, hour, min, sec; in sh03_rtc_gettimeofday() local
51 day = (__raw_readb(RTC_DAY1) & 0xf) + (__raw_readb(RTC_DAY10) & 0xf) * 10; in sh03_rtc_gettimeofday()
57 if (year == 0 || mon < 1 || mon > 12 || day > 31 || day < 1 || in sh03_rtc_gettimeofday()
61 printk("year=%d, mon=%d, day=%d, hour=%d, min=%d, sec=%d\n", in sh03_rtc_gettimeofday()
62 year, mon, day, hour, min, sec); in sh03_rtc_gettimeofday()
82 tm->tm_mday = day; in sh03_rtc_gettimeofday()
/linux/arch/mips/sibyte/swarm/
H A Drtc_xicor1241.c47 #define X1241REG_DT 0x33 /* Day of month */
50 #define X1241REG_DW 0x36 /* Day of Week */
169 unsigned int year, mon, day, hour, min, sec, y2k; in xicor_get_time() local
184 day = xicor_read(X1241REG_DT); in xicor_get_time()
193 day = bcd2bin(day); in xicor_get_time()
200 return mktime64(year, mon, day, hour, min, sec); in xicor_get_time()
H A Drtc_m41t81.c65 #define M41T81REG_DY 0x04 /* day of week */
188 unsigned int year, mon, day, hour, min, sec; in m41t81_get_time() local
202 day = m41t81_read(M41T81REG_DT); in m41t81_get_time()
210 day = bcd2bin(day); in m41t81_get_time()
216 return mktime64(year, mon, day, hour, min, sec); in m41t81_get_time()
/linux/arch/m68k/atari/
H A Dtime.c203 int sec=0, min=0, hour=0, day=0, mon=0, year=0, wday=0; in atari_tt_hwclk() local
217 day = t->tm_mday; in atari_tt_hwclk()
236 day = bin2bcd(day); in atari_tt_hwclk()
269 day = RTC_READ( RTC_DAY_OF_MONTH ); in atari_tt_hwclk()
278 RTC_WRITE( RTC_DAY_OF_MONTH, day ); in atari_tt_hwclk()
298 day = bcd2bin(day); in atari_tt_hwclk()
314 t->tm_mday = day; in atari_tt_hwclk()
/linux/arch/powerpc/platforms/chrp/
H A Dtime.c132 unsigned int year, mon, day, hour, min, sec; in chrp_get_rtc_time() local
138 day = chrp_cmos_clock_read(RTC_DAY_OF_MONTH); in chrp_get_rtc_time()
147 day = bcd2bin(day); in chrp_get_rtc_time()
156 tm->tm_mday = day; in chrp_get_rtc_time()
/linux/drivers/md/bcache/
H A Dstats.c20 * and one day.
103 ret = ret ?: kobject_add(&acc->day.kobj, parent, in bch_cache_accounting_add_kobjs()
123 kobject_put(&acc->day.kobj); in bch_cache_accounting_destroy()
159 acc->day.name += t; \ in scale_accounting()
171 scale_stats(&acc->day, DAY_RESCALE); in scale_accounting()
228 kobject_init(&acc->day.kobj, &bch_stats_ktype); in bch_cache_accounting_init()
/linux/arch/m68k/bvme6000/
H A Drtc.c74 unsigned char mon, day, hrs, min, sec, leap_yr; in rtc_ioctl() local
87 day = rtc_tm.tm_mday; in rtc_ioctl()
94 if ((mon > 12) || (mon < 1) || (day == 0)) in rtc_ioctl()
97 if (day > (days_in_mo[mon] + ((mon == 2) && leap_yr))) in rtc_ioctl()
116 rtc->bcd_dom = bin2bcd(day); in rtc_ioctl()
/linux/arch/mips/dec/
H A Dtime.c24 unsigned int year, mon, day, hour, min, sec, real_year; in read_persistent_clock64() local
33 day = CMOS_READ(RTC_DAY_OF_MONTH); in read_persistent_clock64()
50 day = bcd2bin(day); in read_persistent_clock64()
57 ts->tv_sec = mktime64(year, mon, day, hour, min, sec); in read_persistent_clock64()
/linux/fs/isofs/
H A Dutil.c21 int year, month, day, hour, minute, second, tz; in iso_date() local
30 day = ((p[6] - '0') * 10 + (p[7] - '0')); in iso_date()
39 day = p[2]; in iso_date()
51 ts.tv_sec = mktime64(year+1900, month, day, hour, minute, second); in iso_date()
/linux/Documentation/input/devices/
H A Datarikbd.rst13 The ikbd processor also maintains a time-of-day clock with one second
43 0xFC time-of-day
177 Time-of-Day Clock
180 The ikbd also maintains a time-of-day clock for the system. Commands are
181 available to set and interrogate the timer-of-day clock. Time-keeping is
232 mode and parameter settings. It does not affect the time-of-day clock.
497 time-of-day clock, and monitor the joystick. The rate sets the interval
513 time-of-day clock, and monitor the fire button on Joystick 1. The fire button
564 TIME-OF-DAY CLOCK SET
572 DD ; day
[all …]
/linux/include/linux/mfd/
H A Dmotorola-cpcap.h70 #define CPCAP_REG_TOD1 0x0410 /* Time of Day 1 */
71 #define CPCAP_REG_TOD2 0x0414 /* Time of Day 2 */
72 #define CPCAP_REG_TODA1 0x0418 /* Time of Day Alarm 1 */
73 #define CPCAP_REG_TODA2 0x041c /* Time of Day Alarm 2 */
74 #define CPCAP_REG_DAY 0x0420 /* Day */
75 #define CPCAP_REG_DAYA 0x0424 /* Day Alarm */

1234567891011