Re: [PATCH 16/16] spacemit: k1: rename device tree prefix from "k1-" to "k1_"
Heinrich Schuchardt
xypron.glpk at gmx.de
Wed Apr 29 21:51:59 CEST 2026
Am 29. April 2026 21:42:04 MESZ schrieb Conor Dooley <conor at kernel.org>:
>On Wed, Apr 22, 2026 at 10:31:12AM -0400, Raymond Mao wrote:
>> From: Raymond Mao <raymond.mao at riscstar.com>
>>
>> This change replaces the hyphen ("-") in the DTS prefix with an
>> underscore ("_") for consistency with other prefixes in the
>> Spacemit K1 SoC platform.
>
>Doesn't this inconsistency only exist because you added files that made
>it inconsistent? Using hyphens is the norm anyway, right?
The kernel uses hyphens. We should not deviate from Linux. In the long term we want to use the upstream Linux device-trees in U-Boot.
Renaming in Linux should also be avoided.
Best regards
Heinrich
>
>>
>> Signed-off-by: Raymond Mao <raymond.mao at riscstar.com>
>> ---
>> arch/riscv/dts/Makefile | 2 +-
>> arch/riscv/dts/{k1-bananapi-f3.dts => k1_bananapi-f3.dts} | 2 +-
>> arch/riscv/dts/{k1-muse-pi-pro.dts => k1_muse-pi-pro.dts} | 0
>> arch/riscv/dts/{k1-pinctrl.dtsi => k1_pinctrl.dtsi} | 0
>> arch/riscv/dts/{k1-spl.dts => k1_spl.dts} | 0
>> board/spacemit/k1/spl.c | 2 +-
>> configs/spacemit_k1_defconfig | 4 ++--
>> 7 files changed, 5 insertions(+), 5 deletions(-)
>> rename arch/riscv/dts/{k1-bananapi-f3.dts => k1_bananapi-f3.dts} (99%)
>> rename arch/riscv/dts/{k1-muse-pi-pro.dts => k1_muse-pi-pro.dts} (100%)
>> rename arch/riscv/dts/{k1-pinctrl.dtsi => k1_pinctrl.dtsi} (100%)
>> rename arch/riscv/dts/{k1-spl.dts => k1_spl.dts} (100%)
>>
>> diff --git a/arch/riscv/dts/Makefile b/arch/riscv/dts/Makefile
>> index 22b62e25d4d..3827ff72215 100644
>> --- a/arch/riscv/dts/Makefile
>> +++ b/arch/riscv/dts/Makefile
>> @@ -9,7 +9,7 @@ dtb-$(CONFIG_TARGET_LICHEERV_NANO) += sg2002-licheerv-nano-b.dtb
>> dtb-$(CONFIG_TARGET_QEMU_VIRT) += qemu-virt32.dtb qemu-virt64.dtb
>> dtb-$(CONFIG_TARGET_OPENPITON_RISCV64) += openpiton-riscv64.dtb
>> dtb-$(CONFIG_TARGET_SIPEED_MAIX) += k210-maix-bit.dtb
>> -dtb-$(CONFIG_TARGET_SPACEMIT_K1) += k1-bananapi-f3.dtb k1-muse-pi-pro.dtb k1-spl.dtb
>> +dtb-$(CONFIG_TARGET_SPACEMIT_K1) += k1_bananapi-f3.dtb k1_muse-pi-pro.dtb k1_spl.dtb
>> dtb-$(CONFIG_TARGET_XILINX_MBV) += xilinx-mbv32.dtb
>> dtb-$(CONFIG_TARGET_XILINX_MBV) += xilinx-mbv64.dtb
>> dtb-$(CONFIG_TARGET_XILINX_MBV) += xilinx-binman.dtb
>> diff --git a/arch/riscv/dts/k1-bananapi-f3.dts b/arch/riscv/dts/k1_bananapi-f3.dts
>> similarity index 99%
>> rename from arch/riscv/dts/k1-bananapi-f3.dts
>> rename to arch/riscv/dts/k1_bananapi-f3.dts
>> index ea11029c182..bcb5be5f1bc 100644
>> --- a/arch/riscv/dts/k1-bananapi-f3.dts
>> +++ b/arch/riscv/dts/k1_bananapi-f3.dts
>> @@ -5,7 +5,7 @@
>>
>> #include "k1.dtsi"
>> #include "binman.dtsi"
>> -#include "k1-pinctrl.dtsi"
>> +#include "k1_pinctrl.dtsi"
>>
>> / {
>> model = "Banana Pi BPI-F3";
>> diff --git a/arch/riscv/dts/k1-muse-pi-pro.dts b/arch/riscv/dts/k1_muse-pi-pro.dts
>> similarity index 100%
>> rename from arch/riscv/dts/k1-muse-pi-pro.dts
>> rename to arch/riscv/dts/k1_muse-pi-pro.dts
>> diff --git a/arch/riscv/dts/k1-pinctrl.dtsi b/arch/riscv/dts/k1_pinctrl.dtsi
>> similarity index 100%
>> rename from arch/riscv/dts/k1-pinctrl.dtsi
>> rename to arch/riscv/dts/k1_pinctrl.dtsi
>> diff --git a/arch/riscv/dts/k1-spl.dts b/arch/riscv/dts/k1_spl.dts
>> similarity index 100%
>> rename from arch/riscv/dts/k1-spl.dts
>> rename to arch/riscv/dts/k1_spl.dts
>> diff --git a/board/spacemit/k1/spl.c b/board/spacemit/k1/spl.c
>> index 2556dfe047a..b8e1327dc57 100644
>> --- a/board/spacemit/k1/spl.c
>> +++ b/board/spacemit/k1/spl.c
>> @@ -374,7 +374,7 @@ int board_fit_config_name_match(const char *name)
>>
>> memset(fdt_name, 0, I2C_BUF_SIZE);
>> if (!strncmp(product_name, "k1-x_", 5)) {
>> - snprintf(fdt_name, I2C_BUF_SIZE, "%s-%s", "k1",
>> + snprintf(fdt_name, I2C_BUF_SIZE, "%s_%s", "k1",
>> &product_name[5]);
>> }
>> for (i = 0; i < I2C_BUF_SIZE; i++) {
>> diff --git a/configs/spacemit_k1_defconfig b/configs/spacemit_k1_defconfig
>> index 13f055cdf53..ddd0c959c12 100644
>> --- a/configs/spacemit_k1_defconfig
>> +++ b/configs/spacemit_k1_defconfig
>> @@ -3,8 +3,8 @@ CONFIG_SYS_MALLOC_LEN=0x1000000
>> CONFIG_NR_DRAM_BANKS=2
>> CONFIG_HAS_CUSTOM_SYS_INIT_SP_ADDR=y
>> CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0x1000000
>> -CONFIG_DEFAULT_DEVICE_TREE="k1-spl"
>> -CONFIG_OF_LIST="k1-bananapi-f3 k1-muse-pi-pro"
>> +CONFIG_DEFAULT_DEVICE_TREE="k1_spl"
>> +CONFIG_OF_LIST="k1_bananapi-f3 k1_muse-pi-pro"
>> CONFIG_SPL=y
>> CONFIG_SPL_TEXT_BASE=0xc0801000
>> CONFIG_SPL_MAX_SIZE=0x33000
>> --
>> 2.25.1
>>
More information about the U-Boot
mailing list