From: sashiko-bot@kernel.org
To: "Miquel Raynal" <miquel.raynal@bootlin.com>,
"Richard Weinberger" <richard@nod.at>,
"Vignesh Raghavendra" <vigneshr@ti.com>,
"Daisuke Mizobuchi" <mizo@atmark-techno.com>,
"Dominique Martinet" <dominique.martinet@atmark-techno.com>
Cc: "Thomas Petazzoni" <thomas.petazzoni@bootlin.com>,
"Steam Lin" <stlin2@winbond.com>,
linux-mtd@lists.infradead.org
Subject: Re: [PATCH 03/13] mtd: spinand: winbond: Generalize the LW OOB layout
Date: Fri, 30 Oct 2026 17:51:56 +0000 [thread overview]
Message-ID: <sashiko-outbox-191362@kernel.org> (raw)
In-Reply-To: <20261030-winbond-master-w25nxxlvw-v1-3-91f67407dc8b@bootlin.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Medium] mtd: spinand: winbond: W25N04LW left using w25nxxkv_kw_ooblayout
--
commit 64760906da7fbc1faf3036caf91cb645ff00e508
Author: Miquel Raynal <miquel.raynal@bootlin.com>
mtd: spinand: winbond: Generalize the LW OOB layout
This commit renames the W25N08LW OOB layout helpers and ops structure to
w25nxxlv_lw_ooblayout* so they can be shared across W25NxxLV and W25NxxLW
chips, and updates w25nxxlv_lw_ooblayout_free() to compute the section limit
from mtd->writesize.
> diff --git a/drivers/mtd/nand/spi/winbond.c b/drivers/mtd/nand/spi/winbond.c
> index 4ef30f1a4aa8e..e3be93690bb71 100644
> --- a/drivers/mtd/nand/spi/winbond.c
> +++ b/drivers/mtd/nand/spi/winbond.c
[ ... ]
> @@ -852,7 +855,7 @@ static const struct spinand_info winbond_spinand_table[] = {
> &update_cache_variants,
> &cont_read_cache_variants),
> 0,
> - SPINAND_ECCINFO(&w25n08lw_ooblayout, w25n02kv_ecc_get_status),
> + SPINAND_ECCINFO(&w25nxxlv_lw_ooblayout, w25n02kv_ecc_get_status),
> SPINAND_CONT_READ(w25n0xjw_set_cont_read)),
> };
[Severity: Medium]
Should the W25N04LW entry in winbond_spinand_table also be updated to use
w25nxxlv_lw_ooblayout here?
Earlier in this series, commit 4c37f4cb3704 ("mtd: spinand: winbond: Fix an
OOB layout inconsistency with W25NxxLW chips") switched W25N04LW from
w25n02kv_ooblayout to w25n08lw_ooblayout, but the following commit
c7bc36662c75 ("mtd: spinand: winbond: Generalize the KV OOB layout")
replaced it with w25nxxkv_kw_ooblayout:
drivers/mtd/nand/spi/winbond.c:winbond_spinand_table[] {
...
SPINAND_INFO("W25N04LW", /* 1.8V */
SPINAND_ID(SPINAND_READID_METHOD_OPCODE_DUMMY, 0xb2, 0x23),
NAND_MEMORG(1, 4096, 256, 64, 2048, 40, 1, 1, 1),
NAND_ECCREQ(8, 512),
SPINAND_INFO_OP_VARIANTS(&read_cache_variants,
&write_cache_variants,
&update_cache_variants),
0,
SPINAND_ECCINFO(&w25nxxkv_kw_ooblayout, w25n02kv_ecc_get_status)),
...
}
When a W25N04LW chip is probed, leaving it on w25nxxkv_kw_ooblayout exposes
the 2 non-ECC-protected User Data II bytes per section via
w25nxxkv_kw_ooblayout_free() and reports ECC regions in the upper half of
OOB via w25nxxkv_kw_ooblayout_ecc(), even though the second half of OOB is
not accessible when the on-die ECC engine is enabled.
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261030-winbond-master-w25nxxlvw-v1-0-91f67407dc8b@bootlin.com?part=3
______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
next prev parent reply other threads:[~2026-10-30 17:52 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-30 17:45 [PATCH 00/13] mtd: spinand winbond: Add support for W25NxxLV and W25NxxLW chips Miquel Raynal
2026-10-30 17:45 ` [PATCH 01/13] mtd: spinand: winbond: Fix an OOB layout inconsistency with " Miquel Raynal
2026-10-30 17:45 ` [PATCH 02/13] mtd: spinand: winbond: Generalize the KV OOB layout Miquel Raynal
2026-10-30 17:51 ` sashiko-bot
2026-10-30 20:27 ` Dominique Martinet
2026-10-30 17:45 ` [PATCH 03/13] mtd: spinand: winbond: Generalize the LW " Miquel Raynal
2026-10-30 17:51 ` sashiko-bot [this message]
2026-10-30 17:45 ` [PATCH 04/13] mtd: spinand: winbond: Rename the ->set_cont_read() helper Miquel Raynal
2026-10-30 17:45 ` [PATCH 05/13] mtd: spinand: winbond: Rename the ->ecc_get_status() helper Miquel Raynal
2026-10-30 17:45 ` [PATCH 06/13] mtd: spinand: winbond: Add 1S_1S_1S continuous read variant Miquel Raynal
2026-10-30 17:45 ` [PATCH 07/13] mtd: spinand: winbond: Add basic support for W25N02LV Miquel Raynal
2026-10-30 17:45 ` [PATCH 08/13] mtd: spinand: winbond: Add basic support for W25N04LV Miquel Raynal
2026-10-30 17:45 ` [PATCH 09/13] mtd: spinand: winbond: Add basic support for W25N02LW Miquel Raynal
2026-10-30 17:45 ` [PATCH 10/13] mtd: spinand: winbond: Add continuous read support for W25N02LV Miquel Raynal
2026-10-30 17:45 ` [PATCH 11/13] mtd: spinand: winbond: Add continuous read support for W25N04LV Miquel Raynal
2026-10-30 17:45 ` [PATCH 12/13] mtd: spinand: winbond: Add continuous read support for W25N02LW Miquel Raynal
2026-10-30 17:45 ` [PATCH 13/13] mtd: spinand: winbond: Add continuous read support for W25N04LW Miquel Raynal
2026-10-30 17:57 ` sashiko-bot
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=sashiko-outbox-191362@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=dominique.martinet@atmark-techno.com \
--cc=linux-mtd@lists.infradead.org \
--cc=miquel.raynal@bootlin.com \
--cc=mizo@atmark-techno.com \
--cc=richard@nod.at \
--cc=sashiko-reviews@lists.linux.dev \
--cc=stlin2@winbond.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 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.