diff options
author | Nate Dailey <nate.dailey@stratus.com> | 2019-02-07 14:19:01 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-02-20 10:25:48 +0100 |
commit | ddf966410acecb1cbdf06d0a79a41b6e664aeb44 (patch) | |
tree | 7893080c4e4aebd9c92e123d0c9f9d801d89aa26 /drivers/hwspinlock | |
parent | a2b3e2c0f576901a83b38bf8a48169a0e577290a (diff) | |
download | linux-stable-ddf966410acecb1cbdf06d0a79a41b6e664aeb44.tar.gz |
md/raid1: don't clear bitmap bits on interrupted recovery.
commit dfcc34c99f3ebc16b787b118763bf9cb6b1efc7a upstream.
sync_request_write no longer submits writes to a Faulty device. This has
the unfortunate side effect that bitmap bits can be incorrectly cleared
if a recovery is interrupted (previously, end_sync_write would have
prevented this). This means the next recovery may not copy everything
it should, potentially corrupting data.
Add a function for doing the proper md_bitmap_end_sync, called from
end_sync_write and the Faulty case in sync_request_write.
backport note to 4.14: s/md_bitmap_end_sync/bitmap_end_sync
Cc: stable@vger.kernel.org 4.14+
Fixes: 0c9d5b127f69 ("md/raid1: avoid reusing a resync bio after error handling.")
Reviewed-by: Jack Wang <jinpu.wang@cloud.ionos.com>
Tested-by: Jack Wang <jinpu.wang@cloud.ionos.com>
Signed-off-by: Nate Dailey <nate.dailey@stratus.com>
Signed-off-by: Song Liu <songliubraving@fb.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/hwspinlock')
0 files changed, 0 insertions, 0 deletions