GENI QUP firmware loading is normally expected to be completed by a previous boot stage and is not required in production U-Boot builds. Add CONFIG_QCOM_GENI_FW_LOAD to make the late firmware loading path optional and disable it by default.
The option can be enabled for engineering and bring-up builds where loading GENI firmware from U-Boot is required. Signed-off-by: Aswin Murugan <[email protected]> --- configs/qcom_defconfig | 1 + drivers/misc/Kconfig | 9 +++++++++ drivers/misc/qcom_geni.c | 2 ++ 3 files changed, 12 insertions(+) diff --git a/configs/qcom_defconfig b/configs/qcom_defconfig index c52f619850d..9498583b97c 100644 --- a/configs/qcom_defconfig +++ b/configs/qcom_defconfig @@ -99,6 +99,7 @@ CONFIG_QCOM_HYP_SMMU=y CONFIG_MISC=y CONFIG_NVMEM=y CONFIG_QCOM_GENI=y +# CONFIG_QCOM_GENI_FW_LOAD is not set CONFIG_I2C_EEPROM=y CONFIG_MMC_SDHCI=y CONFIG_MMC_SDHCI_ADMA=y diff --git a/drivers/misc/Kconfig b/drivers/misc/Kconfig index 44415f24ae1..8320fbe28e0 100644 --- a/drivers/misc/Kconfig +++ b/drivers/misc/Kconfig @@ -93,6 +93,15 @@ config QCOM_GENI for providing a common interface for various peripherals like UART, I2C, SPI, etc. +config QCOM_GENI_FW_LOAD + bool "Load Qualcomm GENI peripheral firmware at late init" + depends on QCOM_GENI + default y + help + Load firmware for GENI peripherals from the firmware partition + at late init. Disable if no GENI peripheral needs firmware + loading. + config ROCKCHIP_EFUSE bool "Rockchip e-fuse support" depends on MISC diff --git a/drivers/misc/qcom_geni.c b/drivers/misc/qcom_geni.c index a62ae6a2478..b5c2a511ae7 100644 --- a/drivers/misc/qcom_geni.c +++ b/drivers/misc/qcom_geni.c @@ -563,7 +563,9 @@ static int qcom_geni_fw_initialise(void) return 0; } +#if IS_ENABLED(CONFIG_QCOM_GENI_FW_LOAD) EVENT_SPY_SIMPLE(EVT_LAST_STAGE_INIT, qcom_geni_fw_initialise); +#endif static const struct udevice_id geni_ids[] = { { .compatible = "qcom,geni-se-qup" }, -- 2.34.1
