Re: [PATCH 1/2] i2c: i801: Detect SPD Write Disable and expose as adapter quirk
From: Guenter Roeck
Date: Thu Jun 11 2026 - 00:37:10 EST
On 6/10/26 01:54, TINSAE TADESSE wrote:
On Mon, Jun 8, 2026 at 3:28 PM Andi Shyti <andi.shyti@xxxxxxxxxx> wrote:
Hi Tinsae,
sorry for the very late reply.
+/* SPD writes are blocked by host controller */
+#define I2C_AQ_SPD_WRITE_DISABLED BIT(8)
+
We don't need this extra flag, we already do this statement in
i2c_register_spd().
Can't we just assume that for spd5118 spd write is always
disabled? That's what happens in i2c_register_spd.
Check:
84d477354b0a ("i2c: smbus: Support DDR5 and LPDDR5 SPD EEPROMs")
4d6d35d3417d ("i2c: smbus: introduce Write Disable-aware SPD instantiating functions")
Thanks,
Andi
Hi Andi,
Thanks for reviewing this patch series.
We don't need this extra flag, we already do this statement in
i2c_register_spd().
Based on my testing, the issue does not appear to be in the SPD
registration path
handled by 'i2c_register_spd()'.
I verified that:
* The i801 driver correctly detects SPD Write Disable.
* Disabling 'CONFIG_SENSORS_SPD5118_DETECT' completely eliminates the problem.
* The suspend/resume failures only occur when 'CONFIG_SENSORS_SPD5118_DETECT=y'.
Based on these observations, it appears that the SPD5118 detect path
may instantiate
the device independently of the SPD registration logic and therefore
may bypass the
SPD Write Disable handling added by commit 4d6d35d3417d ("i2c: smbus:
introduce Write
Disable-aware SPD instantiating functions").
This would explain why SPD5118 is still instantiated on systems where SPD Write
Disable is active, even though the SPD registration helpers are
already SPD WD aware.
The above observations are what motivated this patch series. Am I correct in
suspecting that the SPD5118 detect path is separate from the SPD
registration path, or
is there another instantiation path that I should investigate?
The detect path [spd5118_detect()] is intended for systems where
i2c_register_spd() is not called. After all, not all systems with
DDR5 support have i801 or piix4 I2C controllers installed.
If your system uses one of those controllers (i.e., Intel or AMD
CPU), CONFIG_SENSORS_SPD5118_DETECT is not needed and should not be
enabled. There are some exceptions, such as servers with a large
number of DIMM slots, but that is not common.
Guenter