FreeBSD ZFS
The Zettabyte File System
|
#include <sys/cred.h>
#include <sys/dmu.h>
#include <sys/zio.h>
#include <sys/dsl_deleg.h>
#include <sys/spa.h>
#include <sys/zfs_stat.h>
#include <sys/nvpair.h>
#include <sys/dsl_deleg.h>
#include <sys/zfs_stat.h>
Go to the source code of this file.
Data Structures | |
struct | drr_begin |
zfs ioctl command structure More... | |
struct | drr_end |
struct | drr_object |
bonus content follows drr-toguid More... | |
struct | drr_freeobjects |
struct | drr_write |
content follows drr_key More... | |
struct | drr_free |
struct | drr_write_byref |
struct | drr_spill |
spill data follows drr_pad More... | |
struct | dmu_replay_record |
struct | dmu_diff_record |
The diff reports back ranges of free or in-use objects. More... | |
struct | zinject_record |
struct | zfs_share |
struct | zfs_cmd |
struct | zfs_useracct |
struct | zfs_creat |
struct | zfs_soft_state |
Defines | |
#define | ZFS_SNAPDIR_HIDDEN 0 |
#define | ZFS_SNAPDIR_VISIBLE 1 |
#define | DMU_GET_STREAM_HDRTYPE(vi) BF64_GET((vi), 0, 2) |
#define | DMU_SET_STREAM_HDRTYPE(vi, x) BF64_SET((vi), 0, 2, x) |
#define | DMU_GET_FEATUREFLAGS(vi) BF64_GET((vi), 2, 30) |
#define | DMU_SET_FEATUREFLAGS(vi, x) BF64_SET((vi), 2, 30, x) |
#define | DMU_BACKUP_FEATURE_DEDUP (0x1) |
#define | DMU_BACKUP_FEATURE_DEDUPPROPS (0x2) |
#define | DMU_BACKUP_FEATURE_SA_SPILL (0x4) |
#define | DMU_BACKUP_FEATURE_MASK |
Mask of all supported backup features. | |
#define | DMU_STREAM_SUPPORTED(x) (!((x) & ~DMU_BACKUP_FEATURE_MASK)) |
Are all features in the given flag word currently supported? | |
#define | DMU_BACKUP_MAGIC 0x2F5bacbacULL |
#define | DRR_FLAG_CLONE (1<<0) |
#define | DRR_FLAG_CI_DATA (1<<1) |
#define | DRR_CHECKSUM_DEDUP (1<<0) |
#define | DRR_IS_DEDUP_CAPABLE(flags) ((flags) & DRR_CHECKSUM_DEDUP) |
#define | ZINJECT_NULL 0x1 |
#define | ZINJECT_FLUSH_ARC 0x2 |
#define | ZINJECT_UNLOAD_SPA 0x4 |
#define | ZFSDEV_MAX_MINOR (1 << 16) |
#define | ZFS_MIN_MINOR (ZFSDEV_MAX_MINOR + 1) |
#define | ZPOOL_EXPORT_AFTER_SPLIT 0x1 |
Typedefs | |
typedef enum drr_headertype | drr_headertype_t |
Header types for zfs send streams. | |
typedef struct dmu_replay_record | dmu_replay_record_t |
typedef enum diff_type | diff_type_t |
diff record range types | |
typedef struct dmu_diff_record | dmu_diff_record_t |
The diff reports back ranges of free or in-use objects. | |
typedef struct zinject_record | zinject_record_t |
typedef struct zfs_share | zfs_share_t |
typedef enum zfs_case | zfs_case_t |
ZFS file systems may behave the usual, POSIX-compliant way, where name lookups are case-sensitive. | |
typedef struct zfs_cmd | zfs_cmd_t |
typedef struct zfs_useracct | zfs_useracct_t |
typedef struct zfs_creat | zfs_creat_t |
typedef struct zfs_soft_state | zfs_soft_state_t |
Enumerations | |
enum | drr_headertype { DMU_SUBSTREAM = 0x1, DMU_COMPOUNDSTREAM = 0x2 } |
Header types for zfs send streams. More... | |
enum | diff_type { DDR_NONE = 0x1, DDR_INUSE = 0x2, DDR_FREE = 0x4 } |
diff record range types More... | |
enum | zfs_case { ZFS_CASE_SENSITIVE, ZFS_CASE_INSENSITIVE, ZFS_CASE_MIXED } |
ZFS file systems may behave the usual, POSIX-compliant way, where name lookups are case-sensitive. More... | |
enum | zfs_soft_state_type { ZSST_ZVOL, ZSST_CTLDEV } |
ZFS minor numbers can refer to either a control device instance or a zvol. More... | |
Functions | |
int | zfs_secpolicy_snapshot_perms (const char *name, cred_t *cr) |
int | zfs_secpolicy_rename_perms (const char *from, const char *to, cred_t *cr) |
int | zfs_secpolicy_destroy_perms (const char *name, cred_t *cr) |
int | zfs_busy (void) |
int | zfs_unmount_snap (const char *, void *) |
void * | zfsdev_get_soft_state (minor_t minor, enum zfs_soft_state_type which) |
minor_t | zfsdev_minor_alloc (void) |
Find a free minor number. | |
Variables | |
void * | zfsdev_state |
The zfsdev_state structure is protected by spa_namespace_lock from being modified while it's being used, e.g. |
#define DMU_BACKUP_FEATURE_DEDUP (0x1) |
Definition at line 72 of file zfs_ioctl.h.
#define DMU_BACKUP_FEATURE_DEDUPPROPS (0x2) |
Definition at line 73 of file zfs_ioctl.h.
#define DMU_BACKUP_FEATURE_MASK |
Mask of all supported backup features.
Definition at line 79 of file zfs_ioctl.h.
#define DMU_BACKUP_FEATURE_SA_SPILL (0x4) |
Definition at line 74 of file zfs_ioctl.h.
#define DMU_BACKUP_MAGIC 0x2F5bacbacULL |
Definition at line 85 of file zfs_ioctl.h.
#define DMU_GET_FEATUREFLAGS | ( | vi | ) | BF64_GET((vi), 2, 30) |
Definition at line 65 of file zfs_ioctl.h.
#define DMU_GET_STREAM_HDRTYPE | ( | vi | ) | BF64_GET((vi), 0, 2) |
Definition at line 62 of file zfs_ioctl.h.
#define DMU_SET_FEATUREFLAGS | ( | vi, | |
x | |||
) | BF64_SET((vi), 2, 30, x) |
Definition at line 66 of file zfs_ioctl.h.
#define DMU_SET_STREAM_HDRTYPE | ( | vi, | |
x | |||
) | BF64_SET((vi), 0, 2, x) |
Definition at line 63 of file zfs_ioctl.h.
#define DMU_STREAM_SUPPORTED | ( | x | ) | (!((x) & ~DMU_BACKUP_FEATURE_MASK)) |
Are all features in the given flag word currently supported?
Definition at line 83 of file zfs_ioctl.h.
#define DRR_CHECKSUM_DEDUP (1<<0) |
Definition at line 94 of file zfs_ioctl.h.
#define DRR_FLAG_CI_DATA (1<<1) |
Definition at line 88 of file zfs_ioctl.h.
#define DRR_FLAG_CLONE (1<<0) |
Definition at line 87 of file zfs_ioctl.h.
#define DRR_IS_DEDUP_CAPABLE | ( | flags | ) | ((flags) & DRR_CHECKSUM_DEDUP) |
Definition at line 96 of file zfs_ioctl.h.
#define ZFS_MIN_MINOR (ZFSDEV_MAX_MINOR + 1) |
Definition at line 331 of file zfs_ioctl.h.
#define ZFS_SNAPDIR_HIDDEN 0 |
Definition at line 46 of file zfs_ioctl.h.
#define ZFS_SNAPDIR_VISIBLE 1 |
Definition at line 47 of file zfs_ioctl.h.
#define ZFSDEV_MAX_MINOR (1 << 16) |
Definition at line 330 of file zfs_ioctl.h.
#define ZINJECT_FLUSH_ARC 0x2 |
Definition at line 264 of file zfs_ioctl.h.
#define ZINJECT_NULL 0x1 |
Definition at line 263 of file zfs_ioctl.h.
#define ZINJECT_UNLOAD_SPA 0x4 |
Definition at line 265 of file zfs_ioctl.h.
#define ZPOOL_EXPORT_AFTER_SPLIT 0x1 |
Definition at line 333 of file zfs_ioctl.h.
typedef enum diff_type diff_type_t |
diff record range types
typedef struct dmu_diff_record dmu_diff_record_t |
The diff reports back ranges of free or in-use objects.
typedef struct dmu_replay_record dmu_replay_record_t |
typedef enum drr_headertype drr_headertype_t |
Header types for zfs send streams.
typedef enum zfs_case zfs_case_t |
ZFS file systems may behave the usual, POSIX-compliant way, where name lookups are case-sensitive.
They may also be set up so that all the name lookups are case-insensitive, or so that only some lookups, the ones that set an FIGNORECASE flag, are case-insensitive.
typedef struct zfs_creat zfs_creat_t |
typedef struct zfs_share zfs_share_t |
typedef struct zfs_soft_state zfs_soft_state_t |
typedef struct zfs_useracct zfs_useracct_t |
typedef struct zinject_record zinject_record_t |
enum diff_type |
diff record range types
Definition at line 231 of file zfs_ioctl.h.
enum drr_headertype |
Header types for zfs send streams.
Definition at line 57 of file zfs_ioctl.h.
enum zfs_case |
ZFS file systems may behave the usual, POSIX-compliant way, where name lookups are case-sensitive.
They may also be set up so that all the name lookups are case-insensitive, or so that only some lookups, the ones that set an FIGNORECASE flag, are case-insensitive.
Definition at line 280 of file zfs_ioctl.h.
enum zfs_soft_state_type |
ZFS minor numbers can refer to either a control device instance or a zvol.
Depending on the value of zss_type, zss_data points to either a zvol_state_t or a zfs_onexit_t.
Definition at line 354 of file zfs_ioctl.h.
int zfs_busy | ( | void | ) |
Definition at line 2345 of file zfs_vfsops.c.
int zfs_secpolicy_destroy_perms | ( | const char * | name, |
cred_t * | cr | ||
) |
Definition at line 695 of file zfs_ioctl.c.
int zfs_secpolicy_rename_perms | ( | const char * | from, |
const char * | to, | ||
cred_t * | cr | ||
) |
Definition at line 734 of file zfs_ioctl.c.
int zfs_secpolicy_snapshot_perms | ( | const char * | name, |
cred_t * | cr | ||
) |
Definition at line 846 of file zfs_ioctl.c.
int zfs_unmount_snap | ( | const char * | , |
void * | |||
) |
Definition at line 3157 of file zfs_ioctl.c.
void* zfsdev_get_soft_state | ( | minor_t | minor, |
enum zfs_soft_state_type | which | ||
) |
Definition at line 5129 of file zfs_ioctl.c.
minor_t zfsdev_minor_alloc | ( | void | ) |
Find a free minor number.
Definition at line 5076 of file zfs_ioctl.c.
void* zfsdev_state |
The zfsdev_state structure is protected by spa_namespace_lock from being modified while it's being used, e.g.
an open that comes in before a create finishes. It's also protected from temporary opens of the dataset so that, e.g., an open doesn't get a spurious EBUSY.