Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

recent linux y2038 changes prevent zfs from building (time_t, timespec, getrawmonotonic gone) #10052

Closed
softminus opened this issue Feb 25, 2020 · 0 comments
Labels
Type: Building Indicates an issue related to building binaries

Comments

@softminus
Copy link

System information

Type Version/Name
Distribution Name Arch linux
Distribution Version rolling release
Linux Kernel 63623fd44972d1ed2bfb6e0fb631dfcf547fd1e7
Architecture x86_64
ZFS Version 327000c
SPL Version 327000c

Describe the problem you're observing

Latest zfs fails to build on latest kernel; i think due to kernel commit 412c53a680a97cb1ae2c0ab60230e193bee86387 and maybe c766d1472c70d25ad475cf56042af1652e792b23.

Describe how to reproduce the problem

Build ZFS against a kernel with those y2038 commits and get the following error messages:

Include any warning/errors/backtraces from the system logs

make[3]: Entering directory '/home/thz/linux'
  CC [M]  /home/thz/zfs/module/icp/illumos-crypto.o
In file included from /home/thz/zfs/include/os/linux/spl/sys/condvar.h:33,
                 from /home/thz/zfs/include/sys/zfs_context.h:37,
                 from /home/thz/zfs/include/sys/crypto/common.h:39,
                 from /home/thz/zfs/module/icp/illumos-crypto.c:35:
/home/thz/zfs/include/os/linux/spl/sys/time.h:88:15: error: unknown type name ‘time_t’
   88 | static inline time_t
      |               ^~~~~~
/home/thz/zfs/include/os/linux/spl/sys/time.h: In function ‘gethrtime’:
/home/thz/zfs/include/os/linux/spl/sys/time.h:108:18: error: storage size of ‘ts’ isn’t known
  108 |  struct timespec ts;
      |                  ^~
/home/thz/zfs/include/os/linux/spl/sys/time.h:109:2: error: implicit declaration of function ‘getrawmonotonic’ [-Werror=implicit-function-declaration]
  109 |  getrawmonotonic(&ts);
      |  ^~~~~~~~~~~~~~~
/home/thz/zfs/include/os/linux/spl/sys/time.h:108:18: warning: unused variable ‘ts’ [-Wunused-variable]
  108 |  struct timespec ts;
      |                  ^~
cc1: some warnings being treated as errors



@behlendorf behlendorf added the Type: Building Indicates an issue related to building binaries label Feb 25, 2020
@behlendorf behlendorf mentioned this issue Feb 26, 2020
12 tasks
behlendorf added a commit that referenced this issue Feb 27, 2020
As part of the Linux kernel's y2038 changes the time_t type has been
fully retired.  Callers are now required to use the time64_t type.

Rather than move to the new type, I've removed the few remaining
places where a time_t is used in the kernel code.  They've been
replaced with a uint64_t which is already how ZFS internally
handled these values.

Going forward we should work towards updating the remaining user
space time_t consumers to the 64-bit interfaces.

Reviewed-by: Matthew Macy <mmacy@freebsd.org>
Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #10052
Closes #10064
gamanakis pushed a commit to gamanakis/zfs that referenced this issue Apr 15, 2020
The getrawmonotonic() and getrawmonotonic64() interfaces have been
fully retired.  Update gethrtime() to use the replacement interface
ktime_get_raw_ts64() which was introduced in the 4.18 kernel.

Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes openzfs#10052
Closes openzfs#10064
gamanakis pushed a commit to gamanakis/zfs that referenced this issue Apr 15, 2020
As part of the Linux kernel's y2038 changes the time_t type has been
fully retired.  Callers are now required to use the time64_t type.

Rather than move to the new type, I've removed the few remaining
places where a time_t is used in the kernel code.  They've been
replaced with a uint64_t which is already how ZFS internally
handled these values.

Going forward we should work towards updating the remaining user
space time_t consumers to the 64-bit interfaces.

Reviewed-by: Matthew Macy <mmacy@freebsd.org>
Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes openzfs#10052
Closes openzfs#10064
gamanakis pushed a commit to gamanakis/zfs that referenced this issue Apr 15, 2020
The getrawmonotonic() and getrawmonotonic64() interfaces have been
fully retired.  Update gethrtime() to use the replacement interface
ktime_get_raw_ts64() which was introduced in the 4.18 kernel.

Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes openzfs#10052
Closes openzfs#10064
gamanakis pushed a commit to gamanakis/zfs that referenced this issue Apr 15, 2020
As part of the Linux kernel's y2038 changes the time_t type has been
fully retired.  Callers are now required to use the time64_t type.

Rather than move to the new type, I've removed the few remaining
places where a time_t is used in the kernel code.  They've been
replaced with a uint64_t which is already how ZFS internally
handled these values.

Going forward we should work towards updating the remaining user
space time_t consumers to the 64-bit interfaces.

Reviewed-by: Matthew Macy <mmacy@freebsd.org>
Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes openzfs#10052
Closes openzfs#10064
tonyhutter pushed a commit to tonyhutter/zfs that referenced this issue Apr 15, 2020
As part of the Linux kernel's y2038 changes the time_t type has been
fully retired.  Callers are now required to use the time64_t type.

Rather than move to the new type, I've removed the few remaining
places where a time_t is used in the kernel code.  They've been
replaced with a uint64_t which is already how ZFS internally
handled these values.

Going forward we should work towards updating the remaining user
space time_t consumers to the 64-bit interfaces.

Reviewed-by: Matthew Macy <mmacy@freebsd.org>
Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes openzfs#10052
Closes openzfs#10064
tonyhutter pushed a commit to tonyhutter/zfs that referenced this issue Apr 15, 2020
The getrawmonotonic() and getrawmonotonic64() interfaces have been
fully retired.  Update gethrtime() to use the replacement interface
ktime_get_raw_ts64() which was introduced in the 4.18 kernel.

Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes openzfs#10052
Closes openzfs#10064
tonyhutter pushed a commit to tonyhutter/zfs that referenced this issue Apr 22, 2020
As part of the Linux kernel's y2038 changes the time_t type has been
fully retired.  Callers are now required to use the time64_t type.

Rather than move to the new type, I've removed the few remaining
places where a time_t is used in the kernel code.  They've been
replaced with a uint64_t which is already how ZFS internally
handled these values.

Going forward we should work towards updating the remaining user
space time_t consumers to the 64-bit interfaces.

Reviewed-by: Matthew Macy <mmacy@freebsd.org>
Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes openzfs#10052
Closes openzfs#10064
tonyhutter pushed a commit to tonyhutter/zfs that referenced this issue Apr 22, 2020
The getrawmonotonic() and getrawmonotonic64() interfaces have been
fully retired.  Update gethrtime() to use the replacement interface
ktime_get_raw_ts64() which was introduced in the 4.18 kernel.

Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes openzfs#10052
Closes openzfs#10064
tonyhutter pushed a commit to tonyhutter/zfs that referenced this issue Apr 22, 2020
As part of the Linux kernel's y2038 changes the time_t type has been
fully retired.  Callers are now required to use the time64_t type.

Rather than move to the new type, I've removed the few remaining
places where a time_t is used in the kernel code.  They've been
replaced with a uint64_t which is already how ZFS internally
handled these values.

Going forward we should work towards updating the remaining user
space time_t consumers to the 64-bit interfaces.

Reviewed-by: Matthew Macy <mmacy@freebsd.org>
Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes openzfs#10052
Closes openzfs#10064
tonyhutter pushed a commit to tonyhutter/zfs that referenced this issue Apr 22, 2020
The getrawmonotonic() and getrawmonotonic64() interfaces have been
fully retired.  Update gethrtime() to use the replacement interface
ktime_get_raw_ts64() which was introduced in the 4.18 kernel.

Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes openzfs#10052
Closes openzfs#10064
tonyhutter pushed a commit to tonyhutter/zfs that referenced this issue Apr 28, 2020
As part of the Linux kernel's y2038 changes the time_t type has been
fully retired.  Callers are now required to use the time64_t type.

Rather than move to the new type, I've removed the few remaining
places where a time_t is used in the kernel code.  They've been
replaced with a uint64_t which is already how ZFS internally
handled these values.

Going forward we should work towards updating the remaining user
space time_t consumers to the 64-bit interfaces.

Reviewed-by: Matthew Macy <mmacy@freebsd.org>
Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes openzfs#10052
Closes openzfs#10064
tonyhutter pushed a commit to tonyhutter/zfs that referenced this issue Apr 28, 2020
The getrawmonotonic() and getrawmonotonic64() interfaces have been
fully retired.  Update gethrtime() to use the replacement interface
ktime_get_raw_ts64() which was introduced in the 4.18 kernel.

Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes openzfs#10052
Closes openzfs#10064
tonyhutter pushed a commit that referenced this issue May 12, 2020
As part of the Linux kernel's y2038 changes the time_t type has been
fully retired.  Callers are now required to use the time64_t type.

Rather than move to the new type, I've removed the few remaining
places where a time_t is used in the kernel code.  They've been
replaced with a uint64_t which is already how ZFS internally
handled these values.

Going forward we should work towards updating the remaining user
space time_t consumers to the 64-bit interfaces.

Reviewed-by: Matthew Macy <mmacy@freebsd.org>
Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #10052
Closes #10064
tonyhutter pushed a commit that referenced this issue May 12, 2020
The getrawmonotonic() and getrawmonotonic64() interfaces have been
fully retired.  Update gethrtime() to use the replacement interface
ktime_get_raw_ts64() which was introduced in the 4.18 kernel.

Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #10052
Closes #10064
snajpa pushed a commit to vpsfreecz/zfs that referenced this issue May 28, 2020
The getrawmonotonic() and getrawmonotonic64() interfaces have been
fully retired.  Update gethrtime() to use the replacement interface
ktime_get_raw_ts64() which was introduced in the 4.18 kernel.

Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes openzfs#10052
Closes openzfs#10064
snajpa pushed a commit to vpsfreecz/zfs that referenced this issue May 28, 2020
As part of the Linux kernel's y2038 changes the time_t type has been
fully retired.  Callers are now required to use the time64_t type.

Rather than move to the new type, I've removed the few remaining
places where a time_t is used in the kernel code.  They've been
replaced with a uint64_t which is already how ZFS internally
handled these values.

Going forward we should work towards updating the remaining user
space time_t consumers to the 64-bit interfaces.

Reviewed-by: Matthew Macy <mmacy@freebsd.org>
Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes openzfs#10052
Closes openzfs#10064
jsai20 pushed a commit to jsai20/zfs that referenced this issue Mar 30, 2021
The getrawmonotonic() and getrawmonotonic64() interfaces have been
fully retired.  Update gethrtime() to use the replacement interface
ktime_get_raw_ts64() which was introduced in the 4.18 kernel.

Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes openzfs#10052
Closes openzfs#10064
jsai20 pushed a commit to jsai20/zfs that referenced this issue Mar 30, 2021
As part of the Linux kernel's y2038 changes the time_t type has been
fully retired.  Callers are now required to use the time64_t type.

Rather than move to the new type, I've removed the few remaining
places where a time_t is used in the kernel code.  They've been
replaced with a uint64_t which is already how ZFS internally
handled these values.

Going forward we should work towards updating the remaining user
space time_t consumers to the 64-bit interfaces.

Reviewed-by: Matthew Macy <mmacy@freebsd.org>
Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes openzfs#10052
Closes openzfs#10064
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Building Indicates an issue related to building binaries
Projects
None yet
Development

No branches or pull requests

2 participants