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

Commit 8e375ccd authored by Boris Brezillon's avatar Boris Brezillon Committed by Brian Norris
Browse files

mtd: nand: sunxi: fix sunxi_nand_chips_cleanup()



The sunxi_nand_chips_cleanup() function is missing a call to list_del()
which generates a double free error.

Reported-by: default avatarPriit Laes <plaes@plaes.org>
Signed-off-by: default avatarBoris Brezillon <boris.brezillon@free-electrons.com>
Cc: <stable@vger.kernel.org> # 3.19+
Fixes: 1fef62c1 ("mtd: nand: add sunxi NAND flash controller support")
Tested-by: default avatarPriit Laes <plaes@plaes.org>
Signed-off-by: default avatarBrian Norris <computersforpeace@gmail.com>
parent 03a0e8a7
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -1381,6 +1381,7 @@ static void sunxi_nand_chips_cleanup(struct sunxi_nfc *nfc)
					node);
		nand_release(&chip->mtd);
		sunxi_nand_ecc_cleanup(&chip->nand.ecc);
		list_del(&chip->node);
	}
}