All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH linux dev-5.8] mtd: spi-nor: sfdp: Revert "default to addr_width of 3 for configurable widths"
@ 2020-08-12  3:58 Joel Stanley
  2020-08-12  7:15 ` Cédric Le Goater
  2020-08-12 17:44 ` Adriana Kobylak
  0 siblings, 2 replies; 4+ messages in thread
From: Joel Stanley @ 2020-08-12  3:58 UTC (permalink / raw)
  To: openbmc, Cédric Le Goater

This reverts commit f9acd7fa80be6ee14aecdc54429f2a48e56224e8 which
breaks mounting of UBI volumes with the aspeed-smc driver:

 ubi0: default fastmap pool size: 25
 ubi0: default fastmap WL pool size: 12
 ubi0: attaching mtd3
 ubi0: scanning is finished
 ubi0 error: ubi_read_volume_table: the layout volume was not found
 ubi0 error: ubi_attach_mtd_dev: failed to attach mtd3, error -22

Found by bisecting between v5.7 and v5.8.

Fixes: f9acd7fa80be ("mtd: spi-nor: sfdp: default to addr_width of 3 for configurable widths")
Signed-off-by: Joel Stanley <joel@jms.id.au>
---
This identifies why we are seeing SPI NOR failures on v5.8. There is
potentially a fix that needs to be made in the aspeed-smc driver instead
of reverting the core spi-nor change.

Signed-off-by: Joel Stanley <joel@jms.id.au>
---
 drivers/mtd/spi-nor/sfdp.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/mtd/spi-nor/sfdp.c b/drivers/mtd/spi-nor/sfdp.c
index 55c0c508464b..9db07182e9c8 100644
--- a/drivers/mtd/spi-nor/sfdp.c
+++ b/drivers/mtd/spi-nor/sfdp.c
@@ -456,7 +456,6 @@ static int spi_nor_parse_bfpt(struct spi_nor *nor,
 	/* Number of address bytes. */
 	switch (bfpt.dwords[BFPT_DWORD(1)] & BFPT_DWORD1_ADDRESS_BYTES_MASK) {
 	case BFPT_DWORD1_ADDRESS_BYTES_3_ONLY:
-	case BFPT_DWORD1_ADDRESS_BYTES_3_OR_4:
 		nor->addr_width = 3;
 		break;
 
-- 
2.28.0

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH linux dev-5.8] mtd: spi-nor: sfdp: Revert "default to addr_width of 3 for configurable widths"
  2020-08-12  3:58 [PATCH linux dev-5.8] mtd: spi-nor: sfdp: Revert "default to addr_width of 3 for configurable widths" Joel Stanley
@ 2020-08-12  7:15 ` Cédric Le Goater
  2020-08-12 11:26   ` Joel Stanley
  2020-08-12 17:44 ` Adriana Kobylak
  1 sibling, 1 reply; 4+ messages in thread
From: Cédric Le Goater @ 2020-08-12  7:15 UTC (permalink / raw)
  To: Joel Stanley, openbmc

On 8/12/20 5:58 AM, Joel Stanley wrote:
> This reverts commit f9acd7fa80be6ee14aecdc54429f2a48e56224e8 which
> breaks mounting of UBI volumes with the aspeed-smc driver:
> 
>  ubi0: default fastmap pool size: 25
>  ubi0: default fastmap WL pool size: 12
>  ubi0: attaching mtd3
>  ubi0: scanning is finished
>  ubi0 error: ubi_read_volume_table: the layout volume was not found
>  ubi0 error: ubi_attach_mtd_dev: failed to attach mtd3, error -22
> 
> Found by bisecting between v5.7 and v5.8.
> 
> Fixes: f9acd7fa80be ("mtd: spi-nor: sfdp: default to addr_width of 3 for configurable widths")
> Signed-off-by: Joel Stanley <joel@jms.id.au>
> ---
> This identifies why we are seeing SPI NOR failures on v5.8. There is
> potentially a fix that needs to be made in the aspeed-smc driver instead
> of reverting the core spi-nor change.


May be we should introduce a 'post_bfpt_fixups' handler for the mx66l1g45g
instead.

C.


> 
> Signed-off-by: Joel Stanley <joel@jms.id.au>
> ---
>  drivers/mtd/spi-nor/sfdp.c | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/drivers/mtd/spi-nor/sfdp.c b/drivers/mtd/spi-nor/sfdp.c
> index 55c0c508464b..9db07182e9c8 100644
> --- a/drivers/mtd/spi-nor/sfdp.c
> +++ b/drivers/mtd/spi-nor/sfdp.c
> @@ -456,7 +456,6 @@ static int spi_nor_parse_bfpt(struct spi_nor *nor,
>  	/* Number of address bytes. */
>  	switch (bfpt.dwords[BFPT_DWORD(1)] & BFPT_DWORD1_ADDRESS_BYTES_MASK) {
>  	case BFPT_DWORD1_ADDRESS_BYTES_3_ONLY:
> -	case BFPT_DWORD1_ADDRESS_BYTES_3_OR_4:
>  		nor->addr_width = 3;
>  		break;
>  
> 

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH linux dev-5.8] mtd: spi-nor: sfdp: Revert "default to addr_width of 3 for configurable widths"
  2020-08-12  7:15 ` Cédric Le Goater
@ 2020-08-12 11:26   ` Joel Stanley
  0 siblings, 0 replies; 4+ messages in thread
From: Joel Stanley @ 2020-08-12 11:26 UTC (permalink / raw)
  To: Cédric Le Goater; +Cc: OpenBMC Maillist

On Wed, 12 Aug 2020 at 07:15, Cédric Le Goater <clg@kaod.org> wrote:
>
> On 8/12/20 5:58 AM, Joel Stanley wrote:
> > This reverts commit f9acd7fa80be6ee14aecdc54429f2a48e56224e8 which
> > breaks mounting of UBI volumes with the aspeed-smc driver:
> >
> >  ubi0: default fastmap pool size: 25
> >  ubi0: default fastmap WL pool size: 12
> >  ubi0: attaching mtd3
> >  ubi0: scanning is finished
> >  ubi0 error: ubi_read_volume_table: the layout volume was not found
> >  ubi0 error: ubi_attach_mtd_dev: failed to attach mtd3, error -22
> >
> > Found by bisecting between v5.7 and v5.8.
> >
> > Fixes: f9acd7fa80be ("mtd: spi-nor: sfdp: default to addr_width of 3 for configurable widths")
> > Signed-off-by: Joel Stanley <joel@jms.id.au>
> > ---
> > This identifies why we are seeing SPI NOR failures on v5.8. There is
> > potentially a fix that needs to be made in the aspeed-smc driver instead
> > of reverting the core spi-nor change.
>
>
> May be we should introduce a 'post_bfpt_fixups' handler for the mx66l1g45g
> instead.

I don't think that will cover it on it's own. This caused a ubi
failure on a system that has mx25l25635e parts.

>
> C.
>
>
> >
> > Signed-off-by: Joel Stanley <joel@jms.id.au>
> > ---
> >  drivers/mtd/spi-nor/sfdp.c | 1 -
> >  1 file changed, 1 deletion(-)
> >
> > diff --git a/drivers/mtd/spi-nor/sfdp.c b/drivers/mtd/spi-nor/sfdp.c
> > index 55c0c508464b..9db07182e9c8 100644
> > --- a/drivers/mtd/spi-nor/sfdp.c
> > +++ b/drivers/mtd/spi-nor/sfdp.c
> > @@ -456,7 +456,6 @@ static int spi_nor_parse_bfpt(struct spi_nor *nor,
> >       /* Number of address bytes. */
> >       switch (bfpt.dwords[BFPT_DWORD(1)] & BFPT_DWORD1_ADDRESS_BYTES_MASK) {
> >       case BFPT_DWORD1_ADDRESS_BYTES_3_ONLY:
> > -     case BFPT_DWORD1_ADDRESS_BYTES_3_OR_4:
> >               nor->addr_width = 3;
> >               break;
> >
> >
>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH linux dev-5.8] mtd: spi-nor: sfdp: Revert "default to addr_width of 3 for configurable widths"
  2020-08-12  3:58 [PATCH linux dev-5.8] mtd: spi-nor: sfdp: Revert "default to addr_width of 3 for configurable widths" Joel Stanley
  2020-08-12  7:15 ` Cédric Le Goater
@ 2020-08-12 17:44 ` Adriana Kobylak
  1 sibling, 0 replies; 4+ messages in thread
From: Adriana Kobylak @ 2020-08-12 17:44 UTC (permalink / raw)
  To: Joel Stanley; +Cc: openbmc, Cédric Le Goater, openbmc

On 2020-08-11 22:58, Joel Stanley wrote:
> This reverts commit f9acd7fa80be6ee14aecdc54429f2a48e56224e8 which
> breaks mounting of UBI volumes with the aspeed-smc driver:
> 
>  ubi0: default fastmap pool size: 25
>  ubi0: default fastmap WL pool size: 12
>  ubi0: attaching mtd3
>  ubi0: scanning is finished
>  ubi0 error: ubi_read_volume_table: the layout volume was not found
>  ubi0 error: ubi_attach_mtd_dev: failed to attach mtd3, error -22
> 
> Found by bisecting between v5.7 and v5.8.
> 
> Fixes: f9acd7fa80be ("mtd: spi-nor: sfdp: default to addr_width of 3
> for configurable widths")
> Signed-off-by: Joel Stanley <joel@jms.id.au>

Tested-by: Adriana Kobylak <anoo@us.ibm.com>

> ---
> This identifies why we are seeing SPI NOR failures on v5.8. There is
> potentially a fix that needs to be made in the aspeed-smc driver 
> instead
> of reverting the core spi-nor change.
> 
> Signed-off-by: Joel Stanley <joel@jms.id.au>
> ---
>  drivers/mtd/spi-nor/sfdp.c | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/drivers/mtd/spi-nor/sfdp.c b/drivers/mtd/spi-nor/sfdp.c
> index 55c0c508464b..9db07182e9c8 100644
> --- a/drivers/mtd/spi-nor/sfdp.c
> +++ b/drivers/mtd/spi-nor/sfdp.c
> @@ -456,7 +456,6 @@ static int spi_nor_parse_bfpt(struct spi_nor *nor,
>  	/* Number of address bytes. */
>  	switch (bfpt.dwords[BFPT_DWORD(1)] & BFPT_DWORD1_ADDRESS_BYTES_MASK) 
> {
>  	case BFPT_DWORD1_ADDRESS_BYTES_3_ONLY:
> -	case BFPT_DWORD1_ADDRESS_BYTES_3_OR_4:
>  		nor->addr_width = 3;
>  		break;

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2020-08-12 17:44 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-12  3:58 [PATCH linux dev-5.8] mtd: spi-nor: sfdp: Revert "default to addr_width of 3 for configurable widths" Joel Stanley
2020-08-12  7:15 ` Cédric Le Goater
2020-08-12 11:26   ` Joel Stanley
2020-08-12 17:44 ` Adriana Kobylak

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.