ARM: dts: msm: Add 32-bit DT Overlay support
Add 32-bit DT OVERLAY support. Change-Id: Ied5b9f17d78116df478e7c4fbb91261712bd46e3 Signed-off-by: Tengfei Fan <tengfeif@codeaurora.org>
This commit is contained in:
@@ -10,6 +10,10 @@
|
|||||||
#
|
#
|
||||||
# Copyright (C) 1995-2001 by Russell King
|
# Copyright (C) 1995-2001 by Russell King
|
||||||
|
|
||||||
|
ifeq ($(CONFIG_BUILD_ARM64_DT_OVERLAY),y)
|
||||||
|
export DTC_FLAGS := -@
|
||||||
|
endif
|
||||||
|
|
||||||
LDFLAGS_vmlinux :=-p --no-undefined -X --pic-veneer
|
LDFLAGS_vmlinux :=-p --no-undefined -X --pic-veneer
|
||||||
ifeq ($(CONFIG_CPU_ENDIAN_BE8),y)
|
ifeq ($(CONFIG_CPU_ENDIAN_BE8),y)
|
||||||
LDFLAGS_vmlinux += --be8
|
LDFLAGS_vmlinux += --be8
|
||||||
@@ -314,6 +318,8 @@ ifeq ($(CONFIG_USE_OF),y)
|
|||||||
KBUILD_DTBS := dtbs
|
KBUILD_DTBS := dtbs
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
DTSSUBDIR := vendor/qcom
|
||||||
|
|
||||||
all: $(notdir $(KBUILD_IMAGE)) $(KBUILD_DTBS)
|
all: $(notdir $(KBUILD_IMAGE)) $(KBUILD_DTBS)
|
||||||
|
|
||||||
|
|
||||||
@@ -348,6 +354,7 @@ PHONY += dtbs dtbs_install
|
|||||||
|
|
||||||
dtbs: prepare scripts
|
dtbs: prepare scripts
|
||||||
$(Q)$(MAKE) $(build)=$(boot)/dts
|
$(Q)$(MAKE) $(build)=$(boot)/dts
|
||||||
|
$(foreach DIR, $(DTSSUBDIR), $(Q)$(MAKE) $(build)=$(boot)/dts/$(DIR) MACHINE=$(MACHINE) dtbs)
|
||||||
|
|
||||||
dtbs_install:
|
dtbs_install:
|
||||||
$(Q)$(MAKE) $(dtbinst)=$(boot)/dts
|
$(Q)$(MAKE) $(dtbinst)=$(boot)/dts
|
||||||
@@ -359,7 +366,10 @@ ifeq ($(CONFIG_VDSO),y)
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
zImage-dtb: vmlinux scripts dtbs
|
zImage-dtb: vmlinux scripts dtbs
|
||||||
$(Q)$(MAKE) $(build)=$(boot) MACHINE=$(MACHINE) $(boot)/$@
|
$(Q)$(MAKE) $(build)=$(boot) MACHINE=$(MACHINE) DTSSUBDIR=$(DTSSUBDIR) $(boot)/$@
|
||||||
|
|
||||||
|
Image-dtb: vmlinux scripts dtbs
|
||||||
|
$(Q)$(MAKE) $(build)=$(boot) MACHINE=$(MACHINE) DTSSUBDIR=$(DTSSUBDIR) $(boot)/$@
|
||||||
|
|
||||||
# We use MRPROPER_FILES and CLEAN_FILES now
|
# We use MRPROPER_FILES and CLEAN_FILES now
|
||||||
archclean:
|
archclean:
|
||||||
|
|||||||
@@ -33,10 +33,20 @@ targets := Image zImage xipImage bootpImage uImage
|
|||||||
DTB_NAMES := $(subst $\",,$(CONFIG_BUILD_ARM_APPENDED_DTB_IMAGE_NAMES))
|
DTB_NAMES := $(subst $\",,$(CONFIG_BUILD_ARM_APPENDED_DTB_IMAGE_NAMES))
|
||||||
ifneq ($(DTB_NAMES),)
|
ifneq ($(DTB_NAMES),)
|
||||||
DTB_LIST := $(addsuffix .dtb,$(DTB_NAMES))
|
DTB_LIST := $(addsuffix .dtb,$(DTB_NAMES))
|
||||||
else
|
|
||||||
DTB_LIST := $(dtb-y)
|
|
||||||
endif
|
|
||||||
DTB_OBJS := $(addprefix $(obj)/dts/,$(DTB_LIST))
|
DTB_OBJS := $(addprefix $(obj)/dts/,$(DTB_LIST))
|
||||||
|
else
|
||||||
|
# Use the same way as ARM64 does to have dtb files appended
|
||||||
|
# to kernel image.
|
||||||
|
# For dt overlay support, currently there isn't have any
|
||||||
|
# uniform list for dtb files. There is only one uniform list
|
||||||
|
# for overlay's dtbo files which is managered by dtbo-y. And
|
||||||
|
# dtb files are derived from each dtbo file's dtbo-base. so
|
||||||
|
# it use a simple way just to find all dtb files which
|
||||||
|
# generated during the build.
|
||||||
|
# Note that dtb obj directory will always be cleaned at the
|
||||||
|
# beginning of kernel build.
|
||||||
|
DTB_OBJS := $(shell find $(obj)/dts/ -name \*.dtb)
|
||||||
|
endif
|
||||||
|
|
||||||
ifeq ($(CONFIG_XIP_KERNEL),y)
|
ifeq ($(CONFIG_XIP_KERNEL),y)
|
||||||
|
|
||||||
|
|||||||
16
arch/arm/boot/dts/vendor/qcom/Makefile
vendored
Normal file
16
arch/arm/boot/dts/vendor/qcom/Makefile
vendored
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
# SPDX-License-Identifier: GPL-2.0-only
|
||||||
|
|
||||||
|
include $(srctree)/arch/arm64/boot/dts/vendor/qcom/Makefile
|
||||||
|
$(obj)/%.dtb: $(src)/../../../../../arm64/boot/dts/vendor/qcom/%.dts FORCE
|
||||||
|
$(call if_changed_dep,dtc)
|
||||||
|
|
||||||
|
ifeq ($(CONFIG_BUILD_ARM64_DT_OVERLAY),y)
|
||||||
|
$(obj)/%.dtbo:$(src)/../../../../../arm64/boot/dts/vendor/qcom/%.dts FORCE
|
||||||
|
$(call if_changed_dep,dtc)
|
||||||
|
$(call if_changed,dtbo_verify)
|
||||||
|
|
||||||
|
dtbs: $(addprefix $(obj)/,$(dtb-y)) $(addprefix $(obj)/,$(dtbo-y))
|
||||||
|
else
|
||||||
|
dtbs: $(addprefix $(obj)/,$(dtb-y))
|
||||||
|
endif
|
||||||
|
clean-files := *.dtb
|
||||||
Reference in New Issue
Block a user