[PATCH] introduce __blkdev_driver_ioctl()

Analog of blkdev_driver_ioctl() with sane arguments.  For
now uses fake struct file, by the end of the series it won't
and blkdev_driver_ioctl() will become a wrapper around it.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
This commit is contained in:
Al Viro
2007-08-29 20:34:12 -04:00
parent a0eb62a0a4
commit 633a08b812
5 changed files with 39 additions and 19 deletions
+2 -2
View File
@@ -2819,8 +2819,8 @@ static int pkt_ioctl(struct inode *inode, struct file *file, unsigned int cmd, u
case CDROM_LAST_WRITTEN:
case CDROM_SEND_PACKET:
case SCSI_IOCTL_SEND_COMMAND:
return blkdev_driver_ioctl(pd->bdev->bd_inode, pd->bdev->bd_disk,
file, cmd, arg);
return __blkdev_driver_ioctl(pd->bdev, file ? file->f_mode : 0,
cmd, arg);
default:
VPRINTK(DRIVER_NAME": Unknown ioctl for %s (%x)\n", pd->name, cmd);