Skip to content

Commit

Permalink
linux 6.7 compat: handle member rename in current_time() check
Browse files Browse the repository at this point in the history
6.7 changed the names of the time members in struct inode. We still want
to use their specific types to handle <4.18 properly, so we just use a
define to rename it back to what we need it to be in this test.

Signed-off-by: Rob Norris <robn@despairlabs.com>
Sponsored-by: https://github.com/sponsors/robn
  • Loading branch information
robn committed Dec 16, 2023
1 parent dbda451 commit cdc0e7f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions config/kernel-current-time.m4
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,12 @@ dnl #
dnl # 4.9, current_time() added
dnl # 4.18, return type changed from timespec to timespec64
dnl #
dnl # 6.7 renamed i_atime but did not change its type. We use a define to
dnl # rename it back for this test.
dnl #
AC_DEFUN([ZFS_AC_KERNEL_SRC_CURRENT_TIME], [
ZFS_LINUX_TEST_SRC([current_time], [
#define __i_atime i_atime
#include <linux/fs.h>
], [
struct inode ip __attribute__ ((unused));
Expand Down

0 comments on commit cdc0e7f

Please sign in to comment.