From abc87d533d327cc23aafde79aefe1ebdd9c2d85b Mon Sep 17 00:00:00 2001 From: Kapil Porwal Date: Mon, 17 Nov 2025 23:24:17 +0530 Subject: [PATCH] mb/google/bluey: Introduce config to specify absence of USB-A port This commit introduces the MAINBOARD_NO_USB_A_PORT Kconfig option to allow boards derived from the 'bluey' base to specify when they do not include a physical USB Type-A receptacle. For boards like 'Quartz' which are Type-C only, this configuration prevents attempts to initialize the USB-A retimer (which connects via QUPV3_0_SE1 I2C bus) during the mainboard initialization sequence. Skipping this unnecessary initialization avoids potential bus errors on Type-C-only devices. Key changes: - Define new Kconfig option MAINBOARD_NO_USB_A_PORT. - Select MAINBOARD_NO_USB_A_PORT for BOARD_GOOGLE_QUARTZ. - In mainboard.c, conditionally execute the USB-A retimer initialization based on the new configuration option. BUG=b:445441291 TEST=Build and boot to Google/Quenbi. Change-Id: Ia02092100c4e8c46106aff30db21461781d66419 Signed-off-by: Kapil Porwal Reviewed-on: https://review.coreboot.org/c/coreboot/+/90075 Reviewed-by: Subrata Banik Tested-by: build bot (Jenkins) --- src/mainboard/google/bluey/Kconfig | 7 +++++++ src/mainboard/google/bluey/mainboard.c | 3 ++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/src/mainboard/google/bluey/Kconfig b/src/mainboard/google/bluey/Kconfig index 0f5e8c3950..53f6de67d8 100644 --- a/src/mainboard/google/bluey/Kconfig +++ b/src/mainboard/google/bluey/Kconfig @@ -54,6 +54,7 @@ config BOARD_GOOGLE_QUENBIH config BOARD_GOOGLE_QUARTZ select BOARD_GOOGLE_MODEL_QUARTZ select SOC_QUALCOMM_HAMOA + select MAINBOARD_NO_USB_A_PORT if BOARD_GOOGLE_BLUEY_COMMON @@ -87,6 +88,12 @@ config MAINBOARD_HAS_SD_CONTROLLER help Enable this option if your mainboard is equipped with SD card controller. +config MAINBOARD_NO_USB_A_PORT + bool + default n + help + Enable this option if your mainboard is not equipped with USB-A port. + config MAINBOARD_HAS_GOOGLE_TPM bool default n diff --git a/src/mainboard/google/bluey/mainboard.c b/src/mainboard/google/bluey/mainboard.c index 6517842b66..92115f5464 100644 --- a/src/mainboard/google/bluey/mainboard.c +++ b/src/mainboard/google/bluey/mainboard.c @@ -100,7 +100,8 @@ static void mainboard_init(struct device *dev) qupv3_se_fw_load_and_init(QUPV3_1_SE0, SE_PROTOCOL_I2C, MIXED); /* Touch I2C */ qupv3_se_fw_load_and_init(QUPV3_1_SE6, SE_PROTOCOL_UART, FIFO); /* BT UART */ qupv3_se_fw_load_and_init(QUPV3_0_SE0, SE_PROTOCOL_I2C, MIXED); /* Trackpad I2C */ - qupv3_se_fw_load_and_init(QUPV3_0_SE1, SE_PROTOCOL_I2C, MIXED); /* USB-A retimer */ + if (!CONFIG(MAINBOARD_NO_USB_A_PORT)) + qupv3_se_fw_load_and_init(QUPV3_0_SE1, SE_PROTOCOL_I2C, MIXED); /* USB-A retimer */ if (CONFIG(MAINBOARD_HAS_FINGERPRINT_VIA_SPI)) qupv3_se_fw_load_and_init(QUPV3_2_SE2, SE_PROTOCOL_SPI, MIXED); /* Fingerprint SPI */