summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Graf <agraf@suse.de>2009-04-14 16:27:36 +0200
committerhyokeun <hyokeun.jeon@samsung.com>2016-09-06 15:55:31 +0900
commit5248e7a8a6e58a4cd1f451210a557bfe48da0695 (patch)
treec76343dbeb1cb0d28182c164e8c10a321e5d6afc
parentfacf087026c29069504037b8aa6c591e5f890c54 (diff)
downloadqemu-5248e7a8a6e58a4cd1f451210a557bfe48da0695.tar.gz
qemu-5248e7a8a6e58a4cd1f451210a557bfe48da0695.tar.bz2
qemu-5248e7a8a6e58a4cd1f451210a557bfe48da0695.zip
qemu-cvs-ioctl_nodirection
the direction given in the ioctl should be correct so we can assume the communication is uni-directional. The alsa developers did not like this concept though and declared ioctls IOC_R and IOC_W even though they were IOC_RW. Signed-off-by: Alexander Graf <agraf@suse.de> Signed-off-by: Ulrich Hecht <uli@suse.de>
-rw-r--r--linux-user/syscall.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/linux-user/syscall.c b/linux-user/syscall.c
index 1b3ed97a0..8e69c151f 100644
--- a/linux-user/syscall.c
+++ b/linux-user/syscall.c
@@ -5367,6 +5367,11 @@ static abi_long do_ioctl(int fd, int cmd, abi_long arg)
arg_type++;
target_size = thunk_type_size(arg_type, 0);
switch(ie->access) {
+ /* FIXME: actually the direction given in the ioctl should be
+ * correct so we can assume the communication is uni-directional.
+ * The alsa developers did not like this concept though and
+ * declared ioctls IOC_R and IOC_W even though they were IOC_RW.*/
+/*
case IOC_R:
ret = get_errno(safe_ioctl(fd, ie->host_cmd, buf_temp));
if (!is_error(ret)) {
@@ -5385,6 +5390,7 @@ static abi_long do_ioctl(int fd, int cmd, abi_long arg)
unlock_user(argptr, arg, 0);
ret = get_errno(safe_ioctl(fd, ie->host_cmd, buf_temp));
break;
+*/
default:
case IOC_RW:
argptr = lock_user(VERIFY_READ, arg, target_size, 1);