WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] [PATCH] Support for zfs version 16.

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] [PATCH] Support for zfs version 16.
From: Susan Kamm-Worrell <Susan.Kamm-Worrell@xxxxxxx>
Date: Thu, 02 Jul 2009 17:30:55 -0600
Delivery-date: Thu, 02 Jul 2009 16:32:13 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Thunderbird 2.0.0.6 (X11/20071009)
# HG changeset patch
# User Susan Kamm-Worrell <Susan.Kamm-Worrell@xxxxxxx>
# Date 1246570286 25200
# Node ID 02317bbdeb279f32c841127455e21d5e99279b3b
# Parent  033debac041b0ea88fab4a1d70d3247d2d7fe52c
Support for zfs version 16.

Remove version checks to support boot of ZFS root filesystem version 16.

Signed-off-by: Susan Kamm-Worrell <susan.kamm-worrell@xxxxxxx>

diff --git a/tools/libfsimage/zfs/fsys_zfs.c b/tools/libfsimage/zfs/fsys_zfs.c
--- a/tools/libfsimage/zfs/fsys_zfs.c
+++ b/tools/libfsimage/zfs/fsys_zfs.c
@@ -297,8 +297,7 @@
        if (zio_checksum_verify(&bp, (char *)ub, UBERBLOCK_SIZE) != 0)
                return (-1);
 
-       if (uber->ub_magic == UBERBLOCK_MAGIC &&
-           uber->ub_version > 0 && uber->ub_version <= SPA_VERSION)
+       if (uber->ub_magic == UBERBLOCK_MAGIC && uber->ub_version > 0)
                return (0);
 
        return (-1);
@@ -761,8 +760,6 @@
 
        if ((errnum = zap_lookup(ffi, dn, ZPL_VERSION_STR, &version, stack)))
                return (errnum);
-       if (version > ZPL_VERSION)
-               return (-1);
 
        if ((errnum = zap_lookup(ffi, dn, ZFS_ROOT_OBJ, &objnum, stack)))
                return (errnum);
diff --git a/tools/libfsimage/zfs/zfs-include/dmu_objset.h 
b/tools/libfsimage/zfs/zfs-include/dmu_objset.h
--- a/tools/libfsimage/zfs/zfs-include/dmu_objset.h
+++ b/tools/libfsimage/zfs/zfs-include/dmu_objset.h
@@ -17,7 +17,7 @@
  *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  */
 /*
- * Copyright 2007 Sun Microsystems, Inc.  All rights reserved.
+ * Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
  * Use is subject to license terms.
  */
 
@@ -28,8 +28,11 @@
        dnode_phys_t os_meta_dnode;
        zil_header_t os_zil_header;
        uint64_t os_type;
-       char os_pad[1024 - sizeof (dnode_phys_t) - sizeof (zil_header_t) -
-           sizeof (uint64_t)];
+       uint64_t os_flags;
+       char os_pad[2048 - sizeof (dnode_phys_t)*3 -
+           sizeof (zil_header_t) - sizeof (uint64_t)*2];
+       dnode_phys_t os_userused_dnode;
+       dnode_phys_t os_groupused_dnode;
 } objset_phys_t;
 
 #endif /* _SYS_DMU_OBJSET_H */
diff --git a/tools/libfsimage/zfs/zfs-include/zfs.h 
b/tools/libfsimage/zfs/zfs-include/zfs.h
--- a/tools/libfsimage/zfs/zfs-include/zfs.h
+++ b/tools/libfsimage/zfs/zfs-include/zfs.h
@@ -17,7 +17,7 @@
  *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  */
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All rights reserved.
+ * Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
  * Use is subject to license terms.
  */
 
@@ -28,7 +28,7 @@
 /*
  * On-disk version number.
  */
-#define        SPA_VERSION                     14ULL
+#define        SPA_VERSION                     16ULL
 
 /*
  * The following are configuration names used in the nvlist describing a pool's
diff --git a/tools/libfsimage/zfs/zfs-include/zfs_znode.h 
b/tools/libfsimage/zfs/zfs-include/zfs_znode.h
--- a/tools/libfsimage/zfs/zfs-include/zfs_znode.h
+++ b/tools/libfsimage/zfs/zfs-include/zfs_znode.h
@@ -17,7 +17,7 @@
  *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  */
 /*
- * Copyright 2007 Sun Microsystems, Inc.  All rights reserved.
+ * Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
  * Use is subject to license terms.
  */
 
@@ -28,7 +28,7 @@
 #define        ZFS_ROOT_OBJ            "ROOT"
 #define        ZPL_VERSION_STR         "VERSION"
 
-#define        ZPL_VERSION             3ULL
+#define        ZPL_VERSION             4ULL
 
 #define        ZFS_DIRENT_OBJ(de) BF64_GET(de, 0, 48)
 
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-devel] [PATCH] Support for zfs version 16., Susan Kamm-Worrell <=