linux/drivers/s390
Jaehoon Kim f84f57b777 s390/dasd: Return BLK_STS_INVAL for EINVAL from do_dasd_request
commit 8f4ed0ce48 upstream.

Currently, if CCW request creation fails with -EINVAL, the DASD driver
returns BLK_STS_IOERR to the block layer.

This can happen, for example, when a user-space application such as QEMU
passes a misaligned buffer, but the original cause of the error is
masked as a generic I/O error.

This patch changes the behavior so that -EINVAL is returned as
BLK_STS_INVAL, allowing user space to properly detect alignment issues
instead of interpreting them as I/O errors.

Reviewed-by: Stefan Haberland <sth@linux.ibm.com>
Cc: stable@vger.kernel.org #6.11+
Signed-off-by: Jaehoon Kim <jhkim@linux.ibm.com>
Signed-off-by: Stefan Haberland <sth@linux.ibm.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
History 2025-10-19 16:37:37 +02:00
..
block s390/dasd: Return BLK_STS_INVAL for EINVAL from do_dasd_request 2025-10-19 16:37:37 +02:00
char s390/sclp: Fix SCCB present check 2025-08-20 16:37:27 +02:00
cio s390/cio/ioasm: Fix __xsch() condition code handling 2025-10-19 16:37:36 +02:00
crypto s390/ap: Unmask SLCF bit in card and queue ap functions sysfs 2025-07-31 18:59:26 +02:00
net Networking changes for 6.17. 2025-07-30 08:58:55 -07:00
scsi Merge branch '6.16/scsi-queue' into 6.16/scsi-fixes 2025-06-09 15:34:06 -04:00
virtio s390/virtio_ccw: Don't allocate/assign airqs for non-existing queues 2025-04-09 12:12:41 +02:00
Makefile s390: remove pointless drivers-y in drivers/s390/Makefile 2019-09-16 13:21:51 +02:00