mtd: rawnand: marvell: Use correct logic for nand-keep-config
authorTony O'Brien <tony.obrien@alliedtelesis.co.nz>
Tue, 27 Sep 2022 02:47:28 +0000 (15:47 +1300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 3 Nov 2022 14:59:11 +0000 (23:59 +0900)
commit022f21e850e925a19e072fe8747209db88d69e7a
tree3ea6e708037d2730c505d2075ebbe7933380a52a
parentf90897c0f634f975c8f5536e5688863cc292abe9
mtd: rawnand: marvell: Use correct logic for nand-keep-config

commit ce107713b722af57c4b7f2477594d445b496420e upstream.

Originally the absence of the marvell,nand-keep-config property caused
the setup_data_interface function to be provided. However when
setup_data_interface was moved into nand_controller_ops the logic was
unintentionally inverted. Update the logic so that only if the
marvell,nand-keep-config property is present the bootloader NAND config
kept.

Cc: stable@vger.kernel.org
Fixes: 7a08dbaedd36 ("mtd: rawnand: Move ->setup_data_interface() to nand_controller_ops")
Signed-off-by: Tony O'Brien <tony.obrien@alliedtelesis.co.nz>
Signed-off-by: Chris Packham <chris.packham@alliedtelesis.co.nz>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/linux-mtd/20220927024728.28447-1-chris.packham@alliedtelesis.co.nz
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/mtd/nand/raw/marvell_nand.c