Lines Matching defs:tm
1820 char *date_str(char *buf, char *end, const struct rtc_time *tm, bool r)
1822 int year = tm->tm_year + (r ? 0 : 1900);
1823 int mon = tm->tm_mon + (r ? 0 : 1);
1835 return number(buf, end, tm->tm_mday, default_dec02_spec);
1839 char *time_str(char *buf, char *end, const struct rtc_time *tm, bool r)
1841 buf = number(buf, end, tm->tm_hour, default_dec02_spec);
1846 buf = number(buf, end, tm->tm_min, default_dec02_spec);
1851 return number(buf, end, tm->tm_sec, default_dec02_spec);
1855 char *rtc_str(char *buf, char *end, const struct rtc_time *tm,
1863 if (check_pointer(&buf, end, tm, spec))
1892 buf = date_str(buf, end, tm, raw);
1899 buf = time_str(buf, end, tm, raw);
1909 struct tm tm;
1911 time64_to_tm(time, 0, &tm);
1913 rtc_time.tm_sec = tm.tm_sec;
1914 rtc_time.tm_min = tm.tm_min;
1915 rtc_time.tm_hour = tm.tm_hour;
1916 rtc_time.tm_mday = tm.tm_mday;
1917 rtc_time.tm_mon = tm.tm_mon;
1918 rtc_time.tm_year = tm.tm_year;
1919 rtc_time.tm_wday = tm.tm_wday;
1920 rtc_time.tm_yday = tm.tm_yday;