diff options
| author | Tom Rini <[email protected]> | 2022-05-05 19:37:22 -0400 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2022-05-05 19:37:22 -0400 |
| commit | 03b873b4f41010e4f85a72dd59016bb0b123dde1 (patch) | |
| tree | 3ea6ba397b9ce3db7286537be078944c6daa23b8 /include | |
| parent | 5d834bfa5fa61dc9dff94a92672c0a1185cb3a83 (diff) | |
| parent | aa5ea20c71921e062aa91d5c7f924cef5d742ec2 (diff) | |
Merge branch '2022-05-05-assorted-cleanups-and-fixes'
- Assorted minor code cleanups.
- Clean-up the reset uclass code slightly and fix some issues with a
lack of handlers for a case in the driver.
- Y2038 RTC fix
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/time.h | 3 | ||||
| -rw-r--r-- | include/rtc.h | 8 |
2 files changed, 5 insertions, 6 deletions
diff --git a/include/linux/time.h b/include/linux/time.h index 702dd276aea..14ff5b6f481 100644 --- a/include/linux/time.h +++ b/include/linux/time.h @@ -152,9 +152,6 @@ _DEFUN (ctime_r, (tim_p, result), return asctime_r (localtime_r (tim_p, &tm), result); } -/* for compatibility with linux code */ -typedef __s64 time64_t; - #ifdef CONFIG_LIB_DATE time64_t mktime64(const unsigned int year, const unsigned int mon, const unsigned int day, const unsigned int hour, diff --git a/include/rtc.h b/include/rtc.h index 6c7fcadd488..10104e3bf5a 100644 --- a/include/rtc.h +++ b/include/rtc.h @@ -16,6 +16,8 @@ #include <bcd.h> #include <rtc_def.h> +typedef int64_t time64_t; + #ifdef CONFIG_DM_RTC struct udevice; @@ -301,7 +303,7 @@ int rtc_calc_weekday(struct rtc_time *time); void rtc_to_tm(u64 time_t, struct rtc_time *time); /** - * rtc_mktime() - Convert a broken-out time into a time_t value + * rtc_mktime() - Convert a broken-out time into a time64_t value * * The following fields need to be valid for this function to work: * tm_sec, tm_min, tm_hour, tm_mday, tm_mon, tm_year @@ -309,9 +311,9 @@ void rtc_to_tm(u64 time_t, struct rtc_time *time); * Note that tm_wday and tm_yday are ignored. * * @time: Broken-out time to convert - * Return: corresponding time_t value, seconds since 1970-01-01 00:00:00 + * Return: corresponding time64_t value, seconds since 1970-01-01 00:00:00 */ -unsigned long rtc_mktime(const struct rtc_time *time); +time64_t rtc_mktime(const struct rtc_time *time); /** * rtc_month_days() - The number of days in the month |
