]> git.baikalelectronics.ru Git - kernel.git/commit
scsi: scsi_ioctl: Simplify SCSI passthrough permission checking
authorChristoph Hellwig <hch@lst.de>
Sat, 24 Jul 2021 07:20:26 +0000 (09:20 +0200)
committerMartin K. Petersen <martin.petersen@oracle.com>
Thu, 29 Jul 2021 02:24:26 +0000 (22:24 -0400)
commit48f8a7896c6d936cb2f96fa40b7af5c79b802c2d
tree99a416ca5c9eec02a8a2286c10802047c48a53f5
parent81f84f81c77847ac7a8a8d48f217b97e92e78c26
scsi: scsi_ioctl: Simplify SCSI passthrough permission checking

Remove the separate command filter structure and just use a switch
statement (which also cought two duplicate commands), return a bool and
give the function a sensible name.

Link: https://lore.kernel.org/r/20210724072033.1284840-18-hch@lst.de
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
block/scsi_ioctl.c
drivers/scsi/scsi_bsg.c
drivers/scsi/sg.c
include/linux/blkdev.h