[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20210919191025.GB12836@amd>
Date: Sun, 19 Sep 2021 21:10:25 +0200
From: Pavel Machek <pavel@...x.de>
To: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc: linux-kernel@...r.kernel.org, stable@...r.kernel.org,
Bart Van Assche <bvanassche@....org>,
Jens Axboe <axboe@...nel.dk>, Christoph Hellwig <hch@....de>,
"Martin K. Petersen" <martin.petersen@...cle.com>,
Sasha Levin <sashal@...nel.org>
Subject: Re: [PATCH 5.10 058/306] scsi: bsg: Remove support for
SCSI_IOCTL_SEND_COMMAND
Hi!
> From: Christoph Hellwig <hch@....de>
>
> [ Upstream commit beec64d0c9749afedf51c3c10cf52de1d9a89cc0 ]
>
> SCSI_IOCTL_SEND_COMMAND has been deprecated longer than bsg exists and has
> been warning for just as long. More importantly it harcodes SCSI CDBs and
> thus will do the wrong thing on non-SCSI bsg nodes.
I see removing deprecated stuff is good idea in mainline, but do we
want to do that in -stable?
Best regads,
Pavel
> +++ b/block/bsg.c
> @@ -371,10 +371,13 @@ static long bsg_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
> case SG_GET_RESERVED_SIZE:
> case SG_SET_RESERVED_SIZE:
> case SG_EMULATED_HOST:
> - case SCSI_IOCTL_SEND_COMMAND:
> return scsi_cmd_ioctl(bd->queue, NULL, file->f_mode, cmd, uarg);
> case SG_IO:
> return bsg_sg_io(bd->queue, file->f_mode, uarg);
> + case SCSI_IOCTL_SEND_COMMAND:
> + pr_warn_ratelimited("%s: calling unsupported SCSI_IOCTL_SEND_COMMAND\n",
> + current->comm);
> + return -EINVAL;
> default:
> return -ENOTTY;
> }
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Download attachment "signature.asc" of type "application/pgp-signature" (182 bytes)
Powered by blists - more mailing lists