summary refs log tree commit diff stats
path: root/tests
diff options
context:
space:
mode:
authorChalapathi V <chalapathi.v@linux.ibm.com>2025-03-03 08:13:27 -0600
committerNicholas Piggin <npiggin@gmail.com>2025-03-11 22:43:31 +1000
commit7192d7b7fea15f2226a896f02b360bf7cfce1ab1 (patch)
treee6537266565f5f0e916322185718418228adc611 /tests
parentf1f756f305981c24a37a0be3113c2326a28594a5 (diff)
downloadfocaccia-qemu-7192d7b7fea15f2226a896f02b360bf7cfce1ab1.tar.gz
focaccia-qemu-7192d7b7fea15f2226a896f02b360bf7cfce1ab1.zip
hw/ssi/pnv_spi: Make bus names distinct for each controllers of a socket
Create a spi buses with distinct names on each socket so that responders
are attached to correct SPI controllers.

Change the bus name to chipX.spi.<busnum> where X = 0..<num_sockets>

QOM tree on a 2 socket machine:
(qemu) info qom-tree
/machine (powernv10-machine)
  /chip[0] (power10_v2.0-pnv-chip)
    /pib_spic[0] (pnv-spi)
      /chip0.spi.0 (SSI)
      /xscom-spi[0] (memory-region)
  /chip[1] (power10_v2.0-pnv-chip)
    /pib_spic[0] (pnv-spi)
      /chip1.spi.0 (SSI)
      /xscom-spi[0] (memory-region)

Signed-off-by: Chalapathi V <chalapathi.v@linux.ibm.com>
Message-ID: <20250303141328.23991-4-chalapathi.v@linux.ibm.com>
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/qtest/pnv-spi-seeprom-test.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/qtest/pnv-spi-seeprom-test.c b/tests/qtest/pnv-spi-seeprom-test.c
index 57f20af76e..600493c425 100644
--- a/tests/qtest/pnv-spi-seeprom-test.c
+++ b/tests/qtest/pnv-spi-seeprom-test.c
@@ -92,7 +92,7 @@ static void test_spi_seeprom(const void *data)
     qts = qtest_initf("-machine powernv10 -smp 2,cores=2,"
                       "threads=1 -accel tcg,thread=single -nographic "
                       "-blockdev node-name=pib_spic2,driver=file,"
-                      "filename=%s -device 25csm04,bus=pnv-spi-bus.2,cs=0,"
+                      "filename=%s -device 25csm04,bus=chip0.spi.2,cs=0,"
                       "drive=pib_spic2", tmp_path);
     spi_seeprom_transaction(qts, chip);
     qtest_quit(qts);