devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] openrisc: migrate to the generic rule for built-in DTB
@ 2024-12-22  0:23 Masahiro Yamada
  2024-12-24 20:21 ` Stafford Horne
  0 siblings, 1 reply; 2+ messages in thread
From: Masahiro Yamada @ 2024-12-22  0:23 UTC (permalink / raw)
  To: Jonas Bonn, Stefan Kristiansson, Stafford Horne, linux-openrisc
  Cc: linux-kernel, Masahiro Yamada, Conor Dooley, Gabriel Somlo,
	Joel Stanley, Karol Gugala, Krzysztof Kozlowski, Mateusz Holenko,
	Rob Herring, devicetree

Commit 654102df2ac2 ("kbuild: add generic support for built-in boot
DTBs") introduced generic support for built-in DTBs.

Select GENERIC_BUILTIN_DTB to use the generic rule.

To keep consistency across architectures, this commit also renames
CONFIG_OPENRISC_BUILTIN_DTB_NAME to CONFIG_BUILTIN_DTB_NAME.

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
---

 arch/openrisc/Kbuild                       | 1 -
 arch/openrisc/Kconfig                      | 3 ++-
 arch/openrisc/boot/dts/Makefile            | 2 +-
 arch/openrisc/configs/or1klitex_defconfig  | 2 +-
 arch/openrisc/configs/or1ksim_defconfig    | 2 +-
 arch/openrisc/configs/simple_smp_defconfig | 2 +-
 6 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/arch/openrisc/Kbuild b/arch/openrisc/Kbuild
index b0b0f2b03f87..70bdb24ff204 100644
--- a/arch/openrisc/Kbuild
+++ b/arch/openrisc/Kbuild
@@ -1,6 +1,5 @@
 # SPDX-License-Identifier: GPL-2.0
 obj-y += lib/ kernel/ mm/
-obj-y += boot/dts/
 
 # for cleaning
 subdir- += boot
diff --git a/arch/openrisc/Kconfig b/arch/openrisc/Kconfig
index 3279ef457c57..3d053e0b59f4 100644
--- a/arch/openrisc/Kconfig
+++ b/arch/openrisc/Kconfig
@@ -10,6 +10,7 @@ config OPENRISC
 	select ARCH_HAS_DMA_SET_UNCACHED
 	select ARCH_HAS_DMA_CLEAR_UNCACHED
 	select ARCH_HAS_SYNC_DMA_FOR_DEVICE
+	select GENERIC_BUILTIN_DTB
 	select COMMON_CLK
 	select OF
 	select OF_EARLY_FLATTREE
@@ -92,7 +93,7 @@ config DCACHE_WRITETHROUGH
 
 	  If unsure say N here
 
-config OPENRISC_BUILTIN_DTB
+config BUILTIN_DTB_NAME
 	string "Builtin DTB"
 	default ""
 
diff --git a/arch/openrisc/boot/dts/Makefile b/arch/openrisc/boot/dts/Makefile
index 13db5a2aab52..3a66e0ef3985 100644
--- a/arch/openrisc/boot/dts/Makefile
+++ b/arch/openrisc/boot/dts/Makefile
@@ -1,4 +1,4 @@
 # SPDX-License-Identifier: GPL-2.0
-obj-y += $(addsuffix .dtb.o, $(CONFIG_OPENRISC_BUILTIN_DTB))
+dtb-y += $(addsuffix .dtb, $(CONFIG_BUILTIN_DTB_NAME))
 
 #DTC_FLAGS ?= -p 1024
diff --git a/arch/openrisc/configs/or1klitex_defconfig b/arch/openrisc/configs/or1klitex_defconfig
index 466f31a091be..3e849d25838a 100644
--- a/arch/openrisc/configs/or1klitex_defconfig
+++ b/arch/openrisc/configs/or1klitex_defconfig
@@ -7,7 +7,7 @@ CONFIG_BLK_DEV_INITRD=y
 CONFIG_CC_OPTIMIZE_FOR_SIZE=y
 CONFIG_SGETMASK_SYSCALL=y
 CONFIG_EXPERT=y
-CONFIG_OPENRISC_BUILTIN_DTB="or1klitex"
+CONFIG_BUILTIN_DTB_NAME="or1klitex"
 CONFIG_HZ_100=y
 CONFIG_OPENRISC_HAVE_SHADOW_GPRS=y
 CONFIG_NET=y
diff --git a/arch/openrisc/configs/or1ksim_defconfig b/arch/openrisc/configs/or1ksim_defconfig
index 0116e465238f..59fe33cefba2 100644
--- a/arch/openrisc/configs/or1ksim_defconfig
+++ b/arch/openrisc/configs/or1ksim_defconfig
@@ -14,7 +14,7 @@ CONFIG_SLUB=y
 CONFIG_SLUB_TINY=y
 CONFIG_MODULES=y
 # CONFIG_BLOCK is not set
-CONFIG_OPENRISC_BUILTIN_DTB="or1ksim"
+CONFIG_BUILTIN_DTB_NAME="or1ksim"
 CONFIG_HZ_100=y
 CONFIG_NET=y
 CONFIG_PACKET=y
diff --git a/arch/openrisc/configs/simple_smp_defconfig b/arch/openrisc/configs/simple_smp_defconfig
index b990cb6c9309..6008e824d31c 100644
--- a/arch/openrisc/configs/simple_smp_defconfig
+++ b/arch/openrisc/configs/simple_smp_defconfig
@@ -20,7 +20,7 @@ CONFIG_SLUB=y
 CONFIG_SLUB_TINY=y
 CONFIG_MODULES=y
 # CONFIG_BLOCK is not set
-CONFIG_OPENRISC_BUILTIN_DTB="simple_smp"
+CONFIG_BUILTIN_DTB_NAME="simple_smp"
 CONFIG_SMP=y
 CONFIG_HZ_100=y
 CONFIG_OPENRISC_HAVE_SHADOW_GPRS=y
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] openrisc: migrate to the generic rule for built-in DTB
  2024-12-22  0:23 [PATCH] openrisc: migrate to the generic rule for built-in DTB Masahiro Yamada
@ 2024-12-24 20:21 ` Stafford Horne
  0 siblings, 0 replies; 2+ messages in thread
From: Stafford Horne @ 2024-12-24 20:21 UTC (permalink / raw)
  To: Masahiro Yamada
  Cc: Jonas Bonn, Stefan Kristiansson, linux-openrisc, linux-kernel,
	Conor Dooley, Gabriel Somlo, Joel Stanley, Karol Gugala,
	Krzysztof Kozlowski, Mateusz Holenko, Rob Herring, devicetree

On Sun, Dec 22, 2024 at 09:23:50AM +0900, Masahiro Yamada wrote:
> Commit 654102df2ac2 ("kbuild: add generic support for built-in boot
> DTBs") introduced generic support for built-in DTBs.
> 
> Select GENERIC_BUILTIN_DTB to use the generic rule.
> 
> To keep consistency across architectures, this commit also renames
> CONFIG_OPENRISC_BUILTIN_DTB_NAME to CONFIG_BUILTIN_DTB_NAME.
> 
> Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>

Thanks,

This looks good to me. I will queue this for 6.14.

-Stafford

> ---
> 
>  arch/openrisc/Kbuild                       | 1 -
>  arch/openrisc/Kconfig                      | 3 ++-
>  arch/openrisc/boot/dts/Makefile            | 2 +-
>  arch/openrisc/configs/or1klitex_defconfig  | 2 +-
>  arch/openrisc/configs/or1ksim_defconfig    | 2 +-
>  arch/openrisc/configs/simple_smp_defconfig | 2 +-
>  6 files changed, 6 insertions(+), 6 deletions(-)
> 
> diff --git a/arch/openrisc/Kbuild b/arch/openrisc/Kbuild
> index b0b0f2b03f87..70bdb24ff204 100644
> --- a/arch/openrisc/Kbuild
> +++ b/arch/openrisc/Kbuild
> @@ -1,6 +1,5 @@
>  # SPDX-License-Identifier: GPL-2.0
>  obj-y += lib/ kernel/ mm/
> -obj-y += boot/dts/
>  
>  # for cleaning
>  subdir- += boot
> diff --git a/arch/openrisc/Kconfig b/arch/openrisc/Kconfig
> index 3279ef457c57..3d053e0b59f4 100644
> --- a/arch/openrisc/Kconfig
> +++ b/arch/openrisc/Kconfig
> @@ -10,6 +10,7 @@ config OPENRISC
>  	select ARCH_HAS_DMA_SET_UNCACHED
>  	select ARCH_HAS_DMA_CLEAR_UNCACHED
>  	select ARCH_HAS_SYNC_DMA_FOR_DEVICE
> +	select GENERIC_BUILTIN_DTB
>  	select COMMON_CLK
>  	select OF
>  	select OF_EARLY_FLATTREE
> @@ -92,7 +93,7 @@ config DCACHE_WRITETHROUGH
>  
>  	  If unsure say N here
>  
> -config OPENRISC_BUILTIN_DTB
> +config BUILTIN_DTB_NAME
>  	string "Builtin DTB"
>  	default ""
>  
> diff --git a/arch/openrisc/boot/dts/Makefile b/arch/openrisc/boot/dts/Makefile
> index 13db5a2aab52..3a66e0ef3985 100644
> --- a/arch/openrisc/boot/dts/Makefile
> +++ b/arch/openrisc/boot/dts/Makefile
> @@ -1,4 +1,4 @@
>  # SPDX-License-Identifier: GPL-2.0
> -obj-y += $(addsuffix .dtb.o, $(CONFIG_OPENRISC_BUILTIN_DTB))
> +dtb-y += $(addsuffix .dtb, $(CONFIG_BUILTIN_DTB_NAME))
>  
>  #DTC_FLAGS ?= -p 1024
> diff --git a/arch/openrisc/configs/or1klitex_defconfig b/arch/openrisc/configs/or1klitex_defconfig
> index 466f31a091be..3e849d25838a 100644
> --- a/arch/openrisc/configs/or1klitex_defconfig
> +++ b/arch/openrisc/configs/or1klitex_defconfig
> @@ -7,7 +7,7 @@ CONFIG_BLK_DEV_INITRD=y
>  CONFIG_CC_OPTIMIZE_FOR_SIZE=y
>  CONFIG_SGETMASK_SYSCALL=y
>  CONFIG_EXPERT=y
> -CONFIG_OPENRISC_BUILTIN_DTB="or1klitex"
> +CONFIG_BUILTIN_DTB_NAME="or1klitex"
>  CONFIG_HZ_100=y
>  CONFIG_OPENRISC_HAVE_SHADOW_GPRS=y
>  CONFIG_NET=y
> diff --git a/arch/openrisc/configs/or1ksim_defconfig b/arch/openrisc/configs/or1ksim_defconfig
> index 0116e465238f..59fe33cefba2 100644
> --- a/arch/openrisc/configs/or1ksim_defconfig
> +++ b/arch/openrisc/configs/or1ksim_defconfig
> @@ -14,7 +14,7 @@ CONFIG_SLUB=y
>  CONFIG_SLUB_TINY=y
>  CONFIG_MODULES=y
>  # CONFIG_BLOCK is not set
> -CONFIG_OPENRISC_BUILTIN_DTB="or1ksim"
> +CONFIG_BUILTIN_DTB_NAME="or1ksim"
>  CONFIG_HZ_100=y
>  CONFIG_NET=y
>  CONFIG_PACKET=y
> diff --git a/arch/openrisc/configs/simple_smp_defconfig b/arch/openrisc/configs/simple_smp_defconfig
> index b990cb6c9309..6008e824d31c 100644
> --- a/arch/openrisc/configs/simple_smp_defconfig
> +++ b/arch/openrisc/configs/simple_smp_defconfig
> @@ -20,7 +20,7 @@ CONFIG_SLUB=y
>  CONFIG_SLUB_TINY=y
>  CONFIG_MODULES=y
>  # CONFIG_BLOCK is not set
> -CONFIG_OPENRISC_BUILTIN_DTB="simple_smp"
> +CONFIG_BUILTIN_DTB_NAME="simple_smp"
>  CONFIG_SMP=y
>  CONFIG_HZ_100=y
>  CONFIG_OPENRISC_HAVE_SHADOW_GPRS=y
> -- 
> 2.43.0
> 

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-12-24 20:21 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-12-22  0:23 [PATCH] openrisc: migrate to the generic rule for built-in DTB Masahiro Yamada
2024-12-24 20:21 ` Stafford Horne

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).