Commit 93a7e28
s390/dasd: fix error recovery leading to data corruption on ESE devices
commit 7db4042 upstream.
Extent Space Efficient (ESE) or thin provisioned volumes need to be
formatted on demand during usual IO processing.
The dasd_ese_needs_format function checks for error codes that signal
the non existence of a proper track format.
The check for incorrect length is to imprecise since other error cases
leading to transport of insufficient data also have this flag set.
This might lead to data corruption in certain error cases for example
during a storage server warmstart.
Fix by removing the check for incorrect length and replacing by
explicitly checking for invalid track format in transport mode.
Also remove the check for file protected since this is not a valid
ESE handling case.
Cc: stable@vger.kernel.org # 5.3+
Fixes: 5e2b17e ("s390/dasd: Add dynamic formatting support for ESE volumes")
Reviewed-by: Jan Hoeppner <hoeppner@linux.ibm.com>
Signed-off-by: Stefan Haberland <sth@linux.ibm.com>
Link: https://lore.kernel.org/r/20240812125733.126431-3-sth@linux.ibm.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>1 parent 31ba132 commit 93a7e28
File tree
4 files changed
+50
-53
lines changed- drivers/s390/block
4 files changed
+50
-53
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1599 | 1599 | | |
1600 | 1600 | | |
1601 | 1601 | | |
1602 | | - | |
1603 | | - | |
1604 | | - | |
| 1602 | + | |
| 1603 | + | |
| 1604 | + | |
| 1605 | + | |
| 1606 | + | |
| 1607 | + | |
| 1608 | + | |
| 1609 | + | |
| 1610 | + | |
1605 | 1611 | | |
1606 | 1612 | | |
1607 | 1613 | | |
| |||
1622 | 1628 | | |
1623 | 1629 | | |
1624 | 1630 | | |
1625 | | - | |
| 1631 | + | |
1626 | 1632 | | |
1627 | 1633 | | |
1628 | 1634 | | |
| |||
1677 | 1683 | | |
1678 | 1684 | | |
1679 | 1685 | | |
1680 | | - | |
1681 | | - | |
| 1686 | + | |
| 1687 | + | |
| 1688 | + | |
1682 | 1689 | | |
1683 | 1690 | | |
1684 | 1691 | | |
| |||
1693 | 1700 | | |
1694 | 1701 | | |
1695 | 1702 | | |
1696 | | - | |
| 1703 | + | |
1697 | 1704 | | |
1698 | 1705 | | |
1699 | 1706 | | |
| |||
2465 | 2472 | | |
2466 | 2473 | | |
2467 | 2474 | | |
2468 | | - | |
2469 | | - | |
2470 | | - | |
2471 | | - | |
| 2475 | + | |
| 2476 | + | |
| 2477 | + | |
2472 | 2478 | | |
2473 | 2479 | | |
2474 | | - | |
2475 | | - | |
| 2480 | + | |
| 2481 | + | |
| 2482 | + | |
| 2483 | + | |
| 2484 | + | |
| 2485 | + | |
2476 | 2486 | | |
2477 | 2487 | | |
2478 | 2488 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1406 | 1406 | | |
1407 | 1407 | | |
1408 | 1408 | | |
1409 | | - | |
1410 | | - | |
1411 | | - | |
1412 | | - | |
1413 | | - | |
1414 | | - | |
1415 | | - | |
1416 | | - | |
| 1409 | + | |
| 1410 | + | |
1417 | 1411 | | |
1418 | 1412 | | |
1419 | 1413 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2289 | 2289 | | |
2290 | 2290 | | |
2291 | 2291 | | |
| 2292 | + | |
2292 | 2293 | | |
2293 | 2294 | | |
2294 | 2295 | | |
| |||
2570 | 2571 | | |
2571 | 2572 | | |
2572 | 2573 | | |
2573 | | - | |
2574 | 2574 | | |
2575 | 2575 | | |
2576 | 2576 | | |
| |||
4146 | 4146 | | |
4147 | 4147 | | |
4148 | 4148 | | |
4149 | | - | |
4150 | | - | |
4151 | 4149 | | |
4152 | 4150 | | |
4153 | 4151 | | |
| |||
4649 | 4647 | | |
4650 | 4648 | | |
4651 | 4649 | | |
4652 | | - | |
4653 | | - | |
4654 | 4650 | | |
| 4651 | + | |
4655 | 4652 | | |
4656 | 4653 | | |
4657 | 4654 | | |
| |||
5820 | 5817 | | |
5821 | 5818 | | |
5822 | 5819 | | |
5823 | | - | |
5824 | | - | |
5825 | | - | |
5826 | | - | |
5827 | | - | |
5828 | | - | |
5829 | | - | |
5830 | | - | |
5831 | | - | |
5832 | | - | |
5833 | | - | |
5834 | | - | |
| 5820 | + | |
| 5821 | + | |
| 5822 | + | |
| 5823 | + | |
| 5824 | + | |
| 5825 | + | |
| 5826 | + | |
| 5827 | + | |
| 5828 | + | |
5835 | 5829 | | |
5836 | | - | |
5837 | | - | |
5838 | | - | |
5839 | | - | |
5840 | | - | |
5841 | | - | |
5842 | | - | |
5843 | | - | |
5844 | | - | |
5845 | | - | |
| 5830 | + | |
| 5831 | + | |
| 5832 | + | |
5846 | 5833 | | |
5847 | | - | |
5848 | | - | |
5849 | | - | |
| 5834 | + | |
| 5835 | + | |
| 5836 | + | |
5850 | 5837 | | |
| 5838 | + | |
| 5839 | + | |
| 5840 | + | |
| 5841 | + | |
| 5842 | + | |
| 5843 | + | |
| 5844 | + | |
5851 | 5845 | | |
5852 | | - | |
5853 | 5846 | | |
5854 | 5847 | | |
5855 | 5848 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
225 | 225 | | |
226 | 226 | | |
227 | 227 | | |
228 | | - | |
| 228 | + | |
229 | 229 | | |
230 | 230 | | |
231 | 231 | | |
| |||
0 commit comments