[PATCH v4 10/11] mtd: spi-nand: Set the DQS spi-mem capability if available
sashiko-bot at kernel.org
sashiko-bot at kernel.org
Fri Nov 20 09:30:06 PST 2026
Thank you for your contribution! Sashiko AI review found 1 potential
issue to consider:
- [Medium] mtd: spinand: spi_mem_set_dqs_pin_available() called after
SSDR negotiation
--
commit ded1f01b00a338383ed4e62228f6b415856c9df3
Author: Miquel Raynal <miquel.raynal at bootlin.com>
mtd: spi-nand: Set the DQS spi-mem capability if available
This commit adds the SPINAND_HAS_DQS flag and calls
spi_mem_set_dqs_pin_available() in spinand_match_and_init() when a
matched SPI-NAND chip supports DQS.
> diff --git a/drivers/mtd/nand/spi/core.c b/drivers/mtd/nand/spi/core.c
> index fee4a48b4c7f3..6e1b7976d2379 100644
> --- a/drivers/mtd/nand/spi/core.c
> +++ b/drivers/mtd/nand/spi/core.c
> @@ -1797,6 +1797,9 @@ int spinand_match_and_init(struct spinand_device *spinand,
> }
> }
>
> + if (spinand->flags & SPINAND_HAS_DQS)
> + spi_mem_set_dqs_pin_available(spinand->spimem);
> +
> /* I/O variants selection with octo-spi DDR commands (optional) */
>
> ret = spinand_init_odtr_instruction_set(spinand);
[Severity: Medium]
Should spi_mem_set_dqs_pin_available() be called right after
spinand->flags is initialized, before SSDR operation variants are
selected?
Placing it here leaves spinand->spimem->dqs_pin false while
spinand_select_op_variant(spinand, SSDR, ...) and
spinand_support_vendor_ops(spinand, info, SSDR) run, which also evaluate
1S-command DTR read variants such as
SPINAND_PAGE_READ_FROM_CACHE_1S_1D_8D_OP.
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261120-winbond-nand-next-phy-tuning-v4-0-8c21e1f71f41@bootlin.com?part=10
More information about the linux-mtd
mailing list