summary refs log tree commit diff stats
path: root/include/hw/arm/bcm2835_peripherals.h
diff options
context:
space:
mode:
authorRayhan Faizel <rayhan.faizel@gmail.com>2024-01-30 03:48:08 +0530
committerPeter Maydell <peter.maydell@linaro.org>2024-02-02 13:51:59 +0000
commitf09c2b7ba9908714a3e2f1decd989462536cf731 (patch)
treea381c8fb67ab0f1f9470882b6a8e23b148707e03 /include/hw/arm/bcm2835_peripherals.h
parent28004fb741343b77b1044a0f01d27d8b36b59651 (diff)
downloadfocaccia-qemu-f09c2b7ba9908714a3e2f1decd989462536cf731.tar.gz
focaccia-qemu-f09c2b7ba9908714a3e2f1decd989462536cf731.zip
hw/arm: Connect SPI Controller to BCM2835
This patch will allow the SPI controller to be accessible from BCM2835 based
boards as SPI0. SPI driver is usually disabled by default and config.txt does
not work.

Instead, dtmerge can be used to apply spi=on on a bcm2835 dtb file.

Signed-off-by: Rayhan Faizel <rayhan.faizel@gmail.com>
Message-id: 20240129221807.2983148-3-rayhan.faizel@gmail.com
[PMM: indent tweak]
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'include/hw/arm/bcm2835_peripherals.h')
-rw-r--r--include/hw/arm/bcm2835_peripherals.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/hw/arm/bcm2835_peripherals.h b/include/hw/arm/bcm2835_peripherals.h
index d724a2fc28..0203bb79d8 100644
--- a/include/hw/arm/bcm2835_peripherals.h
+++ b/include/hw/arm/bcm2835_peripherals.h
@@ -31,6 +31,7 @@
 #include "hw/gpio/bcm2835_gpio.h"
 #include "hw/timer/bcm2835_systmr.h"
 #include "hw/usb/hcd-dwc2.h"
+#include "hw/ssi/bcm2835_spi.h"
 #include "hw/misc/unimp.h"
 #include "qom/object.h"
 
@@ -66,7 +67,7 @@ struct BCM2835PeripheralState {
     BCM2835GpioState gpio;
     Bcm2835ThermalState thermal;
     UnimplementedDeviceState i2s;
-    UnimplementedDeviceState spi[1];
+    BCM2835SPIState spi[1];
     UnimplementedDeviceState i2c[3];
     UnimplementedDeviceState otp;
     UnimplementedDeviceState dbus;