[PATCH V2] mtd: rawnand: denali_dt: Add support for configuring SPARE_AREA_SKIP_BYTES

Miquel Raynal miquel.raynal at bootlin.com
Thu Jan 9 08:13:37 PST 2020


Hi Masahiro,

Masahiro Yamada <masahiroy at kernel.org> wrote on Fri, 10 Jan 2020
01:06:20 +0900:

> On Fri, Dec 20, 2019 at 6:39 PM Marek Vasut <marex at denx.de> wrote:
> >
> > The SPARE_AREA_SKIP_BYTES register is reset when the controller reset
> > signal is toggled. Yet, this register must be configured to match the
> > content of the NAND OOB area. The current default value is always set
> > to 8 and is programmed into the hardware in case the hardware was not
> > programmed before (e.g. in a bootloader) with a different value. This
> > however does not work when the block is reset properly by Linux.
> >
> > On Altera SoCFPGA CycloneV, ArriaV and Arria10, which are the SoCFPGA
> > platforms which support booting from NAND, the SPARE_AREA_SKIP_BYTES
> > value must be set to 2. On Socionext Uniphier, the value is 8. This
> > patch adds support for preconfiguring the default value and handles
> > the special SoCFPGA case by setting the default to 2 on all SoCFPGA
> > platforms, while retaining the original behavior and default value of
> > 8 on all the other platforms.
> >
> > Signed-off-by: Marek Vasut <marex at denx.de>
> > Cc: Masahiro Yamada <yamada.masahiro at socionext.com>
> > Cc: Miquel Raynal <miquel.raynal at bootlin.com>
> > Cc: Richard Weinberger <richard at nod.at>
> > Cc: Vignesh Raghavendra <vigneshr at ti.com>
> > To: linux-mtd at lists.infradead.org
> > Reviewed-by: Tudor Ambarus <tudor.ambarus at microchip.com>
> > ---
> > V2: Move denali->oob_skip_bytes = data->oob_skip_bytes; right after
> >     of_device_get_match_data()  
> 
> 
> FYI.
> 
> This patch was rebased to avoid a conflict:
> http://patchwork.ozlabs.org/patch/1214018/
> 
> My Ack is in v3.

It is indeed about to be applied :)

Cheers,
Miquèl



More information about the linux-mtd mailing list