[PATCH 03/31] cdrom: remove the unused mode argument to cdrom_ioctl
Phillip Potter
phil at philpotter.co.uk
Tue Jun 6 15:54:11 PDT 2023
On Tue, Jun 06, 2023 at 09:39:22AM +0200, Christoph Hellwig wrote:
> Signed-off-by: Christoph Hellwig <hch at lst.de>
> ---
> drivers/cdrom/cdrom.c | 2 +-
> drivers/cdrom/gdrom.c | 2 +-
> drivers/scsi/sr.c | 2 +-
> include/linux/cdrom.h | 4 ++--
> 4 files changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/cdrom/cdrom.c b/drivers/cdrom/cdrom.c
> index e3eab319cb0474..245e5bbb05d41c 100644
> --- a/drivers/cdrom/cdrom.c
> +++ b/drivers/cdrom/cdrom.c
> @@ -3336,7 +3336,7 @@ static int mmc_ioctl(struct cdrom_device_info *cdi, unsigned int cmd,
> * ATAPI / SCSI specific code now mainly resides in mmc_ioctl().
> */
> int cdrom_ioctl(struct cdrom_device_info *cdi, struct block_device *bdev,
> - fmode_t mode, unsigned int cmd, unsigned long arg)
> + unsigned int cmd, unsigned long arg)
> {
> void __user *argp = (void __user *)arg;
> int ret;
> diff --git a/drivers/cdrom/gdrom.c b/drivers/cdrom/gdrom.c
> index eaa2d5a90bc82f..14922403983e9e 100644
> --- a/drivers/cdrom/gdrom.c
> +++ b/drivers/cdrom/gdrom.c
> @@ -505,7 +505,7 @@ static int gdrom_bdops_ioctl(struct block_device *bdev, fmode_t mode,
> int ret;
>
> mutex_lock(&gdrom_mutex);
> - ret = cdrom_ioctl(gd.cd_info, bdev, mode, cmd, arg);
> + ret = cdrom_ioctl(gd.cd_info, bdev, cmd, arg);
> mutex_unlock(&gdrom_mutex);
>
> return ret;
> diff --git a/drivers/scsi/sr.c b/drivers/scsi/sr.c
> index 61b83880e395a4..444c7efc14cba7 100644
> --- a/drivers/scsi/sr.c
> +++ b/drivers/scsi/sr.c
> @@ -539,7 +539,7 @@ static int sr_block_ioctl(struct block_device *bdev, fmode_t mode, unsigned cmd,
> scsi_autopm_get_device(sdev);
>
> if (cmd != CDROMCLOSETRAY && cmd != CDROMEJECT) {
> - ret = cdrom_ioctl(&cd->cdi, bdev, mode, cmd, arg);
> + ret = cdrom_ioctl(&cd->cdi, bdev, cmd, arg);
> if (ret != -ENOSYS)
> goto put;
> }
> diff --git a/include/linux/cdrom.h b/include/linux/cdrom.h
> index cc5717cb0fa8a8..4aea8c82d16971 100644
> --- a/include/linux/cdrom.h
> +++ b/include/linux/cdrom.h
> @@ -103,8 +103,8 @@ int cdrom_read_tocentry(struct cdrom_device_info *cdi,
> /* the general block_device operations structure: */
> int cdrom_open(struct cdrom_device_info *cdi, fmode_t mode);
> extern void cdrom_release(struct cdrom_device_info *cdi, fmode_t mode);
> -extern int cdrom_ioctl(struct cdrom_device_info *cdi, struct block_device *bdev,
> - fmode_t mode, unsigned int cmd, unsigned long arg);
> +int cdrom_ioctl(struct cdrom_device_info *cdi, struct block_device *bdev,
> + unsigned int cmd, unsigned long arg);
> extern unsigned int cdrom_check_events(struct cdrom_device_info *cdi,
> unsigned int clearing);
>
> --
> 2.39.2
>
Thanks, looks good.
Signed-off-by: Phillip Potter <phil at philpotter.co.uk>
Regards,
Phil
More information about the linux-mtd
mailing list