diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2007-10-07 17:54:28 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2008-10-21 07:47:22 -0400 |
commit | bbc1cc978404105da23d505163ce9fd5598ed5b1 (patch) | |
tree | cd0e1dfba91288338784dac3f9356aeadb3e713e /drivers/ide/ide-cd.c | |
parent | 08f85851215100d0eebf026810955ee6ad456c38 (diff) |
[PATCH] switch cdrom_{open,release,ioctl} to sane APIs
... convert to it in callers
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'drivers/ide/ide-cd.c')
-rw-r--r-- | drivers/ide/ide-cd.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/ide/ide-cd.c b/drivers/ide/ide-cd.c index cd21b34fe509..87d90200b169 100644 --- a/drivers/ide/ide-cd.c +++ b/drivers/ide/ide-cd.c | |||
@@ -2099,7 +2099,7 @@ static int idecd_open(struct inode *inode, struct file *file) | |||
2099 | if (!info) | 2099 | if (!info) |
2100 | return -ENXIO; | 2100 | return -ENXIO; |
2101 | 2101 | ||
2102 | rc = cdrom_open(&info->devinfo, inode, file); | 2102 | rc = cdrom_open(&info->devinfo, inode->i_bdev, file->f_mode); |
2103 | 2103 | ||
2104 | if (rc < 0) | 2104 | if (rc < 0) |
2105 | ide_cd_put(info); | 2105 | ide_cd_put(info); |
@@ -2112,7 +2112,7 @@ static int idecd_release(struct inode *inode, struct file *file) | |||
2112 | struct gendisk *disk = inode->i_bdev->bd_disk; | 2112 | struct gendisk *disk = inode->i_bdev->bd_disk; |
2113 | struct cdrom_info *info = ide_drv_g(disk, cdrom_info); | 2113 | struct cdrom_info *info = ide_drv_g(disk, cdrom_info); |
2114 | 2114 | ||
2115 | cdrom_release(&info->devinfo, file); | 2115 | cdrom_release(&info->devinfo, file ? file->f_mode : 0); |
2116 | 2116 | ||
2117 | ide_cd_put(info); | 2117 | ide_cd_put(info); |
2118 | 2118 | ||
@@ -2176,7 +2176,8 @@ static int idecd_ioctl(struct inode *inode, struct file *file, | |||
2176 | 2176 | ||
2177 | err = generic_ide_ioctl(info->drive, bdev, cmd, arg); | 2177 | err = generic_ide_ioctl(info->drive, bdev, cmd, arg); |
2178 | if (err == -EINVAL) | 2178 | if (err == -EINVAL) |
2179 | err = cdrom_ioctl(file, &info->devinfo, inode, cmd, arg); | 2179 | err = cdrom_ioctl(&info->devinfo, bdev, |
2180 | file ? file->f_mode : 0, cmd, arg); | ||
2180 | 2181 | ||
2181 | return err; | 2182 | return err; |
2182 | } | 2183 | } |