summaryrefslogtreecommitdiff
path: root/drivers/block
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2007-08-27 19:38:10 (GMT)
committerAl Viro <viro@zeniv.linux.org.uk>2008-10-21 11:47:14 (GMT)
commit74f3c8aff36ad6552ea609c8b20bfd588fa16f38 (patch)
treec046823751971ff37b66499282ca2b2e263cc71a /drivers/block
parente915e872ed921d707bc32b3f2184d43abfa8c9e2 (diff)
downloadlinux-74f3c8aff36ad6552ea609c8b20bfd588fa16f38.tar.xz
[PATCH] switch scsi_cmd_ioctl() to passing fmode_t
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'drivers/block')
-rw-r--r--drivers/block/cciss.c3
-rw-r--r--drivers/block/ub.c2
-rw-r--r--drivers/block/virtio_blk.c4
3 files changed, 5 insertions, 4 deletions
diff --git a/drivers/block/cciss.c b/drivers/block/cciss.c
index 1e1f915..d9b1c15 100644
--- a/drivers/block/cciss.c
+++ b/drivers/block/cciss.c
@@ -1232,7 +1232,8 @@ static int cciss_ioctl(struct inode *inode, struct file *filep,
case SG_EMULATED_HOST:
case SG_IO:
case SCSI_IOCTL_SEND_COMMAND:
- return scsi_cmd_ioctl(filep, disk->queue, disk, cmd, argp);
+ return scsi_cmd_ioctl(disk->queue, disk,
+ filep ? filep->f_mode : 0, cmd, argp);
/* scsi_cmd_ioctl would normally handle these, below, but */
/* they aren't a good fit for cciss, as CD-ROMs are */
diff --git a/drivers/block/ub.c b/drivers/block/ub.c
index 85d41eb..bc04330 100644
--- a/drivers/block/ub.c
+++ b/drivers/block/ub.c
@@ -1729,7 +1729,7 @@ static int ub_bd_ioctl(struct inode *inode, struct file *filp,
struct gendisk *disk = inode->i_bdev->bd_disk;
void __user *usermem = (void __user *) arg;
- return scsi_cmd_ioctl(filp, disk->queue, disk, cmd, usermem);
+ return scsi_cmd_ioctl(disk->queue, disk, filp ? filp->f_mode : 0, cmd, usermem);
}
/*
diff --git a/drivers/block/virtio_blk.c b/drivers/block/virtio_blk.c
index 6ec5fc0..7643cd1 100644
--- a/drivers/block/virtio_blk.c
+++ b/drivers/block/virtio_blk.c
@@ -149,8 +149,8 @@ static void do_virtblk_request(struct request_queue *q)
static int virtblk_ioctl(struct inode *inode, struct file *filp,
unsigned cmd, unsigned long data)
{
- return scsi_cmd_ioctl(filp, inode->i_bdev->bd_disk->queue,
- inode->i_bdev->bd_disk, cmd,
+ return scsi_cmd_ioctl(inode->i_bdev->bd_disk->queue,
+ inode->i_bdev->bd_disk, filp->f_mode, cmd,
(void __user *)data);
}