From: Jon Hunter <jonathanh@nvidia.com>
To: Michael Walle <mwalle@kernel.org>,
tkuw584924@gmail.com, linux-mtd@lists.infradead.org
Cc: tudor.ambarus@linaro.org, pratyush@kernel.org,
miquel.raynal@bootlin.com, richard@nod.at, vigneshr@ti.com,
Bacem.Daassi@infineon.com,
Takahiro Kuwano <Takahiro.Kuwano@infineon.com>,
"linux-tegra@vger.kernel.org" <linux-tegra@vger.kernel.org>
Subject: Re: [PATCH] mtd: spi-nor: spansion: Add support for S28HS256T
Date: Fri, 6 Sep 2024 18:23:00 +0100 [thread overview]
Message-ID: <c64154f0-25b9-4943-a3f5-52ee08b5f3be@nvidia.com> (raw)
In-Reply-To: <D3Z80PI18VZB.1ZLQ2TMR10UTG@kernel.org>
Hi Michael,
On 06/09/2024 14:04, Michael Walle wrote:
> Hi Jon,
>
>> Bisect is pointing to this commit and adding the 'name' field does fix
>> it. So it would appear the SPI NOR code still wants the name field.
>
> Thanks for the report, could you try the following patch.
>
> -michael
>
> diff --git a/drivers/mtd/spi-nor/core.c b/drivers/mtd/spi-nor/core.c
> index d8e551fd2e2a..101ee5b0ddeb 100644
> --- a/drivers/mtd/spi-nor/core.c
> +++ b/drivers/mtd/spi-nor/core.c
> @@ -3281,7 +3281,8 @@ static const struct flash_info *spi_nor_match_name(struct spi_nor *nor,
>
> for (i = 0; i < ARRAY_SIZE(manufacturers); i++) {
> for (j = 0; j < manufacturers[i]->nparts; j++) {
> - if (!strcmp(name, manufacturers[i]->parts[j].name)) {
> + if (manufacturers[i]->parts[j].name &&
> + !strcmp(name, manufacturers[i]->parts[j].name)) {
> nor->manufacturer = manufacturers[i];
> return &manufacturers[i]->parts[j];
> }
Works for me! If you plan to send a patch feel free to add my ...
Tested-by: Jon Hunter <jonathanh@nvidia.com>
Thanks
Jon
--
nvpublic
prev parent reply other threads:[~2024-09-06 17:23 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20240830030841.24500-1-Takahiro.Kuwano@infineon.com>
[not found] ` <D3T1W2VQFGNG.14DUML0OSKRH@kernel.org>
2024-09-06 11:47 ` [PATCH] mtd: spi-nor: spansion: Add support for S28HS256T Jon Hunter
2024-09-06 13:04 ` Michael Walle
2024-09-06 17:23 ` Jon Hunter [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=c64154f0-25b9-4943-a3f5-52ee08b5f3be@nvidia.com \
--to=jonathanh@nvidia.com \
--cc=Bacem.Daassi@infineon.com \
--cc=Takahiro.Kuwano@infineon.com \
--cc=linux-mtd@lists.infradead.org \
--cc=linux-tegra@vger.kernel.org \
--cc=miquel.raynal@bootlin.com \
--cc=mwalle@kernel.org \
--cc=pratyush@kernel.org \
--cc=richard@nod.at \
--cc=tkuw584924@gmail.com \
--cc=tudor.ambarus@linaro.org \
--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