summaryrefslogtreecommitdiff
path: root/linux-user/syscall_defs.h
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2016-07-15 18:44:45 +0100
committerRiku Voipio <riku.voipio@linaro.org>2016-09-21 14:24:47 +0300
commit6080723102d1ad3b553769834d6a23e3f3d8250f (patch)
treed1d533c5a8555d81a20864cdb01d210920906302 /linux-user/syscall_defs.h
parent26a6fc96e0ca7522b855c2164bc6098240c286f6 (diff)
downloadqemu-6080723102d1ad3b553769834d6a23e3f3d8250f.tar.gz
linux-user: Implement FS_IOC_GETFLAGS and FS_IOC_SETFLAGS ioctls
Implement the FS_IOC_GETFLAGS and FS_IOC_SETFLAGS ioctls, as used by chattr. Note that the type information encoded in these ioctl numbers is at odds with the actual type the kernel accesses, as discussed in http://thread.gmane.org/gmane.linux.file-systems/80164. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Riku Voipio <riku.voipio@linaro.org>
Diffstat (limited to 'linux-user/syscall_defs.h')
-rw-r--r--linux-user/syscall_defs.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
index c0c9b5887c..c0e5cb0010 100644
--- a/linux-user/syscall_defs.h
+++ b/linux-user/syscall_defs.h
@@ -998,6 +998,12 @@ struct target_pollfd {
#define TARGET_FIBMAP TARGET_IO(0x00,1) /* bmap access */
#define TARGET_FIGETBSZ TARGET_IO(0x00,2) /* get the block size used for bmap */
+/* Note that the ioctl numbers claim type "long" but the actual type
+ * used by the kernel is "int".
+ */
+#define TARGET_FS_IOC_GETFLAGS TARGET_IOR('f', 1, long)
+#define TARGET_FS_IOC_SETFLAGS TARGET_IOW('f', 2, long)
+
#define TARGET_FS_IOC_FIEMAP TARGET_IOWR('f',11,struct fiemap)
/* cdrom commands */