diff mbox

[3/6] time: Add a __itimerval64 struct

Message ID 20200203183153.11635-4-alistair.francis@wdc.com
State New
Headers show

Commit Message

Alistair Francis Feb. 3, 2020, 6:31 p.m. UTC
Add a __itimerval64 which always uses a 64-bit time_t.
---
 include/time.h | 11 +++++++++++
 1 file changed, 11 insertions(+)

Comments

Lukasz Majewski Feb. 4, 2020, 10:21 a.m. UTC | #1
Hi Alistair,

> Add a __itimerval64 which always uses a 64-bit time_t.
> ---
>  include/time.h | 11 +++++++++++
>  1 file changed, 11 insertions(+)
> 
> diff --git a/include/time.h b/include/time.h
> index c2c05bb671..898ff0fb2d 100644
> --- a/include/time.h
> +++ b/include/time.h
> @@ -107,6 +107,17 @@ struct __timeval64
>  };
>  #endif
>  
> +#if __TIMESIZE == 64
> +# define __itimerval64 itimerval
> +#else
> +/* The glibc's internal representation of the struct itimerval.  */
> +struct __itimerval64
> +{
> +  struct __timeval64 it_interval;
> +  struct __timeval64 it_value;
> +};
> +#endif
> +
>  #if __TIMESIZE == 64
>  # define __ctime64 ctime
>  #else

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
diff mbox

Patch

diff --git a/include/time.h b/include/time.h
index c2c05bb671..898ff0fb2d 100644
--- a/include/time.h
+++ b/include/time.h
@@ -107,6 +107,17 @@  struct __timeval64
 };
 #endif
 
+#if __TIMESIZE == 64
+# define __itimerval64 itimerval
+#else
+/* The glibc's internal representation of the struct itimerval.  */
+struct __itimerval64
+{
+  struct __timeval64 it_interval;
+  struct __timeval64 it_value;
+};
+#endif
+
 #if __TIMESIZE == 64
 # define __ctime64 ctime
 #else