diff mbox series

[v2,08/25] y2038: Add __USE_TIME_BITS64 support for time_t

Message ID 20210518205613.1487824-9-adhemerval.zanella@linaro.org
State New
Headers show
Series Add 64 bit time support on legacy ABIs | expand

Commit Message

Adhemerval Zanella Netto May 18, 2021, 8:55 p.m. UTC
The __USE_TIME_BITS64 is not defined internally yet.
---
 time/bits/types/time_t.h | 4 ++++
 1 file changed, 4 insertions(+)

Comments

Lukasz Majewski May 19, 2021, 9:02 a.m. UTC | #1
On Tue, 18 May 2021 17:55:56 -0300
Adhemerval Zanella <adhemerval.zanella@linaro.org> wrote:

> The __USE_TIME_BITS64 is not defined internally yet.
> ---
>  time/bits/types/time_t.h | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/time/bits/types/time_t.h b/time/bits/types/time_t.h
> index ab8287c6fe..84d67f6ac3 100644
> --- a/time/bits/types/time_t.h
> +++ b/time/bits/types/time_t.h
> @@ -4,6 +4,10 @@
>  #include <bits/types.h>
>  
>  /* Returned by `time'.  */
> +#ifdef __USE_TIME_BITS64
> +typedef __time64_t time_t;
> +#else
>  typedef __time_t time_t;
> +#endif
>  
>  #endif

Reviewed-by: Lukasz Majewski <lukma@denx.de>

Best regards,

Lukasz Majewski

--

DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-59 Fax: (+49)-8142-66989-80 Email: lukma@denx.de
Carlos O'Donell June 4, 2021, 7:30 p.m. UTC | #2
On 5/18/21 4:55 PM, Adhemerval Zanella wrote:
> The __USE_TIME_BITS64 is not defined internally yet.

LGTM.

No regressions on x86_64, i686, ppc64le, aarch64, s390x.

Reviewed-by: Carlos O'Donell <carlos@redhat.com>
Tested-by: Carlos O'Donell <carlos@redhat.com>

> ---
>  time/bits/types/time_t.h | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/time/bits/types/time_t.h b/time/bits/types/time_t.h
> index ab8287c6fe..84d67f6ac3 100644
> --- a/time/bits/types/time_t.h
> +++ b/time/bits/types/time_t.h
> @@ -4,6 +4,10 @@
>  #include <bits/types.h>
>  
>  /* Returned by `time'.  */
> +#ifdef __USE_TIME_BITS64
> +typedef __time64_t time_t;
> +#else
>  typedef __time_t time_t;
> +#endif
>  
>  #endif
>
diff mbox series

Patch

diff --git a/time/bits/types/time_t.h b/time/bits/types/time_t.h
index ab8287c6fe..84d67f6ac3 100644
--- a/time/bits/types/time_t.h
+++ b/time/bits/types/time_t.h
@@ -4,6 +4,10 @@ 
 #include <bits/types.h>
 
 /* Returned by `time'.  */
+#ifdef __USE_TIME_BITS64
+typedef __time64_t time_t;
+#else
 typedef __time_t time_t;
+#endif
 
 #endif