aboutsummaryrefslogtreecommitdiff
path: root/sys/contrib/openzfs/module/zcommon
diff options
context:
space:
mode:
Diffstat (limited to 'sys/contrib/openzfs/module/zcommon')
-rw-r--r--sys/contrib/openzfs/module/zcommon/zfeature_common.c13
-rw-r--r--sys/contrib/openzfs/module/zcommon/zpool_prop.c4
2 files changed, 12 insertions, 5 deletions
diff --git a/sys/contrib/openzfs/module/zcommon/zfeature_common.c b/sys/contrib/openzfs/module/zcommon/zfeature_common.c
index 34ebabcf3b3c..e95a85e89ba2 100644
--- a/sys/contrib/openzfs/module/zcommon/zfeature_common.c
+++ b/sys/contrib/openzfs/module/zcommon/zfeature_common.c
@@ -222,9 +222,15 @@ zfs_mod_supported_feature(const char *name)
* features are supported.
*
* The equivalent _can_ be done on FreeBSD by way of the sysctl
- * tree, but this has not been done yet.
+ * tree, but this has not been done yet. Therefore, we return
+ * that all features except edonr are supported.
*/
-#if defined(_KERNEL) || defined(LIB_ZPOOL_BUILD) || defined(__FreeBSD__)
+#if defined(__FreeBSD__)
+ if (strcmp(name, "org.illumos:edonr") == 0)
+ return (B_FALSE);
+ else
+ return (B_TRUE);
+#elif defined(_KERNEL) || defined(LIB_ZPOOL_BUILD)
return (B_TRUE);
#else
return (zfs_mod_supported(ZFS_SYSFS_POOL_FEATURES, name));
@@ -440,8 +446,6 @@ zpool_feature_init(void)
skein_deps);
}
-#if !defined(__FreeBSD__)
-
{
static const spa_feature_t edonr_deps[] = {
SPA_FEATURE_EXTENSIBLE_DATASET,
@@ -453,7 +457,6 @@ zpool_feature_init(void)
ZFEATURE_FLAG_PER_DATASET, ZFEATURE_TYPE_BOOLEAN,
edonr_deps);
}
-#endif
{
static const spa_feature_t redact_books_deps[] = {
diff --git a/sys/contrib/openzfs/module/zcommon/zpool_prop.c b/sys/contrib/openzfs/module/zcommon/zpool_prop.c
index 815fad6df0e0..6299d371f25d 100644
--- a/sys/contrib/openzfs/module/zcommon/zpool_prop.c
+++ b/sys/contrib/openzfs/module/zcommon/zpool_prop.c
@@ -22,6 +22,7 @@
* Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved.
* Copyright 2011 Nexenta Systems, Inc. All rights reserved.
* Copyright (c) 2012, 2018 by Delphix. All rights reserved.
+ * Copyright (c) 2021, Colm Buckley <colm@tuatha.org>
*/
#include <sys/zio.h>
@@ -71,6 +72,9 @@ zpool_prop_init(void)
PROP_DEFAULT, ZFS_TYPE_POOL, "<file> | none", "CACHEFILE");
zprop_register_string(ZPOOL_PROP_COMMENT, "comment", NULL,
PROP_DEFAULT, ZFS_TYPE_POOL, "<comment-string>", "COMMENT");
+ zprop_register_string(ZPOOL_PROP_COMPATIBILITY, "compatibility",
+ "off", PROP_DEFAULT, ZFS_TYPE_POOL,
+ "<file[,file...]> | off | legacy", "COMPATIBILITY");
/* readonly number properties */
zprop_register_number(ZPOOL_PROP_SIZE, "size", 0, PROP_READONLY,