diff options
author | Christoph Hellwig <hch@lst.de> | 2021-07-31 10:40:26 +0300 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2021-08-01 20:21:40 +0300 |
commit | 5c0f61377b765e650b1bc85298b79add1148c97f (patch) | |
tree | 9d8bef0d10805f7b7af415569a9266825260085b /block/bsg-lib.c | |
parent | 1084514ca9aa5b3fcc485b378b92b632918237f4 (diff) | |
download | linux-5c0f61377b765e650b1bc85298b79add1148c97f.tar.xz |
scsi: bsg: Fix commands without data transfer in scsi_bsg_sg_io_fn()
Set ret to 0 after the initial permission checks to avoid leaking -EPERM
for commands without data transfer.
Link: https://lore.kernel.org/r/20210731074027.1185545-2-hch@lst.de
Fixes: 75ca56409e5b ("scsi: bsg: Move the whole request execution into the SCSI/transport handlers")
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'block/bsg-lib.c')
0 files changed, 0 insertions, 0 deletions