Skip to content

Conversation

@astrunin
Copy link

@astrunin astrunin commented Sep 19, 2025

Hi,

I applied patch from:
https://www.spinics.net/lists//devicetree/msg694496.html

For the test we were using EVB that has SPI eeprom on board. Here are dts nodes I added to the IPQ dts:

spi_bridge0: spi@28 {
			compatible = "nxp,sc18is606";
			reg = <0x28>;
		
		eeprom@1 {
			/* EVB manual says to use SS1 as CS */
			reg = <1>;

			compatible = "atmel,at25";
			address-width = <8>;
			size = <128>;
			pagesize = <8>;

			spi-max-frequency = <1875000>;

			/* EVB datasheet says to use SPI mode 3, so cpol and cpha are 1 */

			spi-cpol;
			spi-cpha;
			};
		};

And then to test write/read to eeprom used:

echo "test" > /sys/class/spi_master/spi1/spi1.1/eeprom
cat /sys/class/spi_master/spi1/spi1.1/eeprom

@adrian-nicolau
Copy link

approved, but let's merge it only after we test on real HW

@shmuelhazan
Copy link
Collaborator

@astrunin Can you please update in the description how it was tested? Thanks

@astrunin astrunin merged commit c3afce0 into tg-v6.12 Oct 15, 2025
shmuelhazan pushed a commit that referenced this pull request Nov 6, 2025
Hi,

I applied patch from:
https://www.spinics.net/lists//devicetree/msg694496.html

For now only compilation is tested as we don't have anything to test it
on yet.

For the test we were using EVB that has SPI eeprom on board. Here are
dts nodes I added to the IPQ dts:
```
spi_bridge0: spi@28 {
			compatible = "nxp,sc18is606";
			reg = <0x28>;

		eeprom@1 {
			/* EVB manual says to use SS1 as CS */
			reg = <1>;

			compatible = "atmel,at25";
			address-width = <8>;
			size = <128>;
			pagesize = <8>;

			spi-max-frequency = <1875000>;

			/* EVB datasheet says to use SPI mode 3, so cpol and cpha are 1 */

			spi-cpol;
			spi-cpha;
			};
		};
```

And then to test write/read to eeprom used:
```
echo "test" > /sys/class/spi_master/spi1/spi1.1/eeprom
cat /sys/class/spi_master/spi1/spi1.1/eeprom
```
adrian-nicolau pushed a commit that referenced this pull request Nov 13, 2025
Hi,

I applied patch from:
https://www.spinics.net/lists//devicetree/msg694496.html

For now only compilation is tested as we don't have anything to test it
on yet.

For the test we were using EVB that has SPI eeprom on board. Here are
dts nodes I added to the IPQ dts:
```
spi_bridge0: spi@28 {
			compatible = "nxp,sc18is606";
			reg = <0x28>;

		eeprom@1 {
			/* EVB manual says to use SS1 as CS */
			reg = <1>;

			compatible = "atmel,at25";
			address-width = <8>;
			size = <128>;
			pagesize = <8>;

			spi-max-frequency = <1875000>;

			/* EVB datasheet says to use SPI mode 3, so cpol and cpha are 1 */

			spi-cpol;
			spi-cpha;
			};
		};
```

And then to test write/read to eeprom used:
```
echo "test" > /sys/class/spi_master/spi1/spi1.1/eeprom
cat /sys/class/spi_master/spi1/spi1.1/eeprom
```
adrian-nicolau pushed a commit that referenced this pull request Nov 18, 2025
The following lockdep splat was observed while kernel auto-online a CXL
memory region:

======================================================
WARNING: possible circular locking dependency detected
6.17.0djtest+ #53 Tainted: G        W
------------------------------------------------------
systemd-udevd/3334 is trying to acquire lock:
ffffffff90346188 (hmem_resource_lock){+.+.}-{4:4}, at: hmem_register_resource+0x31/0x50

but task is already holding lock:
ffffffff90338890 ((node_chain).rwsem){++++}-{4:4}, at: blocking_notifier_call_chain+0x2e/0x70

which lock already depends on the new lock.
[..]
Chain exists of:
  hmem_resource_lock --> mem_hotplug_lock --> (node_chain).rwsem

 Possible unsafe locking scenario:

       CPU0                    CPU1
       ----                    ----
  rlock((node_chain).rwsem);
                               lock(mem_hotplug_lock);
                               lock((node_chain).rwsem);
  lock(hmem_resource_lock);

The lock ordering can cause potential deadlock. There are instances
where hmem_resource_lock is taken after (node_chain).rwsem, and vice
versa.

Split out the target update section of hmat_register_target() so that
hmat_callback() only envokes that section instead of attempt to register
hmem devices that it does not need to.

[ dj: Fix up comment to be closer to 80cols. (Jonathan) ]

Fixes: cf8741a ("ACPI: NUMA: HMAT: Register "soft reserved" memory as an "hmem" device")
Reviewed-by: Jonathan Cameron <[email protected]>
Tested-by: Smita Koralahalli <[email protected]>
Reviewed-by: Smita Koralahalli <[email protected]>
Reviewed-by: Dan Williams <[email protected]>
Link: https://patch.msgid.link/[email protected]
Signed-off-by: Dave Jiang <[email protected]>
adrian-nicolau pushed a commit that referenced this pull request Nov 28, 2025
Hi,

I applied patch from:
https://www.spinics.net/lists//devicetree/msg694496.html

For now only compilation is tested as we don't have anything to test it
on yet.

For the test we were using EVB that has SPI eeprom on board. Here are
dts nodes I added to the IPQ dts:
```
spi_bridge0: spi@28 {
			compatible = "nxp,sc18is606";
			reg = <0x28>;

		eeprom@1 {
			/* EVB manual says to use SS1 as CS */
			reg = <1>;

			compatible = "atmel,at25";
			address-width = <8>;
			size = <128>;
			pagesize = <8>;

			spi-max-frequency = <1875000>;

			/* EVB datasheet says to use SPI mode 3, so cpol and cpha are 1 */

			spi-cpol;
			spi-cpha;
			};
		};
```

And then to test write/read to eeprom used:
```
echo "test" > /sys/class/spi_master/spi1/spi1.1/eeprom
cat /sys/class/spi_master/spi1/spi1.1/eeprom
```
adrian-nicolau pushed a commit that referenced this pull request Dec 1, 2025
Hi,

I applied patch from:
https://www.spinics.net/lists//devicetree/msg694496.html

For now only compilation is tested as we don't have anything to test it
on yet.

For the test we were using EVB that has SPI eeprom on board. Here are
dts nodes I added to the IPQ dts:
```
spi_bridge0: spi@28 {
			compatible = "nxp,sc18is606";
			reg = <0x28>;

		eeprom@1 {
			/* EVB manual says to use SS1 as CS */
			reg = <1>;

			compatible = "atmel,at25";
			address-width = <8>;
			size = <128>;
			pagesize = <8>;

			spi-max-frequency = <1875000>;

			/* EVB datasheet says to use SPI mode 3, so cpol and cpha are 1 */

			spi-cpol;
			spi-cpha;
			};
		};
```

And then to test write/read to eeprom used:
```
echo "test" > /sys/class/spi_master/spi1/spi1.1/eeprom
cat /sys/class/spi_master/spi1/spi1.1/eeprom
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants