patch-2.2.14 linux/arch/sparc64/kernel/ioctl32.c
Next file: linux/arch/sparc64/kernel/irq.c
Previous file: linux/arch/sparc64/kernel/head.S
Back to the patch index
Back to the overall index
- Lines: 111
- Date:
Tue Jan 4 10:12:13 2000
- Orig file:
v2.2.13/linux/arch/sparc64/kernel/ioctl32.c
- Orig date:
Tue Jan 4 11:10:32 2000
diff -u --recursive --new-file v2.2.13/linux/arch/sparc64/kernel/ioctl32.c linux/arch/sparc64/kernel/ioctl32.c
@@ -1,4 +1,4 @@
-/* $Id: ioctl32.c,v 1.62.2.4 1999/09/22 17:06:56 jj Exp $
+/* $Id: ioctl32.c,v 1.62.2.8 1999/11/16 23:59:31 davem Exp $
* ioctl32.c: Conversion between 32bit and 64bit native ioctls.
*
* Copyright (C) 1997 Jakub Jelinek (jj@sunsite.mff.cuni.cz)
@@ -17,7 +17,6 @@
#include <linux/if.h>
#include <linux/malloc.h>
#include <linux/hdreg.h>
-#include <linux/raid/md.h>
#include <linux/kd.h>
#include <linux/route.h>
#include <linux/skbuff.h>
@@ -1699,9 +1698,9 @@
int error = -EBADF;
lock_kernel();
- filp = fcheck(fd);
+ filp = fget(fd);
if(!filp)
- goto out;
+ goto out2;
if (!filp->f_op || !filp->f_op->ioctl) {
error = sys_ioctl (fd, cmd, arg);
@@ -1920,6 +1919,9 @@
case TIOCSCTTY:
case TIOCGPTN:
case TIOCSPTLCK:
+ case TIOCGSERIAL:
+ case TIOCSSERIAL:
+ case TIOCSERGETLSR:
/* Big F */
case FBIOGTYPE:
@@ -1995,23 +1997,23 @@
case BLKRASET:
/* 0x09 */
- case RAID_VERSION:
- case GET_ARRAY_INFO:
- case GET_DISK_INFO:
- case CLEAR_ARRAY:
- case ADD_NEW_DISK:
- case HOT_REMOVE_DISK:
- case SET_ARRAY_INFO:
- case SET_DISK_INFO:
- case WRITE_RAID_INFO:
- case UNPROTECT_ARRAY:
- case PROTECT_ARRAY:
- case HOT_ADD_DISK:
- case RUN_ARRAY:
- case START_ARRAY:
- case STOP_ARRAY:
- case STOP_ARRAY_RO:
- case RESTART_ARRAY_RW:
+ case /* RAID_VERSION */ _IOR (MD_MAJOR, 0x10, char[12]):
+ case /* GET_ARRAY_INFO */ _IOR (MD_MAJOR, 0x11, char[72]):
+ case /* GET_DISK_INFO */ _IOR (MD_MAJOR, 0x12, char[20]):
+ case /* CLEAR_ARRAY */ _IO (MD_MAJOR, 0x20):
+ case /* ADD_NEW_DISK */ _IOW (MD_MAJOR, 0x21, char[20]):
+ case /* HOT_REMOVE_DISK */ _IO (MD_MAJOR, 0x22):
+ case /* SET_ARRAY_INFO */ _IOW (MD_MAJOR, 0x23, char[72]):
+ case /* SET_DISK_INFO */ _IO (MD_MAJOR, 0x24):
+ case /* WRITE_RAID_INFO */ _IO (MD_MAJOR, 0x25):
+ case /* UNPROTECT_ARRAY */ _IO (MD_MAJOR, 0x26):
+ case /* PROTECT_ARRAY */ _IO (MD_MAJOR, 0x27):
+ case /* HOT_ADD_DISK */ _IO (MD_MAJOR, 0x28):
+ case /* RUN_ARRAY */ _IOW (MD_MAJOR, 0x30, char[12]):
+ case /* START_ARRAY */ _IO (MD_MAJOR, 0x31):
+ case /* STOP_ARRAY */ _IO (MD_MAJOR, 0x32):
+ case /* STOP_ARRAY_RO */ _IO (MD_MAJOR, 0x33):
+ case /* RESTART_ARRAY_RW */ _IO (MD_MAJOR, 0x34):
/* Big K */
case PIO_FONT:
@@ -2219,6 +2221,9 @@
case CDROM_DRIVE_STATUS:
case CDROM_DISC_STATUS:
case CDROM_CHANGER_NSLOTS:
+ case CDROM_LOCKDOOR:
+ case CDROM_DEBUG:
+ case CDROM_GET_CAPABILITY:
/* Big L */
case LOOP_SET_FD:
@@ -2385,6 +2390,10 @@
case AUTOFS_IOC_PROTOVER:
case AUTOFS_IOC_EXPIRE:
+ /* Raw devices */
+ case _IO(0xac, 0): /* RAW_SETBIND */
+ case _IO(0xac, 1): /* RAW_GETBIND */
+
error = sys_ioctl (fd, cmd, arg);
goto out;
@@ -2397,9 +2406,11 @@
(int)fd, (unsigned int)cmd, (unsigned int)arg);
} while(0);
error = -EINVAL;
- break;
+ goto out;
}
out:
+ fput(filp);
+out2:
unlock_kernel();
return error;
}
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)