linux/drivers/s390/block
Stefan Haberland 67d638f8ef s390/dasd: fix no record found for raw_track_access
[ Upstream commit 590ce6d96d ]

For DASD devices in raw_track_access mode only full track images are
read and written.
For this purpose it is not necessary to do search operation in the
locate record extended function. The documentation even states that
this might fail if the searched record is not found on a track.

Currently the driver sets a value of 1 in the search field for the first
record after record zero. This is the default for disks not in
raw_track_access mode but record 1 might be missing on a completely
empty track.

There has not been any problem with this on IBM storage servers but it
might lead to errors with DASD devices on other vendors storage servers.

Fix this by setting the search field to 0. Record zero is always available
even on a completely empty track.

Fixes: e4dbb0f2b5 ("[S390] dasd: Add support for raw ECKD access.")
Signed-off-by: Stefan Haberland <sth@linux.ibm.com>
Reviewed-by: Jan Hoeppner <hoeppner@linux.ibm.com>
Link: https://lore.kernel.org/r/20221123160719.3002694-4-sth@linux.ibm.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
History 2022-12-02 17:41:07 +01:00
..
dasd.c s390/dasd: Fix read inconsistency for ESE DASD devices 2022-05-12 12:30:08 +02:00
dasd_3990_erp.c s390/dasd: Fix comment spelling 2020-03-17 20:50:19 +01:00
dasd_alias.c s390/dasd: fix Oops in dasd_alias_get_start_dev due to missing pavgroup 2022-09-28 11:11:54 +02:00
dasd_devmap.c s390/dasd: let driver core manage the sysfs attributes 2021-03-16 08:31:00 -06:00
dasd_diag.c dasd: use bvec_virt 2021-08-16 10:50:33 -06:00
dasd_diag.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
dasd_eckd.c s390/dasd: fix no record found for raw_track_access 2022-12-02 17:41:07 +01:00
dasd_eckd.h s390/dasd: Avoid field over-reading memcpy() 2021-07-01 09:27:04 -06:00
dasd_eer.c s390/dasd: Handle out-of-space constraint 2019-07-11 20:39:54 +02:00
dasd_erp.c License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
dasd_fba.c dasd: use bvec_virt 2021-08-16 10:50:33 -06:00
dasd_fba.h s390/dasd: fix typo in copyright statement 2019-12-20 11:52:01 -07:00
dasd_genhd.c block: drop unused includes in <linux/genhd.h> 2022-03-16 14:23:46 +01:00
dasd_int.h s390/dasd: prevent double format of tracks for ESE devices 2022-05-12 12:30:08 +02:00
dasd_ioctl.c s390/dasd: remove debug printk 2021-07-27 09:39:14 +02:00
dasd_proc.c proc: convert everything to "struct proc_ops" 2020-02-04 03:05:26 +00:00
dcssblk.c dcssblk: use bvec_virt 2021-08-16 10:50:33 -06:00
Kconfig s390: remove xpram device driver 2021-09-07 13:38:42 +02:00
Makefile s390: remove xpram device driver 2021-09-07 13:38:42 +02:00
scm_blk.c scm_blk: use blk_mq_alloc_disk and blk_cleanup_disk 2021-06-11 11:54:43 -06:00
scm_blk.h Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux 2017-11-13 11:47:01 -08:00
scm_drv.c s390/scm: Make struct scm_driver::remove return void 2021-07-21 11:53:42 +02:00