Message ID | d73012e2a3185d96b8a9fcd9523af54867d50e89.1671684805.git.Takahiro.Kuwano@infineon.com |
---|---|
State | Changes Requested |
Delegated to: | Ambarus Tudor |
Headers | show |
Series | mtd: spi-nor: sfdp: Introduce SFDP_DWORD() macro | expand |
On 23.12.2022 09:21, tkuw584924@gmail.com wrote: > From: Takahiro Kuwano <Takahiro.Kuwano@infineon.com> > > Array index for SCCR 22th DOWRD should be 21. > don't forget to cc stable: https://www.kernel.org/doc/html/latest/process/stable-kernel-rules.html > Fixes: 981a8d60e01f ("mtd: spi-nor: Parse SFDP SCCR Map") > Signed-off-by: Takahiro Kuwano <Takahiro.Kuwano@infineon.com> > Reviewed-by: Michael Walle <michael@walle.cc> > --- > drivers/mtd/spi-nor/sfdp.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/mtd/spi-nor/sfdp.c b/drivers/mtd/spi-nor/sfdp.c > index 8434f654eca1..5df2fcba5483 100644 > --- a/drivers/mtd/spi-nor/sfdp.c > +++ b/drivers/mtd/spi-nor/sfdp.c > @@ -1228,7 +1228,7 @@ static int spi_nor_parse_sccr(struct spi_nor *nor, > > le32_to_cpu_array(dwords, sccr_header->length); > > - if (FIELD_GET(SCCR_DWORD22_OCTAL_DTR_EN_VOLATILE, dwords[22])) > + if (FIELD_GET(SCCR_DWORD22_OCTAL_DTR_EN_VOLATILE, dwords[21])) > nor->flags |= SNOR_F_IO_MODE_EN_VOLATILE; > > out:
diff --git a/drivers/mtd/spi-nor/sfdp.c b/drivers/mtd/spi-nor/sfdp.c index 8434f654eca1..5df2fcba5483 100644 --- a/drivers/mtd/spi-nor/sfdp.c +++ b/drivers/mtd/spi-nor/sfdp.c @@ -1228,7 +1228,7 @@ static int spi_nor_parse_sccr(struct spi_nor *nor, le32_to_cpu_array(dwords, sccr_header->length); - if (FIELD_GET(SCCR_DWORD22_OCTAL_DTR_EN_VOLATILE, dwords[22])) + if (FIELD_GET(SCCR_DWORD22_OCTAL_DTR_EN_VOLATILE, dwords[21])) nor->flags |= SNOR_F_IO_MODE_EN_VOLATILE; out: