diff mbox

[7/7] openrisc: remove the redundant of_platform_populate

Message ID 1474036985-20981-8-git-send-email-shorne@gmail.com
State Superseded
Headers show

Commit Message

Stafford Horne Sept. 16, 2016, 2:43 p.m. UTC
From: Rob Herring <robh@kernel.org>


The of_platform_populate call in the openrisc arch code is now redundant
as the DT core provides a default call. Openrisc has a NULL match table
which means only top level nodes with compatible strings will have
devices creates. The default version will also descend nodes in the
match table such as "simple-bus" which should be fine as openrisc
doesn't have any of these (though it is preferred that memory-mapped
peripherals be grouped under a bus node(s)).

Signed-off-by: Rob Herring <robh@kernel.org>

Cc: Jonas Bonn <jonas@southpole.se>
Signed-off-by: Stafford Horne <shorne@gmail.com>

---
 arch/openrisc/kernel/setup.c | 10 ----------
 1 file changed, 10 deletions(-)

-- 
2.7.4

Comments

Rob Herring Sept. 19, 2016, 4:14 p.m. UTC | #1
On Mon, Sep 19, 2016 at 9:32 AM, Jonas Bonn <jonas@southpole.se> wrote:
> On 09/16/2016 04:43 PM, Stafford Horne wrote:

>>

>> From: Rob Herring <robh@kernel.org>

>>

>> The of_platform_populate call in the openrisc arch code is now redundant

>> as the DT core provides a default call. Openrisc has a NULL match table

>> which means only top level nodes with compatible strings will have

>> devices creates. The default version will also descend nodes in the

>> match table such as "simple-bus" which should be fine as openrisc

>> doesn't have any of these (though it is preferred that memory-mapped

>> peripherals be grouped under a bus node(s)).

>>

>> Signed-off-by: Rob Herring <robh@kernel.org>

>> Cc: Jonas Bonn <jonas@southpole.se>

>> Signed-off-by: Stafford Horne <shorne@gmail.com>

>

>

> Yes, this is fine, but trivial/generic stuff like this doesn't really need

> to go via the OpenRISC repo, anyway.


Then which tree do you think it should go thru? I could have applied
it, but it doesn't depend on anything else. So it should go via the
correct maintainer's tree.

Rob
diff mbox

Patch

diff --git a/arch/openrisc/kernel/setup.c b/arch/openrisc/kernel/setup.c
index b4ed8b3..d2f78cf 100644
--- a/arch/openrisc/kernel/setup.c
+++ b/arch/openrisc/kernel/setup.c
@@ -38,7 +38,6 @@ 
 #include <linux/of.h>
 #include <linux/memblock.h>
 #include <linux/device.h>
-#include <linux/of_platform.h>
 
 #include <asm/sections.h>
 #include <asm/segment.h>
@@ -219,15 +218,6 @@  void __init or32_early_setup(void *fdt)
 	early_init_devtree(fdt);
 }
 
-static int __init openrisc_device_probe(void)
-{
-	of_platform_populate(NULL, NULL, NULL, NULL);
-
-	return 0;
-}
-
-device_initcall(openrisc_device_probe);
-
 static inline unsigned long extract_value_bits(unsigned long reg,
 					       short bit_nr, short width)
 {