#ifndef __BTRFS_IOCTL_H__
#define __BTRFS_IOCTL_H__
+#ifdef __cplusplus
+extern "C" {
+#endif
+
#include <asm/types.h>
#include <linux/ioctl.h>
-#include <time.h>
-#ifdef __cplusplus
-extern "C" {
+#ifndef __user
+#define __user
#endif
#define BTRFS_IOCTL_MAGIC 0x94
union {
struct {
__u64 size;
- struct btrfs_qgroup_inherit *qgroup_inherit;
+ struct btrfs_qgroup_inherit __user *qgroup_inherit;
};
__u64 unused[4];
};
__u64 max_id; /* out */
__u64 num_devices; /* out */
__u8 fsid[BTRFS_FSID_SIZE]; /* out */
- __u64 reserved[124]; /* pad to 1k */
+ __u32 nodesize; /* out */
+ __u32 sectorsize; /* out */
+ __u32 clone_alignment; /* out */
+ __u32 reserved32;
+ __u64 reserved[122]; /* pad to 1k */
+};
+
+struct btrfs_ioctl_feature_flags {
+ __u64 compat_flags;
+ __u64 compat_ro_flags;
+ __u64 incompat_flags;
};
/* balance control ioctl modes */
*/
#define BTRFS_SEND_FLAG_OMIT_END_CMD 0x4
+#define BTRFS_SEND_FLAG_MASK \
+ (BTRFS_SEND_FLAG_NO_FILE_DATA | \
+ BTRFS_SEND_FLAG_OMIT_STREAM_HEADER | \
+ BTRFS_SEND_FLAG_OMIT_END_CMD)
+
struct btrfs_ioctl_send_args {
__s64 send_fd; /* in */
__u64 clone_sources_count; /* in */
- __u64 *clone_sources; /* in */
+ __u64 __user *clone_sources; /* in */
__u64 parent_root; /* in */
__u64 flags; /* in */
__u64 reserved[4]; /* in */
};
-
/* Error codes as returned by the kernel */
enum btrfs_err_code {
notused,