Skip to contentSkip to conversation

scsi: scsi_ioctl: fix error code propagation in SG_IO

PATCH Applied Halil Pasic 2 participants 3 messages Aug 23, 2021 – Aug 28, 2021

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 scsi: scsi_ioctl: fix error code propagation in SG_IO

Fixes f2542a3be327 ("scsi: scsi_ioctl: Move the "block layer" SCSI

ioctl handling to drivers/scsi")

---
This is a patch against the for-next branch of
git://git.kernel.org/pub/scm/linux/kernel/git/mkp/scsi.git and/or linux-next/master.

---
 drivers/scsi/scsi_ioctl.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/scsi/scsi_ioctl.c +1 -1
index 7b2b0a1581f4..6ff2207bd45a 100644
@@ -874,7 +874,7 @@ static int scsi_ioctl_sg_io(struct scsi_device *sdev, struct gendisk *disk,
 		return error;
 	if (put_sg_io_hdr(&hdr, argp))
 		return -EFAULT;
-	return 0;
+	return error;
 }
 
 /**
Signature · 1 line
2.25.1
#1 lore raw

Halil,

Quoted 2 lines
Fixes f2542a3be327 ("scsi: scsi_ioctl: Move the "block layer" SCSI

ioctl handling to drivers/scsi")

Applied to 5.15/scsi-staging, thanks!

Signature · 1 line
Martin K. Petersen	Oracle Linux Engineering