mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Armin Wolf <W_Armin@gmx.de>
To: "Thomas Weißschuh" <linux@weissschuh.net>,
	"Guenter Roeck" <linux@roeck-us.net>
Cc: linux-hwmon@vger.kernel.org, devicetree@vger.kernel.org,
	"Rob Herring" <robh@kernel.org>,
	"Krzysztof Kozlowski" <krzk+dt@kernel.org>,
	"Conor Dooley" <conor+dt@kernel.org>,
	linux-kernel@vger.kernel.org, "René Rebe" <rene@exactcode.de>,
	"Wolfram Sang" <wsa+renesas@sang-engineering.com>
Subject: Re: [PATCH RFT v3 4/4] hwmon: (spd5118) Add support for reading SPD data
Date: Sat, 1 Jun 2024 21:23:24 +0200	[thread overview]
Message-ID: <b3109c26-dde1-44cf-b431-80957c97de5f@gmx.de> (raw)
In-Reply-To: <4e4341e4-2165-40d4-909c-9d5164e97942@t-8ch.de>

Am 01.06.24 um 16:08 schrieb Thomas Weißschuh:

> On 2024-06-01 06:48:29+0000, Guenter Roeck wrote:
>
> <snip>
>
>> Makes sense. Another question:
>>
>> This:
>>
>> +        struct nvmem_config nvmem_config = {
>> +               .type = NVMEM_TYPE_EEPROM,
>> +               .name = dev_name(dev),
>> +               .id = NVMEM_DEVID_AUTO,
>>
>> results in:
>>
>> $ ls /sys/bus/nvmem/devices
>> 0-00501  0-00512  0-00523  0-00534  cmos_nvram0
>> ^^^^^^^  ^^^^^^^  ^^^^^^^  ^^^^^^^
>>
>> which really doesn't look good. My current plan is to go with NVMEM_DEVID_NONE,
>> which results in
>>
>> $ ls /sys/bus/nvmem/devices
>> 0-0050	0-0051	0-0052	0-0053	cmos_nvram0
>>
>> We could also used fixed strings, but "spd" results in "spd[1-4]" which
>> I think would be a bit misleading since the DDR3/4 SPD data format is
>> different, and "spd5118" would result in "spd5118[1-4]" which again would
>> look odd. Any suggestions ?
> In order of descending, personal preference:
>
> * spd-ddr5-[0-3] (.id = client->address - 0x50)

Hi,

this will break as soon as more than 8 DDR5 DIMMs are installed.

> * spd-ddr5-[0-3] (NVMEM_DEVID_AUTO)
> * Same with only "ddr5-"
> * spd5118-[0-3]
> * Your proposal from above
> * nvmem[0-3] (default handling)
> * 0-0050-[0-3]
>
> Also can't a user of the eeprom already figure out which kind of module
> it is by looking at the eeprom contents?
> The first few bytes used for that seem to be compatible between at least
> DDR4 and DDR5.
>
> So using plain spd[1-4] could be enough.

This could cause problems when DDR6 arrives.
Personally i would prefer the spd5118-X (NVMEM_DEVID_AUTO) format.

Thanks,
Armin Wolf


  reply	other threads:[~2024-06-01 19:23 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-31 23:05 [PATCH v3 0/4] hwmon: Add support for SPD5118 compliant chips Guenter Roeck
2024-05-31 23:05 ` [PATCH v3 1/4] dt-bindings: trivial-devices: Add jedec,spd5118 Guenter Roeck
2024-06-01 15:19   ` Krzysztof Kozlowski
2024-05-31 23:05 ` [PATCH v3 2/4] hwmon: Add support for SPD5118 compliant temperature sensors Guenter Roeck
2024-06-01  1:28   ` Wolfram Sang
2024-06-01  3:40     ` Guenter Roeck
2024-06-02 20:18       ` Wolfram Sang
2024-06-02 21:24         ` Guenter Roeck
2024-06-01 19:14   ` Armin Wolf
2024-05-31 23:05 ` [PATCH RFT v3 3/4] hwmon: (spd5118) Add suspend/resume support Guenter Roeck
2024-06-01 19:17   ` Armin Wolf
2024-06-03 12:31   ` Stephen Horvath
2024-06-03 13:50     ` Guenter Roeck
2024-05-31 23:05 ` [PATCH RFT v3 4/4] hwmon: (spd5118) Add support for reading SPD data Guenter Roeck
2024-06-01  5:42   ` Guenter Roeck
2024-06-01 10:41     ` Thomas Weißschuh
2024-06-01 13:48       ` Guenter Roeck
2024-06-01 14:08         ` Thomas Weißschuh
2024-06-01 19:23           ` Armin Wolf [this message]
2024-06-02  7:55             ` Thomas Weißschuh
2024-06-02 15:25               ` Guenter Roeck
2024-06-02 16:06               ` Guenter Roeck
2024-06-01  1:26 ` [PATCH v3 0/4] hwmon: Add support for SPD5118 compliant chips Wolfram Sang

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=b3109c26-dde1-44cf-b431-80957c97de5f@gmx.de \
    --to=w_armin@gmx.de \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=krzk+dt@kernel.org \
    --cc=linux-hwmon@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@roeck-us.net \
    --cc=linux@weissschuh.net \
    --cc=rene@exactcode.de \
    --cc=robh@kernel.org \
    --cc=wsa+renesas@sang-engineering.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

all inboxes | Powered by JetHome®