Re: [PATCH v2 3/4] dt-bindings: mtd: macronix,mx25l12833f: add SPI-NOR chip

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 7/1/24 6:08 PM, Erez wrote:
> On Mon, 1 Jul 2024 at 12:15, Tudor Ambarus <tudor.ambarus@xxxxxxxxxx> wrote:
>>
>>
>>
>> On 7/1/24 10:46 AM, Erez wrote:
>>> When using mx25l12805d, we do not read SFDP.
>>> As it uses the no-SFDP flags.
>>> When using mx25l12833f hardware with mx25l12805d driver, it did not
>>> try to read the SFDP.
>>> Yet mx25l12833f does have SFDP, when I remove the no-SFDP flags, the
>>> driver fetch the SFDP.
>>>
>>> Secondly SFDP does not contain OTP information.
>>>
>>> mx25l12805d has two OTP regions of 128 KiB and 384 KiB (yes asymmetric).
>>> While mx25l12833f has two OTP regions of 512 KiB.
>>>
>>> How do we handle it?
>>
>> You would first try to parse SFDP and initialize the flash based on
>> SFDP. If there's no SFDP then you fallback to the flags declared at
>> flash declaration. Esben had a try recently, see [1]. I don't know if
>> there's any progress in that direction.
>>
>> Also, you haven't mentioned anything about the testing. Do you have the
>> flash?
>>
>> [1]
>> https://lore.kernel.org/linux-mtd/20240603-macronix-mx25l3205d-fixups-v2-0-ff98da26835c@xxxxxxxxxx/
> 
> Looking at "mtd: spi-nor: macronix: workaround for device id re-use"
> I guess it can be applied to all Macronix devices.

No, no, we're going to do it individually just where it's needed.
Issuing unsupported commands is not that great.

> Adding something like the following in macronix_nor_default_init():
> 
> if (info>no_sfdp_flags)
>     info>no_sfdp_flags |= SPI_NOR_TRY_SFDP
> 
> It seems Macronix did many reuse of IDs.
> I saw it with "mx25l12833f" reusing "mx25l12805d".
> And Esben saw it with MX25L3233F reusing "MX25L3205D".
> 
> The only thing I notice is the flash using the same size.
> A sort of "backward" compatible.
> 
> Erez




[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux