Searched refs:year (Results 1 - 25 of 27) sorted by relevance

12

/u-boot/lib/
H A Ddate.c16 #define leapyear(year) ((year) % 4 == 0)
37 /* Number of leap corrections to apply up to end of last year */
41 * This year is a leap year if it is divisible by 4 except when it is
44 * e.g. 1904 was a leap year, 1900 was not, 1996 is, and 2000 is.
49 /* We are past Feb. 29 in a leap year */
65 * => year=1980, mon=12, day=31, hour=23, min=59, sec=59.
70 * -year / 100 + year / 40
77 int year = tm->tm_year; local
95 mktime64(const unsigned int year, const unsigned int mon, const unsigned int day, const unsigned int hour, const unsigned int min, const unsigned int sec) argument
[all...]
H A Drtc-lib.c9 * - The year field takes the actual value, not year - 1900.
25 int rtc_month_days(unsigned int month, unsigned int year) argument
27 return rtc_days_in_month[month] + (is_leap_year(year) && month == 1);
35 * But in U-Boot January is month 1 and we do not subtract 1900 from the year.
39 unsigned int month, year, secs; local
47 year = 1970 + days / 365;
48 days -= (year - 1970) * 365
49 + LEAPS_THRU_END_OF(year - 1)
52 year
[all...]
/u-boot/lib/efi_selftest/
H A Defi_selftest_rtc.c46 .year = 2017,
63 tm_old.year, tm_old.month, tm_old.day,
76 if (tm.year != tm_new.year ||
/u-boot/arch/arm/include/asm/
H A Ddavinci_rtc.h22 unsigned int year; member in struct:davinci_rtc
/u-boot/include/
H A Drtc.h298 * is_leap_year - Check if year is a leap year
300 * @year Year
301 * Return: 1 if leap year
303 static inline bool is_leap_year(unsigned int year) argument
305 return (!(year % 4) && (year % 100)) || !(year % 400);
349 * @year: year (
[all...]
H A Dedid.h149 unsigned char year; member in struct:edid1_info
H A Defi.h283 u16 year; member in struct:efi_time
/u-boot/cmd/
H A Ddate.c183 int year, century; local
186 cnvrt2 (datestr+10, &year) ) {
189 tmp->tm_year = 100 * century + year;
191 int year, century; local
194 if (cnvrt2 (datestr+ 8, &year))
196 tmp->tm_year = 100 * century + year;
H A Deficonfig_sbkey.c272 time->year, time->month, time->day,
/u-boot/drivers/rtc/
H A Dpt7c4338.c69 u8 sec, min, hour, mday, wday, mon, year, ctl_stat; local
78 year = rtc_read(RTC_YR_REG_ADDR);
79 debug("Get RTC year: %02x mon: %02x mday: %02x wday: %02x "
81 year, mon, mday, wday, hour, min, sec, ctl_stat);
97 tmp->tm_year = bcd2bin(year) + 2000;
146 u8 sec, min, hour, mday, wday, mon, year, ctl_stat; local
155 year = rtc_read(dev, RTC_YR_REG_ADDR);
156 debug("Get RTC year: %02x mon: %02x mday: %02x wday: %02x\n",
157 year, mon, mday, wday);
176 tmp->tm_year = bcd2bin(year)
[all...]
H A Dpcf8563.c29 uchar sec, min, hour, mday, wday, mon_cent, year; local
37 year = rtc_read (0x08);
39 debug ( "Get RTC year: %02x mon/cent: %02x mday: %02x wday: %02x "
41 year, mon_cent, mday, wday,
59 tmp->tm_year = bcd2bin (year) + ((mon_cent & 0x80) ? 1900 : 2000);
125 uchar sec, min, hour, mday, wday, mon_cent, year; local
133 year = dm_i2c_reg_read(dev, 0x08);
135 debug("Get RTC year: %02x mon/cent: %02x mday: %02x wday: %02x ",
136 year, mon_cent, mday, wday);
155 tmp->tm_year = bcd2bin(year)
[all...]
H A Dds3231.c69 uchar sec, min, hour, mday, wday, mon_cent, year, control, status; local
79 year = rtc_read (RTC_YR_REG_ADDR);
81 debug("Get RTC year: %02x mon/cent: %02x mday: %02x wday: %02x "
83 year, mon_cent, mday, wday, hour, min, sec, control, status);
98 tmp->tm_year = bcd2bin (year) + ((mon_cent & 0x80) ? 2000 : 1900);
178 uchar sec, min, hour, mday, wday, mon_cent, year, status; local
187 year = dm_i2c_reg_read(dev, RTC_YR_REG_ADDR);
203 tmp->tm_year = bcd2bin(year) + ((mon_cent & 0x80) ? 2000 : 1900);
H A Dds1337.c76 uchar sec, min, hour, mday, wday, mon_cent, year, control, status; local
86 year = rtc_read (RTC_YR_REG_ADDR);
88 /* No century bit, assume year 2000 */
93 debug("Get RTC year: %02x mon/cent: %02x mday: %02x wday: %02x "
95 year, mon_cent, mday, wday, hour, min, sec, control, status);
110 tmp->tm_year = bcd2bin (year) + ((mon_cent & 0x80) ? 2000 : 1900);
209 uchar sec, min, hour, mday, wday, mon_cent, year, control, status; local
219 year = rtc_read(dev, RTC_YR_REG_ADDR);
221 /* No century bit, assume year 2000 */
226 debug("Get RTC year
[all...]
H A Drx8025.c93 uchar sec, min, hour, mday, wday, mon, year, ctl2; local
107 year = rtc_read(RTC_YR_REG_ADDR);
109 DEBUGR("Get RTC year: %02x mon: %02x mday: %02x wday: %02x "
111 year, mon, mday, wday, hour, min, sec);
139 tmp->tm_year = bcd2bin (year) + ( bcd2bin (year) >= 70 ? 1900 : 2000);
174 printf("WARNING: year should be between 1970 and 2069!\n");
H A Dmc146818.c84 uchar sec, min, hour, mday, wday __attribute__((unused)),mon, year; local
96 year = mc146818_read8(RTC_YEAR);
98 printf("Get RTC year: %02x mon/cent: %02x mday: %02x wday: %02x hr: %02x min: %02x sec: %02x\n",
99 year, mon, mday, wday, hour, min, sec);
111 tmp->tm_year = bcd2bin(year);
H A Dds1307.c100 uchar sec, min, hour, mday, wday, mon, year; local
111 year = rtc_read (RTC_YR_REG_ADDR);
113 DEBUGR ("Get RTC year: %02x mon: %02x mday: %02x wday: %02x "
115 year, mon, mday, wday, hour, min, sec);
148 tmp->tm_year = bcd2bin (year) + ( bcd2bin (year) >= 70 ? 1900 : 2000);
171 printf("WARNING: year should be between 1970 and 2069!\n");
238 printf("WARNING: year should be between 1970 and 2069!\n");
H A Ddavinci.c183 unsigned long sec, min, hour, mday, wday, mon_cent, year; local
196 year = omap_rtc_readb(priv, OMAP_RTC_YEARS_REG);
199 "Get RTC year: %02lx mon/cent: %02lx mday: %02lx wday: %02lx "
201 year, mon_cent, mday, wday,
209 tm->tm_year = bcd2bin(year) + 2000;
/u-boot/board/compulab/common/
H A Deeprom.c278 unsigned int year)
302 if (year % 4 == 0) {
303 if (year % 100 != 0)
305 else if (year % 400 == 0)
329 * year value, and checks the validity of the date.
359 unsigned int year = simple_strtol(tok3, &endptr, 0); local
361 printf("%s: invalid year\n", field->name);
365 if (validate_date(day, month - 1, year)) {
370 if (year >> 16) {
371 printf("%s: year overflo
277 validate_date(unsigned char day, unsigned char month, unsigned int year) argument
[all...]
/u-boot/lib/crypto/
H A Dx509_cert_parser.c540 * dates through the year 2049 as UTCTime; certificate validity dates in
552 unsigned year, mon, day, hour, min, sec, mon_len; local
561 year = DD2bin(p);
562 if (year >= 50)
563 year += 1900;
565 year += 2000;
570 year = DD2bin(p) * 100 + DD2bin(p);
571 if (year >= 1950 && year <= 2049)
586 if (year < 197
[all...]
/u-boot/lib/efi_loader/
H A Defi_runtime.c310 time->year = tm.tm_year;
350 time->year < 1900 || time->year > 9999 ||
352 time->day > rtc_month_days(time->month - 1, time->year) ||
395 tm.tm_year = time->year;
H A Defi_variable.c93 tm.tm_year = timestamp.year;
H A Defi_file.c493 time->year = tm->tm_year;
/u-boot/include/linux/
H A Dtime.h47 int tm_yday; /* Days in year.[0-365] */
118 /* compute year & day of year */
165 time64_t mktime64(const unsigned int year, const unsigned int mon,
H A Dfb.h317 __u32 year; /* Year manufactured */ member in struct:fb_monspecs
/u-boot/common/
H A Dedid.c396 printf("Manufactured in week: %d year: %d\n",
397 edid_info->week, edid_info->year + 1990);

Completed in 132 milliseconds

12