Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 1fa9ce8d authored by Tomasz Majchrzak's avatar Tomasz Majchrzak Committed by Jens Axboe
Browse files

badblocks: fix overlapping check for clearing



Current bad block clear implementation assumes the range to clear
overlaps with at least one bad block already stored. If given range to
clear precedes first bad block in a list, the first entry is incorrectly
updated.

Check not only if stored block end is past clear block end but also if
stored block start is before clear block end.

Signed-off-by: default avatarTomasz Majchrzak <tomasz.majchrzak@intel.com>
Acked-by: default avatarNeilBrown <neilb@suse.com>
Signed-off-by: default avatarJens Axboe <axboe@fb.com>
parent 24532f76
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment