[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <DA3HXNN7HTD2.2NUKORU5V6CS2@kernel.org>
Date: Fri, 23 May 2025 13:16:50 +0200
From: "Michael Walle" <mwalle@...nel.org>
To: "Zixian Zeng" <sycamoremoon376@...il.com>, "Tudor Ambarus"
<tudor.ambarus@...aro.org>, "Pratyush Yadav" <pratyush@...nel.org>, "Miquel
Raynal" <miquel.raynal@...tlin.com>, "Richard Weinberger" <richard@....at>,
"Vignesh Raghavendra" <vigneshr@...com>, "Chen Wang"
<unicorn_wang@...look.com>, "Inochi Amaoto" <inochiama@...il.com>, "Mark
Brown" <broonie@...nel.org>, "Rob Herring" <robh@...nel.org>, "Krzysztof
Kozlowski" <krzk+dt@...nel.org>, "Conor Dooley" <conor+dt@...nel.org>,
"Paul Walmsley" <paul.walmsley@...ive.com>, "Palmer Dabbelt"
<palmer@...belt.com>, "Albert Ou" <aou@...s.berkeley.edu>, "Alexandre
Ghiti" <alex@...ti.fr>, "Longbin Li" <looong.bin@...il.com>
Cc: <linux-mtd@...ts.infradead.org>, <linux-kernel@...r.kernel.org>,
<sophgo@...ts.linux.dev>, <linux-spi@...r.kernel.org>,
<devicetree@...r.kernel.org>, <linux-riscv@...ts.infradead.org>,
<dlan@...too.org>, <ziyao@...root.org>
Subject: Re: [PATCH 2/3] mtd: spi-nor: Add GD25LB512ME GigaDevice flash_info
Hi,
> Add GD25LB512ME SPI-NOR flash information
Please have a look at [1].
This flash supports SFDP, do you really need a new entry in the
flashdb? Could you try without it?
In any case, could you please dump the SFDP see [1], too.
[1] https://docs.kernel.org/driver-api/mtd/spi-nor.html
> Signed-off-by: Zixian Zeng <sycamoremoon376@...il.com>
> ---
> drivers/mtd/spi-nor/gigadevice.c | 17 +++++++++++++++++
> 1 file changed, 17 insertions(+)
>
> diff --git a/drivers/mtd/spi-nor/gigadevice.c b/drivers/mtd/spi-nor/gigadevice.c
> index ef1edd0add70e6ca501620798a779d621d6bb00d..223b2f598ecd651ce8df6789dfbaf938c534f94f 100644
> --- a/drivers/mtd/spi-nor/gigadevice.c
> +++ b/drivers/mtd/spi-nor/gigadevice.c
> @@ -33,6 +33,15 @@ static const struct spi_nor_fixups gd25q256_fixups = {
> .post_bfpt = gd25q256_post_bfpt,
> };
>
> +static void gd25lb512me_default_init(struct spi_nor *nor)
> +{
> + nor->params->quad_enable = spi_nor_sr1_bit6_quad_enable;
Should be automatically set, by SFDP.
> +}
> +
> +static const struct spi_nor_fixups gd25lb512me_fixups = {
> + .default_init = gd25lb512me_default_init,
> +};
> +
> static const struct flash_info gigadevice_nor_parts[] = {
> {
> .id = SNOR_ID(0xc8, 0x40, 0x15),
> @@ -82,6 +91,14 @@ static const struct flash_info gigadevice_nor_parts[] = {
> .size = SZ_16M,
> .flags = SPI_NOR_HAS_LOCK | SPI_NOR_HAS_TB,
> .no_sfdp_flags = SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ,
> + }, {
> + .id = SNOR_ID(0xc8, 0x67, 0x1a),
> + .name = "gd25lb512me",
No name,
> + .size = SZ_64M,
> + .flags = SPI_NOR_HAS_LOCK | SPI_NOR_HAS_TB,
> + .no_sfdp_flags = SECT_4K | SPI_NOR_QUAD_READ,
No, no_sfdp_flags, as this flash supports SFDP.
> + .fixups = &gd25lb512me_fixups,
> + .fixup_flags = SPI_NOR_4B_OPCODES,
> },
> };
>
-michael
Download attachment "signature.asc" of type "application/pgp-signature" (298 bytes)
Powered by blists - more mailing lists