Re: [PATCH] dt-bindings: mtd: spi-nor: deprecate Everspin MRAM devices

From: Tudor Ambarus
Date: Thu Jun 06 2024 - 08:17:01 EST




On 6/5/24 14:58, Thorsten Scherer wrote:
> Hello,
>

Hi!

> in the past I more actively worked on the ci4x10. That changed after switching
> departments. Anyway, I thought maybe it's useful if I share my point of view.
>
> On Tue, Jun 04, 2024 at 09:42:31AM +0200, Michael Walle wrote:
>> These devices are more like an AT25 compatible EEPROM instead of
>> flashes. Like an EEPROM the user doesn't need to explicitly erase the
>> memory, nor are there sectors or pages. Thus, instead of the SPI-NOR
>> (flash) driver, one should instead use the at25 EEPROM driver.
>>
>> Signed-off-by: Michael Walle <mwalle@xxxxxxxxxx>
>> Cc: Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxxxx>
>
> You cannot reach Uwe via this address anymore.
>
> IMHO missing in this discussion is
>
> kernel@xxxxxxxxxxxxxx
>
> , which I added to CC.
>
>> Cc: Thorsten Scherer <t.scherer@xxxxxxxxxxxx>
>> Cc: Marek Vasut <marex@xxxxxxx>
>> Cc: Imre Kaloz <kaloz@xxxxxxxxxxx>
>> Cc: Andrew Lunn <andrew@xxxxxxx>
>> Cc: Flavio Suligoi <f.suligoi@xxxxxxx>
>> ---
>> The referenced binding only supports the true AT25 compatible EEPROMs
>> where you have to specify additional properties like size and page size
>> or cypress FRAM devices where all the properties are discovered by the
>> driver. I don't have the actual hardware, therefore I can't work on a
>> proper driver and binding. But I really want to deprecate the use of
>> these EEPROM like devices in SPI-NOR. So as a first step, mark the
>> devices in the DT bindings as deprecated.
>>
>> There are three in-tree users of this. I hope I've CCed all the relevant
>> people. With the switch to the at25 driver also comes a user-space
>> facing change: there is no more MTD device. Instead there is an "eeprom"
>> file in /sys now, just like for every other EEPROM.
>
> My vague memory tells me (at least some of) the domain specific applications
> running on ci4x10 rely on MTD(block?) devices. So this change would break
> user-space.

it's a possibility, indeed. I assume we don't know for sure, right?
>
>> Marek already expressed, that the sps1 dts can likely be removed
>> altogether. I'd like to hear from the other board DTS maintainers if
>> they seem some problems moving to the EEPROM interface - or maybe that
>> device isn't used at all anyway. So in the end, we can hopefully move

if it's not used at all we can remove it entirely.

>> all the users over to the at25 driver.
>
> The ci4x10 is still being used and sold. Right now I do not have a clear
> view on the implications of moving to that driver. I'd like to invest some
> time to sharpen my picture (or find the person that claims responsibility), but
> this will propably not happen this week.
>

if it's used then we are forced to keep the entry in SPI NOR for
backward compatibility. But we can still deprecate the use and forbid
new support in SPI NOR while directing users to the other driver.

> Hope this helps.
>
Thanks!
ta