On Monday, March 9, 2020 10:40:33 AM EEST Sascha Hauer wrote: > EXTERNAL EMAIL: Do not click links or open attachments unless you know the > content is safe > > The Cypress cy15b104q and cy15v104q are 4Mbit serial SPI F-RAM devices. > Add support for them to the spi-nor driver. > > Signed-off-by: Sascha Hauer <s.hauer@xxxxxxxxxxxxxx> > --- > > Changes since v1: > - Instead of specifying 1024 sectors with a sector size of 512 specify > 512 * 1024 sectos with a sector size of 1. The device has no idea of > sectors and is not erasable, so a sector size of 1 seems to better > reflect reality. > > drivers/mtd/spi-nor/spi-nor.c | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/drivers/mtd/spi-nor/spi-nor.c b/drivers/mtd/spi-nor/spi-nor.c > index 4fc632ec18fe..a5c1d684364c 100644 > --- a/drivers/mtd/spi-nor/spi-nor.c > +++ b/drivers/mtd/spi-nor/spi-nor.c > @@ -2335,6 +2335,9 @@ static const struct flash_info spi_nor_ids[] = { > > { "at45db081d", INFO(0x1f2500, 0, 64 * 1024, 16, SECT_4K) }, > > + /* Cypress */ > + { "cy15x104q", INFO6(0x042cc2, 0x7f7f7f, 512 * 1024, 1, > SPI_NOR_NO_ERASE) }, + Shouldn't the id start with 0x03 instead of 0x04? Check [1]. Otherwise looks good. Also, would you please specify in the commit message on which platform did you test the flash, or with which controller? We usually don't add new flash_info entries solely by datasheet info, we've seen some nasty bugs and we try to avoid adding flashes that are broken since day one. Cheers, ta [1] https://www.google.com/url? sa=t&rct=j&q=&esrc=s&source=web&cd=1&cad=rja&uact=8&ved=2ahUKEwikvb6A2- roAhUKjqQKHQRzAhEQFjAAegQIAhAB&url=https%3A%2F%2Fmedia.digikey.com%2Fpdf%2FData%2520Sheets%2FCypress%2520PDFs%2FCY15B104Q_CY15V104Q_RevB_2-3-20.pdf&usg=AOvVaw0BmuUvI2j3NR07ZN_Jd4bN ______________________________________________________ Linux MTD discussion mailing list http://lists.infradead.org/mailman/listinfo/linux-mtd/