From: Miquel Raynal <miquel.raynal@bootlin.com>
To: Paul Cercueil <paul.cercueil@bootlin.com>
Cc: "Pratyush Yadav" <pratyush@kernel.org>,
"Michael Walle" <mwalle@kernel.org>,
"Takahiro Kuwano" <takahiro.kuwano@infineon.com>,
"Richard Weinberger" <richard@nod.at>,
"Vignesh Raghavendra" <vigneshr@ti.com>,
"Nuno Sá" <nuno.sa@analog.com>,
linux-mtd@lists.infradead.org,
"Thomas Petazzoni" <thomas.petazzoni@bootlin.com>
Subject: Re: [PATCH] mtd: spi-nor: winbond: Drop octal PP support for W25Q256JW
Date: Wed, 02 Dec 2026 17:05:41 +0100 [thread overview]
Message-ID: <87v75bllbe.fsf@bootlin.com> (raw)
In-Reply-To: <20261202145124.483873-1-paul.cercueil@bootlin.com> (Paul Cercueil's message of "Wed, 2 Dec 2026 15:51:24 +0100")
On 02/12/2026 at 15:51:24 +01, Paul Cercueil <paul.cercueil@bootlin.com> wrote:
> The W25Q256JW reports support for octal page program in its SFDP but
> does not actually support it, according to my own tests as well as the
> datasheet.
>
> Fixes: 68d7115d77a8 ("mtd: spi-nor: sfdp: get the 1-1-8 and 1-8-8 page programs from 4BAIT")
> Signed-off-by: Paul Cercueil <paul.cercueil@bootlin.com>
> ---
> drivers/mtd/spi-nor/winbond.c | 15 +++++++++++++++
> 1 file changed, 15 insertions(+)
>
> diff --git a/drivers/mtd/spi-nor/winbond.c b/drivers/mtd/spi-nor/winbond.c
> index 51f6bcd3f8e5..5ca88749eaaa 100644
> --- a/drivers/mtd/spi-nor/winbond.c
> +++ b/drivers/mtd/spi-nor/winbond.c
> @@ -147,6 +147,20 @@ static const struct spi_nor_fixups w25q256_fixups = {
> .post_bfpt = w25q256_post_bfpt_fixups,
> };
>
> +static int w25q256jw_post_sfdp_fixups(struct spi_nor *nor)
> +{
> + struct spi_nor_flash_parameter *p = nor->params;
> +
> + /* W25Q256JW advertises octal page program but doesn't actually support it */
> + p->hwcaps.mask &= ~SNOR_HWCAPS_PP_OCTAL;
> +
> + return 0;
> +}
> +
> +static const struct spi_nor_fixups w25q256jw_fixups = {
> + .post_sfdp = w25q256jw_post_sfdp_fixups,
> +};
> +
> /**
> * winbond_nor_select_die() - Set active die.
> * @nor: pointer to 'struct spi_nor'.
> @@ -667,6 +681,7 @@ static const struct spi_nor_fixup winbond_fixups[] = {
> { .fixups = &winbond_nor_fixups },
> { .id = SNOR_ID(0xef, 0x40, 0x18), .fixups = &w25q128_fixups },
> { .id = SNOR_ID(0xef, 0x40, 0x19), .fixups = &w25q256_fixups },
> + { .id = SNOR_ID(0xef, 0x60, 0x19), .fixups = &w25q256jw_fixups
> },
Since the IDs have been reused, this ID by itself does not only cover
W25Q256JW. But since all the concerned chips are quad capable, dropping
an octal capability for them shouldn't be too problematic anyway. Since
you mention the chip explicitely in the fixup hook, I guess it's fine
like that.
Reviewed-by: Miquel Raynal <miquel.raynal@bootlin.com>
Thanks,
Miquèl
______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
prev parent reply other threads:[~2026-12-02 16:05 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-12-02 14:51 [PATCH] mtd: spi-nor: winbond: Drop octal PP support for W25Q256JW Paul Cercueil
2026-12-02 15:19 ` Nuno Sá
2026-12-02 16:05 ` Miquel Raynal [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87v75bllbe.fsf@bootlin.com \
--to=miquel.raynal@bootlin.com \
--cc=linux-mtd@lists.infradead.org \
--cc=mwalle@kernel.org \
--cc=nuno.sa@analog.com \
--cc=paul.cercueil@bootlin.com \
--cc=pratyush@kernel.org \
--cc=richard@nod.at \
--cc=takahiro.kuwano@infineon.com \
--cc=thomas.petazzoni@bootlin.com \
--cc=vigneshr@ti.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox