Whamcloud - gitweb
LU-15422 build: Update ZFS version to 2.0.7 06/46006/8
authorJames Simmons <jsimmons@infradead.org>
Thu, 3 Feb 2022 19:23:16 +0000 (14:23 -0500)
committerOleg Drokin <green@whamcloud.com>
Mon, 7 Feb 2022 23:40:17 +0000 (23:40 +0000)
Update ZFS version to 2.0.7. The changes are listed in:
https://github.com/openzfs/zfs/releases/tag/zfs-2.0.7

Change-Id: I5dcff31af1458c5c9d2fe17256e31751535578d8
Signed-off-by: James Simmons <jsimmons@infradead.org>
Reviewed-on: https://review.whamcloud.com/46006
Tested-by: jenkins <devops@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Olaf Faaland-LLNL <faaland1@llnl.gov>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
config/lustre-build-zfs.m4
contrib/lbuild/lbuild
lustre/ChangeLog
lustre/osd-zfs/osd_internal.h

index 27b0c0f..f17f296 100644 (file)
@@ -767,6 +767,19 @@ your distribution.
                        AC_DEFINE(HAVE_DB_DIRTY_RECORDS_LIST, 1,
                                [Have db_dirty_records list_t])
                ])
+               dnl #
+               dnl # ZFS 2.0 renamed sys/refcount.h to zfs_refcount.h
+               dnl # This build issue shows up with ZFS 2.0.7 and Lustre 2.12 LTS
+               dnl #
+               LB_CHECK_COMPILE([if ZFS renamed sys/refcount to zfs_refcount.h],
+               zfs_zfs_refcount, [
+                       #include <sys/zfs_refcount.h>
+               ],[
+                       zfs_refcount_add((zfs_refcount_t *) NULL, NULL);
+               ],[
+                       AC_DEFINE(HAVE_ZFS_REFCOUNT_HEADER, 1,
+                               [Have zfs_refcount.h])
+               ])
        ])
 
        AS_IF([test "x$enable_zfs" = xyes], [
index 303d332..1f64c5d 100755 (executable)
@@ -1019,7 +1019,7 @@ build_spl_zfs() {
     # The spl/zfs spec files expect RPM_BUILD_ROOT to point to the root of the
     # destination for the rpms
     export RPM_BUILD_ROOT=$TOPDIR
-    SPLZFSVER=${SPLZFSVER:-2.0.6}
+    SPLZFSVER=${SPLZFSVER:-2.0.7}
     SPLZFSTAG=${SPLZFSTAG:-}
     # "spl zfs" prior to 0.8.0
     # "zfs" for 0.8.0 and later
index b3fa609..978b554 100644 (file)
@@ -53,7 +53,7 @@ TBD Whamcloud
          5.11.0-31            (Ubuntu 20.04.3 HWE)
          5.11.0               (vanilla kernel.org)
        * Recommended e2fsprogs version: 1.46.2.wc1 or newer
-       * Recommended ZFS version: 2.0.6
+       * Recommended ZFS version: 2.0.7
        * NFS export disabled when stack size < 8192 (32-bit Lustre clients),
          since the NFSv4 export of Lustre filesystem with 4K stack may cause a
          stack overflow. For more information, please refer to bugzilla 17630.
index e3fcd3d..176ef7b 100644 (file)
@@ -39,6 +39,7 @@
 #ifndef _OSD_INTERNAL_H
 #define _OSD_INTERNAL_H
 
+#include <linux/refcount.h>
 #include <dt_object.h>
 #include <md_object.h>
 #include <lustre_quota.h>
@@ -49,6 +50,9 @@
 #endif
 #include <sys/arc.h>
 #include <sys/nvpair.h>
+#ifdef HAVE_ZFS_REFCOUNT_HEADER
+#include <sys/zfs_refcount.h>
+#endif
 #include <sys/zfs_znode.h>
 #include <sys/zap.h>
 #include <sys/dbuf.h>
 
 #define OSD_MAX_CACHE_SIZE OBD_OBJECT_EOF
 
+#ifndef HAVE_ZFS_REFCOUNT_HEADER
 #ifndef HAVE_ZFS_REFCOUNT_ADD
 #define zfs_refcount_add       refcount_add
 #endif
+#endif
 
 extern const struct dt_body_operations osd_body_scrub_ops;
 extern const struct dt_body_operations osd_body_ops;