diff options
Diffstat (limited to 'fs/compat_ioctl.c')
-rw-r--r-- | fs/compat_ioctl.c | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c index a4284ccac1f9..ffdc022cae64 100644 --- a/fs/compat_ioctl.c +++ b/fs/compat_ioctl.c | |||
@@ -10,6 +10,8 @@ | |||
10 | * ioctls. | 10 | * ioctls. |
11 | */ | 11 | */ |
12 | 12 | ||
13 | #include <linux/joystick.h> | ||
14 | |||
13 | #include <linux/types.h> | 15 | #include <linux/types.h> |
14 | #include <linux/compat.h> | 16 | #include <linux/compat.h> |
15 | #include <linux/kernel.h> | 17 | #include <linux/kernel.h> |
@@ -322,7 +324,7 @@ static int dev_ifname32(unsigned int fd, unsigned int cmd, unsigned long arg) | |||
322 | int err; | 324 | int err; |
323 | 325 | ||
324 | uifr = compat_alloc_user_space(sizeof(struct ifreq)); | 326 | uifr = compat_alloc_user_space(sizeof(struct ifreq)); |
325 | if (copy_in_user(uifr, compat_ptr(arg), sizeof(struct ifreq32))); | 327 | if (copy_in_user(uifr, compat_ptr(arg), sizeof(struct ifreq32))) |
326 | return -EFAULT; | 328 | return -EFAULT; |
327 | 329 | ||
328 | err = sys_ioctl(fd, SIOCGIFNAME, (unsigned long)uifr); | 330 | err = sys_ioctl(fd, SIOCGIFNAME, (unsigned long)uifr); |
@@ -1374,7 +1376,7 @@ static int do_atm_ioctl(unsigned int fd, unsigned int cmd32, unsigned long arg) | |||
1374 | return -EINVAL; | 1376 | return -EINVAL; |
1375 | } | 1377 | } |
1376 | 1378 | ||
1377 | static __attribute_used__ int | 1379 | static __used int |
1378 | ret_einval(unsigned int fd, unsigned int cmd, unsigned long arg) | 1380 | ret_einval(unsigned int fd, unsigned int cmd, unsigned long arg) |
1379 | { | 1381 | { |
1380 | return -EINVAL; | 1382 | return -EINVAL; |
@@ -1954,6 +1956,12 @@ ULONG_IOCTL(TIOCSCTTY) | |||
1954 | COMPATIBLE_IOCTL(TIOCGPTN) | 1956 | COMPATIBLE_IOCTL(TIOCGPTN) |
1955 | COMPATIBLE_IOCTL(TIOCSPTLCK) | 1957 | COMPATIBLE_IOCTL(TIOCSPTLCK) |
1956 | COMPATIBLE_IOCTL(TIOCSERGETLSR) | 1958 | COMPATIBLE_IOCTL(TIOCSERGETLSR) |
1959 | #ifdef TCGETS2 | ||
1960 | COMPATIBLE_IOCTL(TCGETS2) | ||
1961 | COMPATIBLE_IOCTL(TCSETS2) | ||
1962 | COMPATIBLE_IOCTL(TCSETSW2) | ||
1963 | COMPATIBLE_IOCTL(TCSETSF2) | ||
1964 | #endif | ||
1957 | /* Little f */ | 1965 | /* Little f */ |
1958 | COMPATIBLE_IOCTL(FIOCLEX) | 1966 | COMPATIBLE_IOCTL(FIOCLEX) |
1959 | COMPATIBLE_IOCTL(FIONCLEX) | 1967 | COMPATIBLE_IOCTL(FIONCLEX) |
@@ -2636,6 +2644,12 @@ COMPATIBLE_IOCTL(VIDEO_SET_ATTRIBUTES) | |||
2636 | COMPATIBLE_IOCTL(VIDEO_GET_SIZE) | 2644 | COMPATIBLE_IOCTL(VIDEO_GET_SIZE) |
2637 | COMPATIBLE_IOCTL(VIDEO_GET_FRAME_RATE) | 2645 | COMPATIBLE_IOCTL(VIDEO_GET_FRAME_RATE) |
2638 | 2646 | ||
2647 | /* joystick */ | ||
2648 | COMPATIBLE_IOCTL(JSIOCGVERSION) | ||
2649 | COMPATIBLE_IOCTL(JSIOCGAXES) | ||
2650 | COMPATIBLE_IOCTL(JSIOCGBUTTONS) | ||
2651 | COMPATIBLE_IOCTL(JSIOCGNAME(0)) | ||
2652 | |||
2639 | /* now things that need handlers */ | 2653 | /* now things that need handlers */ |
2640 | HANDLE_IOCTL(MEMREADOOB32, mtd_rw_oob) | 2654 | HANDLE_IOCTL(MEMREADOOB32, mtd_rw_oob) |
2641 | HANDLE_IOCTL(MEMWRITEOOB32, mtd_rw_oob) | 2655 | HANDLE_IOCTL(MEMWRITEOOB32, mtd_rw_oob) |