Print this page
4171 clean up spa_feature_*() interfaces
4172 implement extensible_dataset feature for use by other zpool features
Reviewed by: Max Grossman <max.grossman@delphix.com>
Reviewed by: Christopher Siden <christopher.siden@delphix.com>
Reviewed by: George Wilson <george.wilson@delphix.com>

@@ -21,11 +21,11 @@
  * Copyright 2010 Sun Microsystems, Inc.  All rights reserved.
  * Use is subject to license terms.
  */
 
 /*
- * Copyright (c) 2012 by Delphix. All rights reserved.
+ * Copyright (c) 2013 by Delphix. All rights reserved.
  * Copyright (c) 2013 by Saso Kiselkov. All rights reserved.
  */
 
 /*
  * The zfs plug-in routines for GRUB are:

@@ -964,10 +964,11 @@
  * When this list is updated the version number in usr/src/grub/capability
  * must be incremented to ensure the new grub gets installed.
  */
 static const char *spa_feature_names[] = {
         "org.illumos:lz4_compress",
+        "com.delphix:extensible_dataset",
         NULL
 };
 
 /*
  * Checks whether the MOS features that are active are supported by this

@@ -1042,11 +1043,11 @@
 
         if (errnum = zap_lookup(mdn, DMU_POOL_ROOT_DATASET, &objnum,
             stack))
                 return (errnum);
 
-        if (errnum = dnode_get(mosmdn, objnum, DMU_OT_DSL_DIR, mdn, stack))
+        if (errnum = dnode_get(mosmdn, objnum, 0, mdn, stack))
                 return (errnum);
 
         if (fsname == NULL) {
                 headobj =
                     ((dsl_dir_phys_t *)DN_BONUS(mdn))->dd_head_dataset_obj;

@@ -1084,11 +1085,11 @@
                         return (errnum);
 
                 if (zap_lookup(mdn, cname, &objnum, stack))
                         return (ERR_FILESYSTEM_NOT_FOUND);
 
-                if (errnum = dnode_get(mosmdn, objnum, DMU_OT_DSL_DIR,
+                if (errnum = dnode_get(mosmdn, objnum, 0,
                     mdn, stack))
                         return (errnum);
 
                 *fsname = ch;
                 if (issnapshot)

@@ -1097,11 +1098,11 @@
         headobj = ((dsl_dir_phys_t *)DN_BONUS(mdn))->dd_head_dataset_obj;
         if (obj)
                 *obj = headobj;
 
 skip:
-        if (errnum = dnode_get(mosmdn, headobj, DMU_OT_DSL_DATASET, mdn, stack))
+        if (errnum = dnode_get(mosmdn, headobj, 0, mdn, stack))
                 return (errnum);
         if (issnapshot) {
                 uint64_t snapobj;
 
                 snapobj = ((dsl_dataset_phys_t *)DN_BONUS(mdn))->

@@ -1110,12 +1111,11 @@
                 if (errnum = dnode_get(mosmdn, snapobj,
                     DMU_OT_DSL_DS_SNAP_MAP, mdn, stack))
                         return (errnum);
                 if (zap_lookup(mdn, snapname + 1, &headobj, stack))
                         return (ERR_FILESYSTEM_NOT_FOUND);
-                if (errnum = dnode_get(mosmdn, headobj,
-                    DMU_OT_DSL_DATASET, mdn, stack))
+                if (errnum = dnode_get(mosmdn, headobj, 0, mdn, stack))
                         return (errnum);
                 if (obj)
                         *obj = headobj;
         }