Skip to content
Commit 5fdfc3db authored by Joakim Tjernlund's avatar Joakim Tjernlund Committed by Boris Brezillon
Browse files

mtd: cfi_cmdset_0002: fix SEGV unlocking multiple chips



cfi_ppb_unlock() tries to relock all sectors that were locked before
unlocking the whole chip.
This locking used the chip start address + the FULL offset from the
first flash chip, thereby forming an illegal address. Fix that by using
the chip offset(adr).

Fixes: 1648eaaa ("mtd: cfi_cmdset_0002: Support Persistent Protection Bits (PPB) locking")
Cc: stable@vger.kernel.org
Signed-off-by: default avatarJoakim Tjernlund <joakim.tjernlund@infinera.com>
Signed-off-by: default avatarBoris Brezillon <boris.brezillon@bootlin.com>
parent f93aa8c4
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment