1 /****************************************************************************
2 ****************************************************************************
4 *** This header was automatically generated from a Linux kernel header
5 *** of the same name, to make information necessary for userspace to
6 *** call into the kernel available to libc. It contains only constants,
7 *** structures, and macros generated from the original header, and thus,
8 *** contains no copyrightable information.
10 ****************************************************************************
11 ****************************************************************************/
12 #ifndef _LINUX_DM_IOCTL_V4_H
13 #define _LINUX_DM_IOCTL_V4_H
15 #include <linux/types.h>
17 #define DM_DIR "mapper"
18 #define DM_MAX_TYPE_NAME 16
19 #define DM_NAME_LEN 128
20 #define DM_UUID_LEN 129
29 uint32_t target_count;
37 char name[DM_NAME_LEN];
38 char uuid[DM_UUID_LEN];
42 struct dm_target_spec {
43 uint64_t sector_start;
49 char target_type[DM_MAX_TYPE_NAME];
53 struct dm_target_deps {
65 struct dm_target_versions {
72 struct dm_target_msg {
98 DM_DEV_SET_GEOMETRY_CMD
101 #define DM_IOCTL 0xfd
103 #define DM_VERSION _IOWR(DM_IOCTL, DM_VERSION_CMD, struct dm_ioctl)
104 #define DM_REMOVE_ALL _IOWR(DM_IOCTL, DM_REMOVE_ALL_CMD, struct dm_ioctl)
105 #define DM_LIST_DEVICES _IOWR(DM_IOCTL, DM_LIST_DEVICES_CMD, struct dm_ioctl)
107 #define DM_DEV_CREATE _IOWR(DM_IOCTL, DM_DEV_CREATE_CMD, struct dm_ioctl)
108 #define DM_DEV_REMOVE _IOWR(DM_IOCTL, DM_DEV_REMOVE_CMD, struct dm_ioctl)
109 #define DM_DEV_RENAME _IOWR(DM_IOCTL, DM_DEV_RENAME_CMD, struct dm_ioctl)
110 #define DM_DEV_SUSPEND _IOWR(DM_IOCTL, DM_DEV_SUSPEND_CMD, struct dm_ioctl)
111 #define DM_DEV_STATUS _IOWR(DM_IOCTL, DM_DEV_STATUS_CMD, struct dm_ioctl)
112 #define DM_DEV_WAIT _IOWR(DM_IOCTL, DM_DEV_WAIT_CMD, struct dm_ioctl)
114 #define DM_TABLE_LOAD _IOWR(DM_IOCTL, DM_TABLE_LOAD_CMD, struct dm_ioctl)
115 #define DM_TABLE_CLEAR _IOWR(DM_IOCTL, DM_TABLE_CLEAR_CMD, struct dm_ioctl)
116 #define DM_TABLE_DEPS _IOWR(DM_IOCTL, DM_TABLE_DEPS_CMD, struct dm_ioctl)
117 #define DM_TABLE_STATUS _IOWR(DM_IOCTL, DM_TABLE_STATUS_CMD, struct dm_ioctl)
119 #define DM_LIST_VERSIONS _IOWR(DM_IOCTL, DM_LIST_VERSIONS_CMD, struct dm_ioctl)
121 #define DM_TARGET_MSG _IOWR(DM_IOCTL, DM_TARGET_MSG_CMD, struct dm_ioctl)
122 #define DM_DEV_SET_GEOMETRY _IOWR(DM_IOCTL, DM_DEV_SET_GEOMETRY_CMD, struct dm_ioctl)
124 #define DM_VERSION_MAJOR 4
125 #define DM_VERSION_MINOR 14
126 #define DM_VERSION_PATCHLEVEL 0
127 #define DM_VERSION_EXTRA "-ioctl (2008-04-23)"
129 #define DM_READONLY_FLAG (1 << 0)
130 #define DM_SUSPEND_FLAG (1 << 1)
131 #define DM_PERSISTENT_DEV_FLAG (1 << 3)
133 #define DM_STATUS_TABLE_FLAG (1 << 4)
135 #define DM_ACTIVE_PRESENT_FLAG (1 << 5)
136 #define DM_INACTIVE_PRESENT_FLAG (1 << 6)
138 #define DM_BUFFER_FULL_FLAG (1 << 8)
140 #define DM_SKIP_BDGET_FLAG (1 << 9)
142 #define DM_SKIP_LOCKFS_FLAG (1 << 10)
144 #define DM_NOFLUSH_FLAG (1 << 11)