nand: raw: mxs_nand: Fix specific hook registration
authorMichael Trimarchi <michael@amarulasolutions.com>
Sun, 15 May 2022 09:35:30 +0000 (11:35 +0200)
committerStefano Babic <sbabic@denx.de>
Fri, 20 May 2022 10:36:47 +0000 (12:36 +0200)
commit78bf8e802c33883d1069f165d95866d9b5cd36fc
tree861e76abb34e302bb9e13224c26b74f3398fc4e3
parent1919f58a8f371c19c340127b6a76859867e90247
nand: raw: mxs_nand: Fix specific hook registration

Move the hook after nand_scan_tail is called. The hook must be replaced
to the mxs specific one but those must to be assignment later in the
probe function.

With this fix markbad is working again. Before this change:

nand markbad 0xDEC00
NXS NAND: Writing OOB isn't supported
NXS NAND: Writing OOB isn't supported
block 0x000dec00 NOT marked as bad! ERROR 0

Cc: Han Xu <han.xu@nxp.com>
Cc: Fabio Estevam <festevam@gmail.com>
Acked-by: Han Xu <han.xu@nxp.com>
Tested-By: Tim Harvey <tharvey@gateworks.com>
Signed-off-by: Michael Trimarchi <michael@amarulasolutions.com>
drivers/mtd/nand/raw/mxs_nand.c