-
由 Mikulas Patocka 提交于
Revert the commit 7a5b96b4 ("dm integrity: use discard support when recalculating"). There's a bug that when we write some data beyond the current recalculate boundary, the checksum will be rewritten with the discard filler later. And the data will no longer have integrity protection. There's no easy fix for this case. Also, another problematic case is if dm-integrity is used to detect bitrot (random device errors, bit flips, etc); dm-integrity should detect that even for unused sectors. With commit 7a5b96b4 it can happen that such change is undetected (because discard filler is not a valid checksum). Signed-off-by: NMikulas Patocka <mpatocka@redhat.com> Acked-by: NMilan Broz <gmazyland@gmail.com> Signed-off-by: NMike Snitzer <snitzer@redhat.com>
dbae70d4