[PATCH v5 6/6] mtd: spi-nor: add support for Macronix Octal flash
Michael Walle
michael at walle.cc
Wed Nov 22 02:16:20 PST 2023
Hi,
>> >>> and sometimes incorrect. Therefore, at least drop it and just list the
>> >>> IDs.
>> >> Could I know patch 6/6 only or patch 5/6 should remove name as well?
>> >
>> > I'd say yes. Tudor? Pratyush? New flash additions without names?
>>
>> Why do you need a flash addition in the first place? Haven't we agreed
>> that we'll apply the vendor fixup based on the manufacturer ID?
>>
>> Anyway, flash additions without names is fine by me.
>>
>> Cheers,
>> ta
>> >
>> > As, mentioned last time, for OF we might introduce an of_compatible
>> > (thats then ABI) - or - we can use the numeric ID in the device tree,
>> > as it's already used for PHY IDs or PCI IDs.
>> >
>> > Jaime, could you try to use
>> >
>> > /* Apply vendor fixups */
>> > { .id = SNOR_ID(0xc2) }
> I have validate some flash without "name" and looks good.
Great :)
> But I got some log with (null) like below:
>
> SPI-NOR SPI0.0: (null) (32768 Kbytes)
dev_info(dev, "%s (%lld Kbytes)\n", info->name ?: "",
(long long)mtd->size >> 10);
Maybe we should print the vendor and the name and
both are optional? I don't have a strong opinion here
as long as it's not "(null)" because that looks like
a bug.
> and
>
> zynq> cat jedec_id
> c2943c
> zynq> cat manufacturer
> macronix
> zynq> cat partname
> (null)
There is spi_nor_sysfs_is_visible() you can hide this property the
same was as the manufacturer property is hidden.
Also, please update
Documentation/ABI/testing/sysfs-bus-spi-devices-spi-nor in this case:
The attribute is optional. User space shouldn't rely on it to
be present or even correct. Instead, user space should read the
jedec_id attribute.
-michael
More information about the linux-mtd
mailing list