]> git.baikalelectronics.ru Git - kernel.git/commit
s390/dasd: Add dynamic formatting support for ESE volumes
authorJan Höppner <hoeppner@linux.ibm.com>
Fri, 27 Apr 2018 14:51:22 +0000 (16:51 +0200)
committerVasily Gorbik <gor@linux.ibm.com>
Thu, 11 Jul 2019 18:39:53 +0000 (20:39 +0200)
commit4fb6bf848fbcc61b9427e3261bacdd9227345513
tree62dbb4a3d1a83bead5ec3c1b57d21d16afa24b89
parent21a8438b205517f06757c6f49e9ff90fd7786444
s390/dasd: Add dynamic formatting support for ESE volumes

A dynamic formatting is issued whenever a write request returns with
either a No Record Found error (Command Mode), Incorrect Length error
(Transport Mode), or File Protected error (Transport Mode). All three
cases mean that the tracks in question haven't been initialized in a
desired format yet.

The part of the volume that was tried to be written on is then formatted
and the original request is re-queued.

As the formatting will happen during normal I/O operations, it is quite
likely that there won't be any memory available to build the respective
request. Another two pages of memory are allocated per volume
specifically for the dynamic formatting.

The dasd_eckd_build_format() function is extended to make sure that the
original startdev is reused. Also, all formatting and format check
functions use the new memory pool exclusively now to reduce complexity.

Read operations will always return zero data when unformatted areas are
read.

Signed-off-by: Jan Höppner <hoeppner@linux.ibm.com>
Reviewed-by: Stefan Haberland <sth@linux.ibm.com>
Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
drivers/s390/block/dasd.c
drivers/s390/block/dasd_eckd.c
drivers/s390/block/dasd_int.h