/linux-6.1.9/drivers/rtc/ |
D | rtc-rtd119x.c | 85 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 …]
|
D | lib.c | 39 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() 59 day_of_year, month, day; in rtc_time64_to_tm() local 113 day = ((u16) u32tmp) / 2141; in rtc_time64_to_tm() 124 day = day + 1; in rtc_time64_to_tm() 132 tm->tm_mday = (int) day; in rtc_time64_to_tm()
|
D | rtc-cpcap.c | 36 int day; member 57 time = tod + ((cpcap->day & DAY_MASK) * SECS_PER_DAY); in cpcap2rtc_time() 68 cpcap->day = time / SECS_PER_DAY; in rtc2cpcap_time() 101 ret |= regmap_read(rtc->regmap, CPCAP_REG_DAY, &cpcap_tm.day); in cpcap_rtc_read_time() 106 ret |= regmap_read(rtc->regmap, CPCAP_REG_DAY, &cpcap_tm.day); in cpcap_rtc_read_time() 142 DAY_MASK, cpcap_tm.day); in cpcap_rtc_set_time() 154 DAY_MASK, cpcap_tm.day); in cpcap_rtc_set_time() 179 ret = regmap_read(rtc->regmap, CPCAP_REG_DAYA, &cpcap_tm.day); in cpcap_rtc_read_alarm() 206 cpcap_tm.day); in cpcap_rtc_set_alarm()
|
D | rtc-m48t35.c | 31 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()
|
D | rtc-efi.c | 30 return rtc_year_days(eft->day, eft->month - 1, eft->year); in compute_yday() 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() 207 eft.year, eft.month, eft.day, in efi_procfs() 223 alm.year, alm.month, alm.day, in efi_procfs()
|
D | rtc-mxc.c | 93 u32 day = 0, hr = 0, min = 0, sec = 0, hr_min = 0; in get_alarm_or_time() local 97 day = readw(ioaddr + RTC_DAYR); in get_alarm_or_time() 102 day = readw(ioaddr + RTC_DAYALARM); in get_alarm_or_time() 111 return ((((time64_t)day * 24 + hr) * 60) + min) * 60 + sec; in get_alarm_or_time() 119 u32 tod, day, hr, min, sec, temp; in set_alarm_or_time() local 123 day = div_s64_rem(time, 86400, &tod); in set_alarm_or_time() 137 writew(day, ioaddr + RTC_DAYR); in set_alarm_or_time() 142 writew(day, ioaddr + RTC_DAYALARM); in set_alarm_or_time()
|
D | rtc-mc146818-lib.c | 194 unsigned char mon, day, hrs, min, sec; in mc146818_set_time() local 204 day = time->tm_mday; in mc146818_set_time() 253 day = bin2bcd(day); in mc146818_set_time() 273 CMOS_WRITE(day, RTC_DAY_OF_MONTH); in mc146818_set_time()
|
D | rtc-wilco-ec.c | 53 u8 day; member 82 u8 day; member 110 tm->tm_mday = rtc.day; in wilco_ec_rtc_read() 142 rtc.day = bin2bcd(tm->tm_mday); in wilco_ec_rtc_write()
|
D | rtc-bq4802.c | 95 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()
|
D | rtc-mv.c | 71 unsigned int year, month, day, hour, minute, second, wday; in mv_rtc_read_time() local 81 day = rtc_date & 0x3f; in mv_rtc_read_time() 88 tm->tm_mday = bcd2bin(day); in mv_rtc_read_time() 102 unsigned int year, month, day, hour, minute, second, wday; in mv_rtc_read_alarm() local 112 day = rtc_date & 0x3f; in mv_rtc_read_alarm() 119 alm->time.tm_mday = bcd2bin(day); in mv_rtc_read_alarm()
|
D | rtc-ds1511.c | 176 u8 mon, day, dow, hrs, min, sec, yrs, cen; in ds1511_rtc_set_time() local 191 day = rtc_tm->tm_mday; in ds1511_rtc_set_time() 197 if ((mon > 12) || (day == 0)) in ds1511_rtc_set_time() 200 if (day > rtc_month_days(rtc_tm->tm_mon, rtc_tm->tm_year)) in ds1511_rtc_set_time() 212 day = bin2bcd(day) & 0x3f; in ds1511_rtc_set_time() 222 rtc_write(day, RTC_DOM); in ds1511_rtc_set_time()
|
D | rtc-ds1286.c | 216 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()
|
/linux-6.1.9/kernel/time/ |
D | timeconv.c | 49 u32 u32tmp, day_of_century, year_of_century, day_of_year, month, day; in time64_to_tm() local 121 day = ((u16) u32tmp) / 2141; in time64_to_tm() 132 day = day + 1; in time64_to_tm() 138 result->tm_mday = (int) day; in time64_to_tm()
|
/linux-6.1.9/arch/mips/include/asm/ |
D | mc146818-time.h | 91 unsigned int year, mon, day, hour, min, sec; in mc146818_get_cmos_time() local 100 day = CMOS_READ(RTC_DAY_OF_MONTH); in mc146818_get_cmos_time() 109 day = bcd2bin(day); in mc146818_get_cmos_time() 116 return mktime64(year, mon, day, hour, min, sec); in mc146818_get_cmos_time()
|
/linux-6.1.9/arch/sh/boards/mach-sh03/ |
D | rtc.c | 43 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() 62 year, mon, day, hour, min, sec); in sh03_rtc_gettimeofday() 82 tm->tm_mday = day; in sh03_rtc_gettimeofday()
|
/linux-6.1.9/arch/m68k/atari/ |
D | time.c | 201 int sec=0, min=0, hour=0, day=0, mon=0, year=0, wday=0; in atari_tt_hwclk() local 215 day = t->tm_mday; in atari_tt_hwclk() 234 day = bin2bcd(day); in atari_tt_hwclk() 267 day = RTC_READ( RTC_DAY_OF_MONTH ); in atari_tt_hwclk() 276 RTC_WRITE( RTC_DAY_OF_MONTH, day ); in atari_tt_hwclk() 296 day = bcd2bin(day); in atari_tt_hwclk() 312 t->tm_mday = day; in atari_tt_hwclk()
|
/linux-6.1.9/arch/mips/dec/ |
D | time.c | 24 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-6.1.9/arch/m68k/mvme16x/ |
D | rtc.c | 69 unsigned char mon, day, hrs, min, sec, leap_yr; in rtc_ioctl() local 82 day = rtc_tm.tm_mday; in rtc_ioctl() 89 if ((mon > 12) || (day == 0)) in rtc_ioctl() 92 if (day > (days_in_mo[mon] + ((mon == 2) && leap_yr))) in rtc_ioctl() 107 rtc->bcd_dom = bin2bcd(day); in rtc_ioctl()
|
/linux-6.1.9/arch/powerpc/platforms/chrp/ |
D | time.c | 132 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-6.1.9/fs/isofs/ |
D | util.c | 21 int year, month, day, hour, minute, second, tz; in iso_date() local 26 day = p[2]; in iso_date() 36 crtime = mktime64(year+1900, month, day, hour, minute, second); in iso_date()
|
/linux-6.1.9/arch/m68k/bvme6000/ |
D | rtc.c | 74 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-6.1.9/arch/mips/sibyte/swarm/ |
D | rtc_m41t81.c | 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()
|
D | rtc_xicor1241.c | 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()
|
/linux-6.1.9/drivers/md/bcache/ |
D | stats.c | 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-6.1.9/arch/m68k/sun3/ |
D | intersil.c | 45 todintersil->day = t->tm_mday; in sun3_hwclk() 55 t->tm_mday = todintersil->day; in sun3_hwclk()
|