From df3935ed878029527ccbcce8562242ff68e5e604 Mon Sep 17 00:00:00 2001 From: Subrata Banik Date: Fri, 11 Apr 2025 04:44:26 +0000 Subject: [PATCH] soc/qualcomm/common: Avoid hardcoding SPI bus from QUP range The `spi_ctrlr_bus_map` defines the range of SPI bus numbers managed by different controllers. Previously, the generic `spi_qup_ctrlr` was hardcoded to manage buses 0 through 15. Modify the `.bus_end` value for the `spi_qup_ctrlr` entry to be `QUPV3_SE_MAX - 1`. TEST=Able to build google/herobrine. Change-Id: I7e9ec555a6d72d93bc23285e48eab52030978e1a Signed-off-by: Subrata Banik Reviewed-on: https://review.coreboot.org/c/coreboot/+/87270 Tested-by: build bot (Jenkins) Reviewed-by: Kapil Porwal --- src/soc/qualcomm/common/spi.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/soc/qualcomm/common/spi.c b/src/soc/qualcomm/common/spi.c index aee124dd59..3cc7681004 100644 --- a/src/soc/qualcomm/common/spi.c +++ b/src/soc/qualcomm/common/spi.c @@ -2,6 +2,7 @@ #include #include +#include #include #include @@ -29,7 +30,7 @@ const struct spi_ctrlr_buses spi_ctrlr_bus_map[] = { { .ctrlr = &spi_qup_ctrlr, .bus_start = 0, - .bus_end = 15, + .bus_end = QUPV3_SE_MAX - 1, }, };