diff --git a/arch/Kconfig b/arch/Kconfig index 1709d40e97e09922f31b5a201b381667ce1600ad..ec120139cba9619a5fa971ceaee2add268325f89 100644 --- a/arch/Kconfig +++ b/arch/Kconfig @@ -55,6 +55,7 @@ config MIPS select HAVE_PRIVATE_LIBGCC select HAVE_GENERIC_BOARD select SYS_GENERIC_BOARD + select SUPPORT_OF_CONTROL config NDS32 bool "NDS32 architecture" diff --git a/arch/mips/config.mk b/arch/mips/config.mk index 415ec8afd2d7016f7d87379a1ab491a3907644e9..b78d4953ba215c0a8a11fa1884b7bb521c8e0ac0 100644 --- a/arch/mips/config.mk +++ b/arch/mips/config.mk @@ -72,6 +72,7 @@ PF_ABICALLS := -mabicalls PF_PIC := -fpic PF_PIE := -pie PF_OBJCOPY := -j .got -j .u_boot_list -j .rel.dyn -j .padding +PF_OBJCOPY += -j .dtb.init.rodata endif PLATFORM_CPPFLAGS += -G 0 $(PF_ABICALLS) $(PF_PIC) diff --git a/arch/mips/dts/.gitignore b/arch/mips/dts/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..b60ed208c779e02006759c98b65724a7e1137d8f --- /dev/null +++ b/arch/mips/dts/.gitignore @@ -0,0 +1 @@ +*.dtb diff --git a/arch/mips/dts/Makefile b/arch/mips/dts/Makefile new file mode 100644 index 0000000000000000000000000000000000000000..47b6eb50c35a5574f20162ca524540b4dc4c8ebe --- /dev/null +++ b/arch/mips/dts/Makefile @@ -0,0 +1,16 @@ +# +# SPDX-License-Identifier: GPL-2.0+ +# + +dtb-y += + +targets += $(dtb-y) + +# Add any required device tree compiler flags here +DTC_FLAGS += + +PHONY += dtbs +dtbs: $(addprefix $(obj)/, $(dtb-y)) + @: + +clean-files := *.dtb diff --git a/arch/mips/dts/include/dt-bindings b/arch/mips/dts/include/dt-bindings new file mode 120000 index 0000000000000000000000000000000000000000..0cecb3d08054bad387b1883e90f896cca16e2ec1 --- /dev/null +++ b/arch/mips/dts/include/dt-bindings @@ -0,0 +1 @@ +../../../../include/dt-bindings \ No newline at end of file diff --git a/arch/mips/dts/skeleton.dtsi b/arch/mips/dts/skeleton.dtsi new file mode 100644 index 0000000000000000000000000000000000000000..24ee6c3e7314436827e9c5d5d8f7eb768c3fe31e --- /dev/null +++ b/arch/mips/dts/skeleton.dtsi @@ -0,0 +1,23 @@ +/* + * Skeleton device tree; the bare minimum needed to boot; just include and + * add a compatible value. The bootloader will typically populate the memory + * node. + * + * SPDX-License-Identifier: GPL-2.0+ + */ + +/ { + #address-cells = <1>; + #size-cells = <1>; + + chosen { + }; + + aliases { + }; + + memory { + device_type = "memory"; + reg = <0 0>; + }; +}; diff --git a/dts/Makefile b/dts/Makefile index d3122aa3b96eeaa8820300060c958bcb5cf1d6dd..c4ac153ef3602bf6f2a66128d3bb63a3ffbcb416 100644 --- a/dts/Makefile +++ b/dts/Makefile @@ -45,4 +45,4 @@ dtbs: $(obj)/dt.dtb clean-files := dt.dtb.S # Let clean descend into dts directories -subdir- += ../arch/arm/dts ../arch/microblaze/dts ../arch/sandbox/dts ../arch/x86/dts +subdir- += ../arch/arm/dts ../arch/microblaze/dts ../arch/mips/dts ../arch/sandbox/dts ../arch/x86/dts