Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

MIPS: loongson: Add built-in DTB support

Since the current bootloader for Loongson-1 does not support FDT,
introduce CONFIG_BUILTIN_DTB_NAME to enable a built-in DTB.

Signed-off-by: Keguang Zhang <keguang.zhang@gmail.com>
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>

authored by

Keguang Zhang and committed by
Thomas Bogendoerfer
ec7c2a10 11741215

+13
+5
arch/mips/boot/dts/loongson/Makefile
··· 1 1 # SPDX-License-Identifier: GPL-2.0 2 + 3 + ifneq ($(CONFIG_BUILTIN_DTB_NAME),) 4 + dtb-y := $(addsuffix .dtb, $(CONFIG_BUILTIN_DTB_NAME)) 5 + else 2 6 dtb-$(CONFIG_MACH_LOONGSON64) += loongson64_2core_2k1000.dtb 3 7 dtb-$(CONFIG_MACH_LOONGSON64) += loongson64c_4core_ls7a.dtb 4 8 dtb-$(CONFIG_MACH_LOONGSON64) += loongson64c_4core_rs780e.dtb ··· 14 10 dtb-$(CONFIG_MACH_LOONGSON32) += ls1b-demo.dtb 15 11 dtb-$(CONFIG_MACH_LOONGSON32) += lsgz_1b_dev.dtb 16 12 dtb-$(CONFIG_MACH_LOONGSON32) += smartloong-1c.dtb 13 + endif
+8
arch/mips/loongson32/Kconfig
··· 36 36 endchoice 37 37 38 38 endif # MACH_LOONGSON32 39 + 40 + config BUILTIN_DTB_NAME 41 + string "Source file for built-in DTB" 42 + depends on BUILTIN_DTB 43 + help 44 + Base name (without suffix, relative to arch/mips/boot/dts/loongson) 45 + for the DTS file that will be used to produce the DTB linked into 46 + the kernel.