diff mbox series

riscv: fix build failure with Canaan K210 SoC

Message ID 20210113021501.363913-1-damien.lemoal@wdc.com (mailing list archive)
State New, archived
Headers show
Series riscv: fix build failure with Canaan K210 SoC | expand

Commit Message

Damien Le Moal Jan. 13, 2021, 2:15 a.m. UTC
Fix riscv dts main Makefile to avoid build failures when
CONFIG_SOC_CANAAN is selected but CONFIG_SOC_CANAAN_K210_DTB_BUILTIN is
not set. In this case, the SoC device tree should not be built.
Avoid the failure by changing the canaan subdir inclusion based on the
CONFIG_SOC_CANAAN_K210_DTB_BUILTIN configuration option value instead
of on the value of the CONFIG_SOC_CANAAN configuration option.

Reported-by: kernel test robot <lkp@intel.com>
Fixes: 3c54e3125dcd ("riscv: Use vendor name for K210 SoC support")
Signed-off-by: Damien Le Moal <damien.lemoal@wdc.com>
---
 arch/riscv/boot/dts/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/arch/riscv/boot/dts/Makefile b/arch/riscv/boot/dts/Makefile
index 4da40691c55b..406740a5da28 100644
--- a/arch/riscv/boot/dts/Makefile
+++ b/arch/riscv/boot/dts/Makefile
@@ -1,5 +1,5 @@ 
 # SPDX-License-Identifier: GPL-2.0
 subdir-y += sifive
-subdir-$(CONFIG_SOC_CANAAN) += canaan
+subdir-$(SOC_CANAAN_K210_DTB_BUILTIN) += canaan
 
 obj-$(CONFIG_BUILTIN_DTB) := $(addsuffix /, $(subdir-y))