17 * information: Portions Copyright [yyyy] [name of copyright owner]
18 *
19 * CDDL HEADER END
20 */
21 /*
22 * Copyright 2010 Sun Microsystems, Inc. All rights reserved.
23 * Use is subject to license terms.
24 * Copyright (c) 2012, Joyent, Inc. All rights reserved.
25 */
26
27 #ifndef _ZFS_PROP_H
28 #define _ZFS_PROP_H
29
30 #include <sys/fs/zfs.h>
31 #include <sys/types.h>
32
33 #ifdef __cplusplus
34 extern "C" {
35 #endif
36
37 /*
38 * For index types (e.g. compression and checksum), we want the numeric value
39 * in the kernel, but the string value in userland.
40 */
41 typedef enum {
42 PROP_TYPE_NUMBER, /* numeric value */
43 PROP_TYPE_STRING, /* string value */
44 PROP_TYPE_INDEX /* numeric value indexed by string */
45 } zprop_type_t;
46
47 typedef enum {
48 PROP_DEFAULT,
49 PROP_READONLY,
50 PROP_INHERIT,
51 /*
52 * ONETIME properties are a sort of conglomeration of READONLY
53 * and INHERIT. They can be set only during object creation,
54 * after that they are READONLY. If not explicitly set during
55 * creation, they can be inherited.
56 */
|
17 * information: Portions Copyright [yyyy] [name of copyright owner]
18 *
19 * CDDL HEADER END
20 */
21 /*
22 * Copyright 2010 Sun Microsystems, Inc. All rights reserved.
23 * Use is subject to license terms.
24 * Copyright (c) 2012, Joyent, Inc. All rights reserved.
25 */
26
27 #ifndef _ZFS_PROP_H
28 #define _ZFS_PROP_H
29
30 #include <sys/fs/zfs.h>
31 #include <sys/types.h>
32
33 #ifdef __cplusplus
34 extern "C" {
35 #endif
36
37 #define MAXLIMIT ((uint64_t)-1)
38
39 /*
40 * For index types (e.g. compression and checksum), we want the numeric value
41 * in the kernel, but the string value in userland.
42 */
43 typedef enum {
44 PROP_TYPE_NUMBER, /* numeric value */
45 PROP_TYPE_STRING, /* string value */
46 PROP_TYPE_INDEX /* numeric value indexed by string */
47 } zprop_type_t;
48
49 typedef enum {
50 PROP_DEFAULT,
51 PROP_READONLY,
52 PROP_INHERIT,
53 /*
54 * ONETIME properties are a sort of conglomeration of READONLY
55 * and INHERIT. They can be set only during object creation,
56 * after that they are READONLY. If not explicitly set during
57 * creation, they can be inherited.
58 */
|