summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2021-07-24 09:20:26 +0200
committerMartin K. Petersen <martin.petersen@oracle.com>2021-07-29 04:24:26 +0200
commit7353dc06c9a8e37c80da7ff986e6ef5123bec8ce (patch)
tree99a416ca5c9eec02a8a2286c10802047c48a53f5 /include
parentscsi: scsi_ioctl: Move scsi_command_size_tbl to scsi_common.c (diff)
downloadlinux-7353dc06c9a8e37c80da7ff986e6ef5123bec8ce.tar.xz
linux-7353dc06c9a8e37c80da7ff986e6ef5123bec8ce.zip
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>
Diffstat (limited to 'include')
-rw-r--r--include/linux/blkdev.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
index d36b67bd7267..e28679e63373 100644
--- a/include/linux/blkdev.h
+++ b/include/linux/blkdev.h
@@ -1343,7 +1343,7 @@ static inline int sb_issue_zeroout(struct super_block *sb, sector_t block,
gfp_mask, 0);
}
-extern int blk_verify_command(unsigned char *cmd, fmode_t mode);
+bool scsi_cmd_allowed(unsigned char *cmd, fmode_t mode);
static inline bool bdev_is_partition(struct block_device *bdev)
{