nand-bb: mtd_del_bb: fix missing pointer reset
If an attached bb device was removed before the actual mtd device
the code would try due to a missing pointer reset to access
the no more present bb device handle which leads to a page fault.

This bug was made visible by commit "7649473 mtd: nand: remove
automatically created bb devices" which relys on a correct
mtd->cdev_bb handling.

Signed-off-by: Heinrich Toews <heinrich.toews@wago.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
1 parent e10efc5 commit 51c0c6454944d53b63de7b1f42484ed5dc64d703
@Heinrich Toews Heinrich Toews authored on 18 Jun 2018
Sascha Hauer committed on 20 Jun 2018
Showing 1 changed file
View
drivers/mtd/nand/nand-bb.c