diff --git a/arch/arm/dts/nord-ride-u-boot.dtsi b/arch/arm/dts/nord-ride-u-boot.dtsi index 66500a979e9d..fdc91473817a 100644 --- a/arch/arm/dts/nord-ride-u-boot.dtsi +++ b/arch/arm/dts/nord-ride-u-boot.dtsi @@ -15,6 +15,14 @@ #include +&xo_board_clk { + bootph-all; +}; + +&sleep_clk { + bootph-all; +}; + / { negcc: clock-controller@8900000 { compatible = "qcom,nord-negcc"; @@ -22,6 +30,7 @@ #clock-cells = <1>; #reset-cells = <1>; #power-domain-cells = <1>; + bootph-all; }; ufs_mem_phy: phy@1d40000 { @@ -38,11 +47,13 @@ #phy-cells = <0>; status = "okay"; + bootph-all; }; smem { compatible = "qcom,smem"; memory-region = <&smem_region>; + bootph-all; }; sram: sram@146d8000 { @@ -71,9 +82,14 @@ smem_region: smem-region@89b00000 { reg = <0x0 0x89b00000 0x0 0x400000>; no-map; + bootph-all; }; }; +&tlmm { + bootph-all; +}; + &ufs_mem_hc { compatible = "qcom,sa8797p-ufshc", "qcom,sa8255p-ufshc", @@ -101,6 +117,8 @@ phys = <&ufs_mem_phy>; phy-names = "ufsphy"; + + bootph-all; }; &uart4 { @@ -113,12 +131,14 @@ compatible = "qcom,sa8797p-geni-debug-uart", "qcom,sa8255p-geni-debug-uart", "qcom,geni-debug-uart"; + bootph-all; }; &qupv3_0 { compatible = "qcom,sa8797p-geni-se-qup", "qcom,sa8255p-geni-se-qup", "qcom,geni-se-qup"; + bootph-all; }; &qupv3_1 { diff --git a/scripts/Makefile.xpl b/scripts/Makefile.xpl index a3fd3e1375f7..23a19b72d9ec 100644 --- a/scripts/Makefile.xpl +++ b/scripts/Makefile.xpl @@ -256,6 +256,30 @@ MKIMAGEFLAGS_boot.bin = -T zynqmpimage -R $(srctree)/$(CONFIG_BOOT_INIT_FILE) \ -n "$(shell cd $(srctree); readlink -f $(CONFIG_PMUFW_INIT_FILE))" endif +ifeq ($(CONFIG_SPL_WRAPPER_ELF),y) +# Convert ELF to object file +OBJCOPYFLAGS_$(SPL_BIN).bin.o = -I binary -O elf64-littleaarch64 + +# Wrap the object file inside a ELF +QCOM_SPL_SOC = $(shell echo $(notdir "$(CONFIG_DEFAULT_DEVICE_TREE)") | cut -f1 -d-) +QCOM_SPL_WRAP_LDS = $(srctree)/arch/arm/mach-snapdragon/$(QCOM_SPL_SOC)-spl-wrap-elf.lds +LDFLAGS_$(SPL_BIN).wrap-elf = -T $(obj)/$(SPL_BIN).wrap-elf.lds + +ifeq ($(QCOM_SPL_SOC),nord) +LDFLAGS_$(SPL_BIN).wrap-elf += -z common-page-size=0x1000 -z max-page-size=0x1000 +endif + +$(obj)/$(SPL_BIN).wrap-elf.lds: $(QCOM_SPL_WRAP_LDS) FORCE + $(call if_changed_dep,cpp_lds) + +$(obj)/$(SPL_BIN).bin.o: $(obj)/$(SPL_BIN).bin $(obj)/$(SPL_BIN).wrap-elf.lds FORCE + $(call if_changed,objcopy) + +$(obj)/$(SPL_BIN).wrap-elf: $(obj)/$(SPL_BIN).bin.o FORCE + $(call if_changed,ld) + +endif + $(obj)/$(SPL_BIN)-align.bin: $(obj)/$(SPL_BIN).bin @dd if=$< of=$@ conv=sync bs=4 2>/dev/null; @@ -302,6 +326,10 @@ INPUTS-$(CONFIG_ARCH_ZYNQMP) += $(obj)/boot.bin INPUTS-$(CONFIG_ARCH_MEDIATEK) += $(obj)/u-boot-spl-mtk.bin +ifeq ($(CONFIG_ARCH_SNAPDRAGON),y) +INPUTS-$(CONFIG_SPL_WRAPPER_ELF) += $(obj)/u-boot-spl.wrap-elf +endif + all: $(INPUTS-y) quiet_cmd_cat = CAT $@