Skip to contentSkip to conversation

ARM: spear: Explicitly include correct DT includes

PATCH Applied Rob Herring 3 participants 3 messages Jul 17, 2023 – Aug 12, 2023

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ARM: spear: Explicitly include correct DT includes

The DT of_device.h and of_platform.h date back to the separate of_platform_bus_type before it was merged into the regular platform bus. As part of that merge prepping Arm DT support 13 years ago, they "temporarily" include each other. They also include platform_device.h and of.h. As a result, there's a pretty much random mix of those include files used throughout the tree. In order to detangle these headers and replace the implicit includes with struct declarations, users need to explicitly include the correct includes.

---
 arch/arm/mach-spear/spear1340.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/mach-spear/spear1340.c +1 -1
index a391f154eff9..70986ef6c877 100644
@@ -10,7 +10,7 @@
 
 #define pr_fmt(fmt) "SPEAr1340: " fmt
 
-#include <linux/of_platform.h>
+#include <linux/platform_device.h>
 #include <asm/mach/arch.h>
 #include "generic.h"
 
Signature · 1 line
2.40.1
Acked-by on v1 1/1
#1 lore raw
Quoted 19 lines · Rob Herring

The DT of_device.h and of_platform.h date back to the separate of_platform_bus_type before it was merged into the regular platform bus. As part of that merge prepping Arm DT support 13 years ago, they "temporarily" include each other. They also include platform_device.h and of.h. As a result, there's a pretty much random mix of those include files used throughout the tree. In order to detangle these headers and replace the implicit includes with struct declarations, users need to explicitly include the correct includes.

---
 arch/arm/mach-spear/spear1340.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/mach-spear/spear1340.c +0 -0
index a391f154eff9..70986ef6c877 100644

arch/arm/mach-spear/spear1340.c line 15

Quoted 7 lines
arch/arm/mach-spear/spear1340.c +1 -1
@@ -10,7 +10,7 @@
 
 #define pr_fmt(fmt) "SPEAr1340: " fmt
 
-#include <linux/of_platform.h>
+#include <linux/platform_device.h>
 #include <asm/mach/arch.h>
 #include "generic.h"
Signature · 1 line
viresh
#2 lore raw
In reply to Rob Herring
This patch was applied to soc/soc.git (for-next) by Arnd Bergmann <[email protected]>:

Hello:

This patch was applied to soc/soc.git (for-next)
by Arnd Bergmann <[email protected]>:

Quoted 10 lines · On Mon, 17 Jul 2023 16:54:13 -0600 you wrote:

The DT of_device.h and of_platform.h date back to the separate of_platform_bus_type before it was merged into the regular platform bus. As part of that merge prepping Arm DT support 13 years ago, they "temporarily" include each other. They also include platform_device.h and of.h. As a result, there's a pretty much random mix of those include files used throughout the tree. In order to detangle these headers and replace the implicit includes with struct declarations, users need to explicitly include the correct includes.

[...]

Here is the summary with links:
- ARM: spear: Explicitly include correct DT includes

    https://git.kernel.org/soc/soc/c/544885aa0750

You are awesome, thank you!

Signature · 2 lines
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html