mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-24 11:18:52 +03:00
Add zfs module feature and property info to sysfs
This extends our sysfs '/sys/module/zfs' entry to include feature and property attributes. The primary consumer of this information is user processes, like the zfs CLI, that need to know what the current loaded ZFS module supports. The libzfs binary will consult this information when instantiating the zfs and zpool property tables and the pool features table. This introduces 4 kernel objects (dirs) into '/sys/module/zfs' with corresponding attributes (files): features.runtime features.pool properties.dataset properties.pool Reviewed-by: Matthew Ahrens <mahrens@delphix.com> Reviewed-by: Tony Hutter <hutter2@llnl.gov> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Don Brady <don.brady@delphix.com> Closes #7706
This commit is contained in:
committed by
Brian Behlendorf
parent
bb91178e60
commit
e8bcb693d6
@@ -85,6 +85,7 @@ typedef struct zfeature_info {
|
||||
const char *fi_guid; /* On-disk feature identifier */
|
||||
const char *fi_desc; /* Feature description */
|
||||
zfeature_flags_t fi_flags;
|
||||
boolean_t fi_zfs_mod_supported; /* supported by running zfs module */
|
||||
/* array of dependencies, terminated by SPA_FEATURE_NONE */
|
||||
const spa_feature_t *fi_depends;
|
||||
} zfeature_info_t;
|
||||
@@ -98,6 +99,7 @@ extern zfeature_info_t spa_feature_table[SPA_FEATURES];
|
||||
extern boolean_t zfeature_is_valid_guid(const char *);
|
||||
|
||||
extern boolean_t zfeature_is_supported(const char *);
|
||||
extern int zfeature_lookup_guid(const char *, spa_feature_t *);
|
||||
extern int zfeature_lookup_name(const char *, spa_feature_t *);
|
||||
extern boolean_t zfeature_depends_on(spa_feature_t, spa_feature_t);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user