Martin Roth | 9231f0b | 2022-10-28 22:39:23 -0600 | [diff] [blame] | 1 | ## SPDX-License-Identifier: GPL-2.0-only |
Ravi Kumar Bokka | 0c9eb31 | 2021-03-31 08:04:13 +0530 | [diff] [blame] | 2 | ifeq ($(CONFIG_SOC_QUALCOMM_SC7280),y) |
| 3 | |
Ravi Kumar Bokka | 86b0609 | 2021-04-06 17:01:05 +0530 | [diff] [blame] | 4 | decompressor-y += decompressor.c |
| 5 | decompressor-y += mmu.c |
| 6 | decompressor-y += ../common/timer.c |
Ravi Kumar Bokka | 0c9eb31 | 2021-03-31 08:04:13 +0530 | [diff] [blame] | 7 | all-y += ../common/timer.c |
Taniya Das | e689378 | 2020-09-29 13:12:12 +0530 | [diff] [blame] | 8 | all-y += ../common/gpio.c |
Taniya Das | 3fe6c03 | 2021-02-11 15:58:29 +0530 | [diff] [blame] | 9 | all-y += ../common/clock.c |
| 10 | all-y += clock.c |
Taniya Das | 6b81bcd | 2022-07-04 21:02:31 +0530 | [diff] [blame] | 11 | all-y += socinfo.c |
Roja Rani Yarubandi | 04096b9 | 2020-09-25 20:05:05 +0530 | [diff] [blame] | 12 | all-y += ../common/spi.c |
| 13 | all-$(CONFIG_SC7280_QSPI) += ../common/qspi.c |
Rajesh Patil | 4f96b06 | 2021-06-22 15:00:33 +0530 | [diff] [blame] | 14 | all-y += ../common/qupv3_config.c |
| 15 | all-y += qcom_qup_se.c |
| 16 | all-y += ../common/qup_se_handler.c |
Rajesh Patil | 4744c6e | 2021-06-17 16:40:10 +0530 | [diff] [blame] | 17 | all-y += ../common/qupv3_spi.c |
Rajesh Patil | 7028c0e | 2021-06-16 14:11:15 +0530 | [diff] [blame] | 18 | all-y += ../common/qupv3_i2c.c |
Rajesh Patil | 4744c6e | 2021-06-17 16:40:10 +0530 | [diff] [blame] | 19 | all-y += ../common/qupv3_spi.c |
Ravi Kumar Bokka | 0c9eb31 | 2021-03-31 08:04:13 +0530 | [diff] [blame] | 20 | |
| 21 | ################################################################################ |
| 22 | bootblock-y += bootblock.c |
| 23 | bootblock-y += mmu.c |
Ravi Kumar Bokka | b01b476 | 2020-11-06 11:28:01 +0530 | [diff] [blame] | 24 | bootblock-$(CONFIG_DRIVERS_UART) += ../common/uart_bitbang.c |
Rajesh Patil | c003ea6 | 2021-06-18 09:16:01 +0530 | [diff] [blame] | 25 | |
| 26 | ################################################################################ |
| 27 | verstage-$(CONFIG_DRIVERS_UART) += ../common/qupv3_uart.c |
| 28 | |
Ravi Kumar Bokka | 0c9eb31 | 2021-03-31 08:04:13 +0530 | [diff] [blame] | 29 | ################################################################################ |
| 30 | romstage-y += cbmem.c |
Ravi Kumar Bokka | 5afeba3 | 2021-01-04 14:28:14 +0530 | [diff] [blame] | 31 | romstage-y += shrm_load_reset.c |
Sudheer Kumar Amrabadi | dfe817e | 2022-03-22 20:00:29 +0530 | [diff] [blame] | 32 | romstage-y += cpucp_load_reset.c |
Ravi Kumar Bokka | 0c9eb31 | 2021-03-31 08:04:13 +0530 | [diff] [blame] | 33 | romstage-y += ../common/qclib.c |
| 34 | romstage-y += ../common/mmu.c |
Kshitiz Godara | ba5df6d | 2022-06-30 18:31:48 +0530 | [diff] [blame] | 35 | romstage-y += ../common/watchdog.c |
Ravi Kumar Bokka | 0c9eb31 | 2021-03-31 08:04:13 +0530 | [diff] [blame] | 36 | romstage-y += mmu.c |
Ravi Kumar Bokka | 0cd6ab3 | 2021-07-05 21:11:27 +0530 | [diff] [blame] | 37 | romstage-y += ../common/usb/usb.c |
T Michael Turney | 730107e | 2022-01-19 18:27:47 -0800 | [diff] [blame] | 38 | romstage-y += carve_out.c |
Sudheer Kumar Amrabadi | 9620ddc | 2022-09-16 12:09:19 +0530 | [diff] [blame] | 39 | romstage-y += ../common/aop_load_reset.c |
Rajesh Patil | c003ea6 | 2021-06-18 09:16:01 +0530 | [diff] [blame] | 40 | romstage-$(CONFIG_DRIVERS_UART) += ../common/qupv3_uart.c |
Ravi Kumar Bokka | 0c9eb31 | 2021-03-31 08:04:13 +0530 | [diff] [blame] | 41 | |
| 42 | ################################################################################ |
| 43 | ramstage-y += soc.c |
T Michael Turney | 730107e | 2022-01-19 18:27:47 -0800 | [diff] [blame] | 44 | ramstage-y += carve_out.c |
Ravi Kumar Bokka | 0c9eb31 | 2021-03-31 08:04:13 +0530 | [diff] [blame] | 45 | ramstage-y += cbmem.c |
Rajesh Patil | c003ea6 | 2021-06-18 09:16:01 +0530 | [diff] [blame] | 46 | ramstage-$(CONFIG_DRIVERS_UART) += ../common/qupv3_uart.c |
Ravi Kumar Bokka | 0cd6ab3 | 2021-07-05 21:11:27 +0530 | [diff] [blame] | 47 | ramstage-y += ../common/usb/usb.c |
| 48 | ramstage-y += ../common/usb/snps_usb_phy.c |
| 49 | ramstage-y += ../common/usb/qmpv4_usb_phy.c |
Ravi Kumar Bokka | b0d48ed | 2021-01-21 02:54:48 +0530 | [diff] [blame] | 50 | ramstage-y += cpucp_load_reset.c |
Vinod Polimera | 4e93e94 | 2022-02-25 13:21:42 +0530 | [diff] [blame] | 51 | ramstage-$(CONFIG_MAINBOARD_DO_NATIVE_VGA_INIT) += display/edp_aux.c |
| 52 | ramstage-$(CONFIG_MAINBOARD_DO_NATIVE_VGA_INIT) += display/edp_ctrl.c |
| 53 | ramstage-$(CONFIG_MAINBOARD_DO_NATIVE_VGA_INIT) += display/edp_phy_7nm.c |
| 54 | ramstage-$(CONFIG_MAINBOARD_DO_NATIVE_VGA_INIT) += ../common/display/mdss.c |
| 55 | ramstage-$(CONFIG_MAINBOARD_DO_NATIVE_VGA_INIT) += display/disp.c |
Prasad Malisetty | 78298f5 | 2022-07-25 13:35:05 +0530 | [diff] [blame] | 56 | ramstage-$(CONFIG_PCI) += ../common/pcie_common.c |
| 57 | ramstage-$(CONFIG_PCI) += pcie.c |
Shelley Chen | 978b474 | 2023-01-11 16:10:07 -0800 | [diff] [blame] | 58 | ramstage-$(CONFIG_SDHCI_CONTROLLER) += sdhci.c ../common/storage/sdhci_msm.c |
Ravi Kumar Bokka | 0c9eb31 | 2021-03-31 08:04:13 +0530 | [diff] [blame] | 59 | |
| 60 | ################################################################################ |
| 61 | |
| 62 | CPPFLAGS_common += -Isrc/soc/qualcomm/sc7280/include |
| 63 | CPPFLAGS_common += -Isrc/soc/qualcomm/common/include |
| 64 | |
Shelley Chen | f095d15 | 2021-04-19 22:25:53 -0700 | [diff] [blame] | 65 | SC7280_BLOB := $(top)/3rdparty/qc_blobs/sc7280 |
Ravi Kumar Bokka | 0c9eb31 | 2021-03-31 08:04:13 +0530 | [diff] [blame] | 66 | |
| 67 | ################################################################################ |
Ravi Kumar Bokka | 8a48241 | 2020-11-24 15:52:26 +0530 | [diff] [blame] | 68 | BL31_MAKEARGS += PLAT=sc7280 |
| 69 | |
| 70 | ifeq ($(CONFIG_QC_SDI_ENABLE),y) |
| 71 | BL31_MAKEARGS += QTI_SDI_BUILD=1 |
| 72 | BL31_MAKEARGS += QTISECLIB_PATH=$(SC7280_BLOB)/qtiseclib/libqtisec_dbg.a |
| 73 | else |
| 74 | BL31_MAKEARGS += QTISECLIB_PATH=$(SC7280_BLOB)/qtiseclib/libqtisec.a |
| 75 | endif # CONFIG_QC_SDI_ENABLE |
| 76 | |
| 77 | ################################################################################ |
| 78 | ifeq ($(CONFIG_QC_SDI_ENABLE),y) |
| 79 | QCSDI_FILE := $(SC7280_BLOB)/boot/QcSdi.elf |
| 80 | QCSDI_CBFS := $(CONFIG_CBFS_PREFIX)/qcsdi |
| 81 | $(QCSDI_CBFS)-file := $(QCSDI_FILE) |
| 82 | $(QCSDI_CBFS)-type := stage |
| 83 | $(QCSDI_CBFS)-compression := $(CBFS_COMPRESS_FLAG) |
| 84 | cbfs-files-y += $(QCSDI_CBFS) |
| 85 | endif |
| 86 | |
| 87 | ################################################################################ |
Ravi Kumar Bokka | 0c9eb31 | 2021-03-31 08:04:13 +0530 | [diff] [blame] | 88 | QC_SEC_FILE := $(SC7280_BLOB)/qc_sec/qc_sec.mbn |
| 89 | $(objcbfs)/bootblock.bin: $(objcbfs)/bootblock.raw.elf |
| 90 | @util/qualcomm/createxbl.py --mbn_version 6 -f $(objcbfs)/bootblock.raw.elf \ |
| 91 | -x $(QC_SEC_FILE) -o $(objcbfs)/merged_bb_qcsec.mbn \ |
| 92 | -a 64 -d 64 -c 64 |
| 93 | @printf "\nqgpt.py 4K sector size\n" |
| 94 | @util/qualcomm/qgpt.py $(objcbfs)/merged_bb_qcsec.mbn \ |
| 95 | $(objcbfs)/bootblock.bin |
| 96 | |
Ravi Kumar Bokka | 86c5bcd | 2021-04-23 18:39:47 +0530 | [diff] [blame] | 97 | ################################################################################ |
| 98 | QCLIB_FILE := $(SC7280_BLOB)/boot/QcLib.elf |
| 99 | QCLIB_CBFS := $(CONFIG_CBFS_PREFIX)/qclib |
| 100 | $(QCLIB_CBFS)-file := $(QCLIB_FILE) |
| 101 | $(QCLIB_CBFS)-type := stage |
| 102 | $(QCLIB_CBFS)-compression := $(CBFS_PRERAM_COMPRESS_FLAG) |
| 103 | cbfs-files-y += $(QCLIB_CBFS) |
| 104 | |
| 105 | ################################################################################ |
| 106 | PMIC_FILE := $(SC7280_BLOB)/boot/Pmic.bin |
| 107 | PMIC_CBFS := $(CONFIG_CBFS_PREFIX)/pmiccfg |
| 108 | $(PMIC_CBFS)-file := $(PMIC_FILE) |
| 109 | $(PMIC_CBFS)-type := raw |
| 110 | $(PMIC_CBFS)-compression := $(CBFS_COMPRESS_FLAG) |
| 111 | cbfs-files-y += $(PMIC_CBFS) |
| 112 | |
| 113 | ################################################################################ |
| 114 | DCB_FILE := $(SC7280_BLOB)/boot/dcb.bin |
| 115 | DCB_CBFS := $(CONFIG_CBFS_PREFIX)/dcb |
| 116 | $(DCB_CBFS)-file := $(DCB_FILE) |
| 117 | $(DCB_CBFS)-type := raw |
| 118 | $(DCB_CBFS)-compression := $(CBFS_COMPRESS_FLAG) |
| 119 | cbfs-files-y += $(DCB_CBFS) |
| 120 | |
Rajesh Patil | 4f96b06 | 2021-06-22 15:00:33 +0530 | [diff] [blame] | 121 | ################################################################################ |
| 122 | UART_FW_FILE := $(SC7280_BLOB)/qup_fw/uart_fw.bin |
| 123 | UART_FW_CBFS := $(CONFIG_CBFS_PREFIX)/uart_fw |
| 124 | $(UART_FW_CBFS)-file := $(UART_FW_FILE) |
| 125 | $(UART_FW_CBFS)-type := raw |
Shelley Chen | cf390d9 | 2021-09-22 00:50:51 -0700 | [diff] [blame] | 126 | $(UART_FW_CBFS)-compression := $(CBFS_PRERAM_COMPRESS_FLAG) |
Rajesh Patil | 4f96b06 | 2021-06-22 15:00:33 +0530 | [diff] [blame] | 127 | cbfs-files-y += $(UART_FW_CBFS) |
| 128 | |
| 129 | ################################################################################ |
| 130 | SPI_FW_FILE := $(SC7280_BLOB)/qup_fw/spi_fw.bin |
| 131 | SPI_FW_CBFS := $(CONFIG_CBFS_PREFIX)/spi_fw |
| 132 | $(SPI_FW_CBFS)-file := $(SPI_FW_FILE) |
| 133 | $(SPI_FW_CBFS)-type := raw |
Shelley Chen | cf390d9 | 2021-09-22 00:50:51 -0700 | [diff] [blame] | 134 | $(SPI_FW_CBFS)-compression := $(CBFS_PRERAM_COMPRESS_FLAG) |
Rajesh Patil | 4f96b06 | 2021-06-22 15:00:33 +0530 | [diff] [blame] | 135 | cbfs-files-y += $(SPI_FW_CBFS) |
| 136 | |
| 137 | ################################################################################ |
| 138 | I2C_FW_FILE := $(SC7280_BLOB)/qup_fw/i2c_fw.bin |
| 139 | I2C_FW_CBFS := $(CONFIG_CBFS_PREFIX)/i2c_fw |
| 140 | $(I2C_FW_CBFS)-file := $(I2C_FW_FILE) |
| 141 | $(I2C_FW_CBFS)-type := raw |
Shelley Chen | cf390d9 | 2021-09-22 00:50:51 -0700 | [diff] [blame] | 142 | $(I2C_FW_CBFS)-compression := $(CBFS_PRERAM_COMPRESS_FLAG) |
Rajesh Patil | 4f96b06 | 2021-06-22 15:00:33 +0530 | [diff] [blame] | 143 | cbfs-files-y += $(I2C_FW_CBFS) |
| 144 | |
Ravi Kumar Bokka | 5afeba3 | 2021-01-04 14:28:14 +0530 | [diff] [blame] | 145 | ################################################################################ |
Ravi Kumar Bokka | 5fa09cb | 2021-10-21 20:18:12 +0530 | [diff] [blame] | 146 | AOP_FILE := $(SC7280_BLOB)/aop/aop.mbn |
| 147 | AOP_CBFS := $(CONFIG_CBFS_PREFIX)/aop |
| 148 | $(AOP_CBFS)-file := $(AOP_FILE) |
| 149 | $(AOP_CBFS)-type := payload |
| 150 | $(AOP_CBFS)-compression := $(CBFS_COMPRESS_FLAG) |
| 151 | cbfs-files-y += $(AOP_CBFS) |
| 152 | |
| 153 | ################################################################################ |
Ravi Kumar Bokka | b0d48ed | 2021-01-21 02:54:48 +0530 | [diff] [blame] | 154 | CPUCP_FILE := $(SC7280_BLOB)/cpucp/cpucp.elf |
| 155 | CPUCP_CBFS := $(CONFIG_CBFS_PREFIX)/cpucp |
| 156 | $(CPUCP_CBFS)-file := $(CPUCP_FILE) |
| 157 | $(CPUCP_CBFS)-type := payload |
| 158 | $(CPUCP_CBFS)-compression := $(CBFS_COMPRESS_FLAG) |
| 159 | cbfs-files-y += $(CPUCP_CBFS) |
| 160 | |
| 161 | ################################################################################ |
Ravi Kumar Bokka | 5afeba3 | 2021-01-04 14:28:14 +0530 | [diff] [blame] | 162 | SHRM_FILE := $(SC7280_BLOB)/shrm/shrm.elf |
| 163 | SHRM_CBFS := $(CONFIG_CBFS_PREFIX)/shrm |
| 164 | $(SHRM_CBFS)-file := $(SHRM_FILE) |
| 165 | $(SHRM_CBFS)-type := payload |
Shelley Chen | 9573c0e | 2021-10-07 23:09:36 -0700 | [diff] [blame] | 166 | $(SHRM_CBFS)-compression := $(CBFS_PRERAM_COMPRESS_FLAG) |
Ravi Kumar Bokka | 5afeba3 | 2021-01-04 14:28:14 +0530 | [diff] [blame] | 167 | cbfs-files-y += $(SHRM_CBFS) |
| 168 | |
Ravi Kumar Bokka | dcb2613 | 2021-07-24 21:17:29 +0530 | [diff] [blame] | 169 | ################################################################################ |
| 170 | GSI_FW_FILE := $(SC7280_BLOB)/qup_fw/gsi_fw.bin |
| 171 | GSI_FW_CBFS := $(CONFIG_CBFS_PREFIX)/gsi_fw |
| 172 | $(GSI_FW_CBFS)-file := $(GSI_FW_FILE) |
| 173 | $(GSI_FW_CBFS)-type := raw |
| 174 | $(GSI_FW_CBFS)-compression := $(CBFS_COMPRESS_FLAG) |
| 175 | cbfs-files-y += $(GSI_FW_CBFS) |
| 176 | |
Ravi Kumar Bokka | 0c9eb31 | 2021-03-31 08:04:13 +0530 | [diff] [blame] | 177 | endif |