[PATCH v15 4/8] mtd: spi-nor: Do not change nor->addr_nbytes at SFDP parsing time

Michael Walle michael at walle.cc
Thu May 12 14:45:10 PDT 2022


Am 2022-05-10 00:10, schrieb tkuw584924 at gmail.com:
> From: Tudor Ambarus <tudor.ambarus at microchip.com>
> 
> At the SFDP parsing time we should not change members of struct 
> spi_nor,
> but instead fill members of struct spi_nor_flash_parameters which could
> leter on be used by callers. The caller will then decide if SFDP params
> should be used and more importantly when they should be used. Clean the
> code flow and don't initialize nor->addr_nbytes at SFDP parsing time.
> 
> Signed-off-by: Tudor Ambarus <tudor.ambarus at microchip.com>
> Tested-By: Takahiro Kuwano <Takahiro.Kuwano at infineon.com>

Nice!

Reviewed-by: Michael Walle <michael at walle.cc>



More information about the linux-mtd mailing list