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 |
Ravi Kumar Bokka | 0c9eb31 | 2021-03-31 08:04:13 +0530 | [diff] [blame] | 58 | |
| 59 | ################################################################################ |
| 60 | |
| 61 | CPPFLAGS_common += -Isrc/soc/qualcomm/sc7280/include |
| 62 | CPPFLAGS_common += -Isrc/soc/qualcomm/common/include |
| 63 | |
Shelley Chen | f095d15 | 2021-04-19 22:25:53 -0700 | [diff] [blame] | 64 | SC7280_BLOB := $(top)/3rdparty/qc_blobs/sc7280 |
Ravi Kumar Bokka | 0c9eb31 | 2021-03-31 08:04:13 +0530 | [diff] [blame] | 65 | |
| 66 | ################################################################################ |
Ravi Kumar Bokka | 8a48241 | 2020-11-24 15:52:26 +0530 | [diff] [blame] | 67 | BL31_MAKEARGS += PLAT=sc7280 |
| 68 | |
| 69 | ifeq ($(CONFIG_QC_SDI_ENABLE),y) |
| 70 | BL31_MAKEARGS += QTI_SDI_BUILD=1 |
| 71 | BL31_MAKEARGS += QTISECLIB_PATH=$(SC7280_BLOB)/qtiseclib/libqtisec_dbg.a |
| 72 | else |
| 73 | BL31_MAKEARGS += QTISECLIB_PATH=$(SC7280_BLOB)/qtiseclib/libqtisec.a |
| 74 | endif # CONFIG_QC_SDI_ENABLE |
| 75 | |
| 76 | ################################################################################ |
| 77 | ifeq ($(CONFIG_QC_SDI_ENABLE),y) |
| 78 | QCSDI_FILE := $(SC7280_BLOB)/boot/QcSdi.elf |
| 79 | QCSDI_CBFS := $(CONFIG_CBFS_PREFIX)/qcsdi |
| 80 | $(QCSDI_CBFS)-file := $(QCSDI_FILE) |
| 81 | $(QCSDI_CBFS)-type := stage |
| 82 | $(QCSDI_CBFS)-compression := $(CBFS_COMPRESS_FLAG) |
| 83 | cbfs-files-y += $(QCSDI_CBFS) |
| 84 | endif |
| 85 | |
| 86 | ################################################################################ |
Ravi Kumar Bokka | 0c9eb31 | 2021-03-31 08:04:13 +0530 | [diff] [blame] | 87 | QC_SEC_FILE := $(SC7280_BLOB)/qc_sec/qc_sec.mbn |
| 88 | $(objcbfs)/bootblock.bin: $(objcbfs)/bootblock.raw.elf |
| 89 | @util/qualcomm/createxbl.py --mbn_version 6 -f $(objcbfs)/bootblock.raw.elf \ |
| 90 | -x $(QC_SEC_FILE) -o $(objcbfs)/merged_bb_qcsec.mbn \ |
| 91 | -a 64 -d 64 -c 64 |
| 92 | @printf "\nqgpt.py 4K sector size\n" |
| 93 | @util/qualcomm/qgpt.py $(objcbfs)/merged_bb_qcsec.mbn \ |
| 94 | $(objcbfs)/bootblock.bin |
| 95 | |
Ravi Kumar Bokka | 86c5bcd | 2021-04-23 18:39:47 +0530 | [diff] [blame] | 96 | ################################################################################ |
| 97 | QCLIB_FILE := $(SC7280_BLOB)/boot/QcLib.elf |
| 98 | QCLIB_CBFS := $(CONFIG_CBFS_PREFIX)/qclib |
| 99 | $(QCLIB_CBFS)-file := $(QCLIB_FILE) |
| 100 | $(QCLIB_CBFS)-type := stage |
| 101 | $(QCLIB_CBFS)-compression := $(CBFS_PRERAM_COMPRESS_FLAG) |
| 102 | cbfs-files-y += $(QCLIB_CBFS) |
| 103 | |
| 104 | ################################################################################ |
| 105 | PMIC_FILE := $(SC7280_BLOB)/boot/Pmic.bin |
| 106 | PMIC_CBFS := $(CONFIG_CBFS_PREFIX)/pmiccfg |
| 107 | $(PMIC_CBFS)-file := $(PMIC_FILE) |
| 108 | $(PMIC_CBFS)-type := raw |
| 109 | $(PMIC_CBFS)-compression := $(CBFS_COMPRESS_FLAG) |
| 110 | cbfs-files-y += $(PMIC_CBFS) |
| 111 | |
| 112 | ################################################################################ |
| 113 | DCB_FILE := $(SC7280_BLOB)/boot/dcb.bin |
| 114 | DCB_CBFS := $(CONFIG_CBFS_PREFIX)/dcb |
| 115 | $(DCB_CBFS)-file := $(DCB_FILE) |
| 116 | $(DCB_CBFS)-type := raw |
| 117 | $(DCB_CBFS)-compression := $(CBFS_COMPRESS_FLAG) |
| 118 | cbfs-files-y += $(DCB_CBFS) |
| 119 | |
Rajesh Patil | 4f96b06 | 2021-06-22 15:00:33 +0530 | [diff] [blame] | 120 | ################################################################################ |
| 121 | UART_FW_FILE := $(SC7280_BLOB)/qup_fw/uart_fw.bin |
| 122 | UART_FW_CBFS := $(CONFIG_CBFS_PREFIX)/uart_fw |
| 123 | $(UART_FW_CBFS)-file := $(UART_FW_FILE) |
| 124 | $(UART_FW_CBFS)-type := raw |
Shelley Chen | cf390d9 | 2021-09-22 00:50:51 -0700 | [diff] [blame] | 125 | $(UART_FW_CBFS)-compression := $(CBFS_PRERAM_COMPRESS_FLAG) |
Rajesh Patil | 4f96b06 | 2021-06-22 15:00:33 +0530 | [diff] [blame] | 126 | cbfs-files-y += $(UART_FW_CBFS) |
| 127 | |
| 128 | ################################################################################ |
| 129 | SPI_FW_FILE := $(SC7280_BLOB)/qup_fw/spi_fw.bin |
| 130 | SPI_FW_CBFS := $(CONFIG_CBFS_PREFIX)/spi_fw |
| 131 | $(SPI_FW_CBFS)-file := $(SPI_FW_FILE) |
| 132 | $(SPI_FW_CBFS)-type := raw |
Shelley Chen | cf390d9 | 2021-09-22 00:50:51 -0700 | [diff] [blame] | 133 | $(SPI_FW_CBFS)-compression := $(CBFS_PRERAM_COMPRESS_FLAG) |
Rajesh Patil | 4f96b06 | 2021-06-22 15:00:33 +0530 | [diff] [blame] | 134 | cbfs-files-y += $(SPI_FW_CBFS) |
| 135 | |
| 136 | ################################################################################ |
| 137 | I2C_FW_FILE := $(SC7280_BLOB)/qup_fw/i2c_fw.bin |
| 138 | I2C_FW_CBFS := $(CONFIG_CBFS_PREFIX)/i2c_fw |
| 139 | $(I2C_FW_CBFS)-file := $(I2C_FW_FILE) |
| 140 | $(I2C_FW_CBFS)-type := raw |
Shelley Chen | cf390d9 | 2021-09-22 00:50:51 -0700 | [diff] [blame] | 141 | $(I2C_FW_CBFS)-compression := $(CBFS_PRERAM_COMPRESS_FLAG) |
Rajesh Patil | 4f96b06 | 2021-06-22 15:00:33 +0530 | [diff] [blame] | 142 | cbfs-files-y += $(I2C_FW_CBFS) |
| 143 | |
Ravi Kumar Bokka | 5afeba3 | 2021-01-04 14:28:14 +0530 | [diff] [blame] | 144 | ################################################################################ |
Ravi Kumar Bokka | 5fa09cb | 2021-10-21 20:18:12 +0530 | [diff] [blame] | 145 | AOP_FILE := $(SC7280_BLOB)/aop/aop.mbn |
| 146 | AOP_CBFS := $(CONFIG_CBFS_PREFIX)/aop |
| 147 | $(AOP_CBFS)-file := $(AOP_FILE) |
| 148 | $(AOP_CBFS)-type := payload |
| 149 | $(AOP_CBFS)-compression := $(CBFS_COMPRESS_FLAG) |
| 150 | cbfs-files-y += $(AOP_CBFS) |
| 151 | |
| 152 | ################################################################################ |
Ravi Kumar Bokka | b0d48ed | 2021-01-21 02:54:48 +0530 | [diff] [blame] | 153 | CPUCP_FILE := $(SC7280_BLOB)/cpucp/cpucp.elf |
| 154 | CPUCP_CBFS := $(CONFIG_CBFS_PREFIX)/cpucp |
| 155 | $(CPUCP_CBFS)-file := $(CPUCP_FILE) |
| 156 | $(CPUCP_CBFS)-type := payload |
| 157 | $(CPUCP_CBFS)-compression := $(CBFS_COMPRESS_FLAG) |
| 158 | cbfs-files-y += $(CPUCP_CBFS) |
| 159 | |
| 160 | ################################################################################ |
Ravi Kumar Bokka | 5afeba3 | 2021-01-04 14:28:14 +0530 | [diff] [blame] | 161 | SHRM_FILE := $(SC7280_BLOB)/shrm/shrm.elf |
| 162 | SHRM_CBFS := $(CONFIG_CBFS_PREFIX)/shrm |
| 163 | $(SHRM_CBFS)-file := $(SHRM_FILE) |
| 164 | $(SHRM_CBFS)-type := payload |
Shelley Chen | 9573c0e | 2021-10-07 23:09:36 -0700 | [diff] [blame] | 165 | $(SHRM_CBFS)-compression := $(CBFS_PRERAM_COMPRESS_FLAG) |
Ravi Kumar Bokka | 5afeba3 | 2021-01-04 14:28:14 +0530 | [diff] [blame] | 166 | cbfs-files-y += $(SHRM_CBFS) |
| 167 | |
Ravi Kumar Bokka | dcb2613 | 2021-07-24 21:17:29 +0530 | [diff] [blame] | 168 | ################################################################################ |
| 169 | GSI_FW_FILE := $(SC7280_BLOB)/qup_fw/gsi_fw.bin |
| 170 | GSI_FW_CBFS := $(CONFIG_CBFS_PREFIX)/gsi_fw |
| 171 | $(GSI_FW_CBFS)-file := $(GSI_FW_FILE) |
| 172 | $(GSI_FW_CBFS)-type := raw |
| 173 | $(GSI_FW_CBFS)-compression := $(CBFS_COMPRESS_FLAG) |
| 174 | cbfs-files-y += $(GSI_FW_CBFS) |
| 175 | |
Ravi Kumar Bokka | 0c9eb31 | 2021-03-31 08:04:13 +0530 | [diff] [blame] | 176 | endif |