linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 00/07] ARM: shmobile: Remove unused auxdata and callbacks
@ 2013-07-01  5:41 Magnus Damm
  2013-07-01  5:41 ` [PATCH 01/07] ARM: shmobile: Remove unused EMEV2 auxdata and callback Magnus Damm
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: Magnus Damm @ 2013-07-01  5:41 UTC (permalink / raw)
  To: linux-arm-kernel

ARM: shmobile: Remove unused auxdata and callbacks

[PATCH 01/07] ARM: shmobile: Remove unused EMEV2 auxdata and callback
[PATCH 02/07] ARM: shmobile: Remove unused r8a7740 auxdata table
[PATCH 03/07] ARM: shmobile: Remove unused r8a7778 auxdata and callback
[PATCH 04/07] ARM: shmobile: Remove unused r8a7779 auxdata table
[PATCH 05/07] ARM: shmobile: Remove unused sh7372 auxdata table
[PATCH 06/07] ARM: shmobile: Remove unused sh73a0 auxdata table
[PATCH 07/07] ARM: shmobile: Remove redundant r8a7790 callback

Rework the mach-shmobile code to pass NULL to of_platform_populate()
instead of empty lists. This cleans up the code and reduces the
number of lines. New in V2: Remove init_machine() callbacks that
only call of_platform_populate(), thanks to Arnd for his advice!

Signed-off-by: Magnus Damm <damm@opensource.se>
---

 Written against renesas.git renesas-next-20130701

 arch/arm/mach-shmobile/setup-emev2.c   |   10 ----------
 arch/arm/mach-shmobile/setup-r8a7740.c |    7 +------
 arch/arm/mach-shmobile/setup-r8a7778.c |   11 -----------
 arch/arm/mach-shmobile/setup-r8a7779.c |    7 +------
 arch/arm/mach-shmobile/setup-r8a7790.c |    5 -----
 arch/arm/mach-shmobile/setup-sh7372.c  |    7 +------
 arch/arm/mach-shmobile/setup-sh73a0.c  |    7 +------
 7 files changed, 4 insertions(+), 50 deletions(-)

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

* [PATCH 01/07] ARM: shmobile: Remove unused EMEV2 auxdata and callback
  2013-07-01  5:41 [PATCH v2 00/07] ARM: shmobile: Remove unused auxdata and callbacks Magnus Damm
@ 2013-07-01  5:41 ` Magnus Damm
  2013-07-01  5:41 ` [PATCH 02/07] ARM: shmobile: Remove unused r8a7740 auxdata table Magnus Damm
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: Magnus Damm @ 2013-07-01  5:41 UTC (permalink / raw)
  To: linux-arm-kernel

From: Magnus Damm <damm@opensource.se>

Replace the SoC-specific callback init_machine() with 
a NULL to use the default code. This cleans up the code
and reduces the number of lines.

Signed-off-by: Magnus Damm <damm@opensource.se>
---

 arch/arm/mach-shmobile/setup-emev2.c |   10 ----------
 1 file changed, 10 deletions(-)

--- 0001/arch/arm/mach-shmobile/setup-emev2.c
+++ work/arch/arm/mach-shmobile/setup-emev2.c	2013-07-01 13:19:32.000000000 +0900
@@ -435,15 +435,6 @@ void __init emev2_init_irq(void)
 }
 
 #ifdef CONFIG_USE_OF
-static const struct of_dev_auxdata emev2_auxdata_lookup[] __initconst = {
-	{ }
-};
-
-static void __init emev2_add_standard_devices_dt(void)
-{
-	of_platform_populate(NULL, of_default_bus_match_table,
-			     emev2_auxdata_lookup, NULL);
-}
 
 static const char *emev2_boards_compat_dt[] __initdata = {
 	"renesas,emev2",
@@ -455,7 +446,6 @@ DT_MACHINE_START(EMEV2_DT, "Generic Emma
 	.init_early	= emev2_init_delay,
 	.nr_irqs	= NR_IRQS_LEGACY,
 	.init_irq	= irqchip_init,
-	.init_machine	= emev2_add_standard_devices_dt,
 	.dt_compat	= emev2_boards_compat_dt,
 MACHINE_END
 

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

* [PATCH 02/07] ARM: shmobile: Remove unused r8a7740 auxdata table
  2013-07-01  5:41 [PATCH v2 00/07] ARM: shmobile: Remove unused auxdata and callbacks Magnus Damm
  2013-07-01  5:41 ` [PATCH 01/07] ARM: shmobile: Remove unused EMEV2 auxdata and callback Magnus Damm
@ 2013-07-01  5:41 ` Magnus Damm
  2013-07-01  5:41 ` [PATCH 03/07] ARM: shmobile: Remove unused r8a7778 auxdata and callback Magnus Damm
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: Magnus Damm @ 2013-07-01  5:41 UTC (permalink / raw)
  To: linux-arm-kernel

From: Magnus Damm <damm@opensource.se>

Pass NULL to of_platform_populate instead of passing
an empty list. This cleans up the code and reduces the
number of lines.

Signed-off-by: Magnus Damm <damm@opensource.se>
---

 arch/arm/mach-shmobile/setup-r8a7740.c |    7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

--- 0001/arch/arm/mach-shmobile/setup-r8a7740.c
+++ work/arch/arm/mach-shmobile/setup-r8a7740.c	2013-06-28 15:43:04.000000000 +0900
@@ -986,16 +986,11 @@ void __init r8a7740_add_early_devices(vo
 
 #ifdef CONFIG_USE_OF
 
-static const struct of_dev_auxdata r8a7740_auxdata_lookup[] __initconst = {
-	{ }
-};
-
 void __init r8a7740_add_standard_devices_dt(void)
 {
 	platform_add_devices(r8a7740_devices_dt,
 			    ARRAY_SIZE(r8a7740_devices_dt));
-	of_platform_populate(NULL, of_default_bus_match_table,
-			     r8a7740_auxdata_lookup, NULL);
+	of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
 }
 
 void __init r8a7740_init_delay(void)

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

* [PATCH 03/07] ARM: shmobile: Remove unused r8a7778 auxdata and callback
  2013-07-01  5:41 [PATCH v2 00/07] ARM: shmobile: Remove unused auxdata and callbacks Magnus Damm
  2013-07-01  5:41 ` [PATCH 01/07] ARM: shmobile: Remove unused EMEV2 auxdata and callback Magnus Damm
  2013-07-01  5:41 ` [PATCH 02/07] ARM: shmobile: Remove unused r8a7740 auxdata table Magnus Damm
@ 2013-07-01  5:41 ` Magnus Damm
  2013-07-01  5:41 ` [PATCH 04/07] ARM: shmobile: Remove unused r8a7779 auxdata table Magnus Damm
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: Magnus Damm @ 2013-07-01  5:41 UTC (permalink / raw)
  To: linux-arm-kernel

From: Magnus Damm <damm@opensource.se>

Replace the SoC-specific callback init_machine() with 
a NULL to use the default code. This cleans up the code
and reduces the number of lines.

Signed-off-by: Magnus Damm <damm@opensource.se>
---

 arch/arm/mach-shmobile/setup-r8a7778.c |   11 -----------
 1 file changed, 11 deletions(-)

--- 0001/arch/arm/mach-shmobile/setup-r8a7778.c
+++ work/arch/arm/mach-shmobile/setup-r8a7778.c	2013-07-01 13:21:05.000000000 +0900
@@ -457,16 +457,6 @@ void __init r8a7778_init_irq_dt(void)
 	r8a7778_init_irq_common();
 }
 
-static const struct of_dev_auxdata r8a7778_auxdata_lookup[] __initconst = {
-	{},
-};
-
-void __init r8a7778_add_standard_devices_dt(void)
-{
-	of_platform_populate(NULL, of_default_bus_match_table,
-			     r8a7778_auxdata_lookup, NULL);
-}
-
 static const char *r8a7778_compat_dt[] __initdata = {
 	"renesas,r8a7778",
 	NULL,
@@ -475,7 +465,6 @@ static const char *r8a7778_compat_dt[] _
 DT_MACHINE_START(R8A7778_DT, "Generic R8A7778 (Flattened Device Tree)")
 	.init_early	= r8a7778_init_delay,
 	.init_irq	= r8a7778_init_irq_dt,
-	.init_machine	= r8a7778_add_standard_devices_dt,
 	.init_time	= shmobile_timer_init,
 	.dt_compat	= r8a7778_compat_dt,
 	.init_late      = r8a7778_init_late,

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

* [PATCH 04/07] ARM: shmobile: Remove unused r8a7779 auxdata table
  2013-07-01  5:41 [PATCH v2 00/07] ARM: shmobile: Remove unused auxdata and callbacks Magnus Damm
                   ` (2 preceding siblings ...)
  2013-07-01  5:41 ` [PATCH 03/07] ARM: shmobile: Remove unused r8a7778 auxdata and callback Magnus Damm
@ 2013-07-01  5:41 ` Magnus Damm
  2013-07-01  5:41 ` [PATCH 05/07] ARM: shmobile: Remove unused sh7372 " Magnus Damm
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: Magnus Damm @ 2013-07-01  5:41 UTC (permalink / raw)
  To: linux-arm-kernel

From: Magnus Damm <damm@opensource.se>

Pass NULL to of_platform_populate instead of passing
an empty list. This cleans up the code and reduces the
number of lines.

Signed-off-by: Magnus Damm <damm@opensource.se>
---

 arch/arm/mach-shmobile/setup-r8a7779.c |    7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

--- 0001/arch/arm/mach-shmobile/setup-r8a7779.c
+++ work/arch/arm/mach-shmobile/setup-r8a7779.c	2013-06-28 15:49:50.000000000 +0900
@@ -665,10 +665,6 @@ void __init r8a7779_init_delay(void)
 	shmobile_setup_delay(1000, 2, 4); /* Cortex-A9 @ 1000MHz */
 }
 
-static const struct of_dev_auxdata r8a7779_auxdata_lookup[] __initconst = {
-	{},
-};
-
 void __init r8a7779_add_standard_devices_dt(void)
 {
 	/* clocks are setup late during boot in the case of DT */
@@ -676,8 +672,7 @@ void __init r8a7779_add_standard_devices
 
 	platform_add_devices(r8a7779_devices_dt,
 			     ARRAY_SIZE(r8a7779_devices_dt));
-	of_platform_populate(NULL, of_default_bus_match_table,
-			     r8a7779_auxdata_lookup, NULL);
+	of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
 }
 
 static const char *r8a7779_compat_dt[] __initdata = {

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

* [PATCH 05/07] ARM: shmobile: Remove unused sh7372 auxdata table
  2013-07-01  5:41 [PATCH v2 00/07] ARM: shmobile: Remove unused auxdata and callbacks Magnus Damm
                   ` (3 preceding siblings ...)
  2013-07-01  5:41 ` [PATCH 04/07] ARM: shmobile: Remove unused r8a7779 auxdata table Magnus Damm
@ 2013-07-01  5:41 ` Magnus Damm
  2013-07-01  5:42 ` [PATCH 06/07] ARM: shmobile: Remove unused sh73a0 " Magnus Damm
  2013-07-01  5:42 ` [PATCH 07/07] ARM: shmobile: Remove redundant r8a7790 callback Magnus Damm
  6 siblings, 0 replies; 8+ messages in thread
From: Magnus Damm @ 2013-07-01  5:41 UTC (permalink / raw)
  To: linux-arm-kernel

From: Magnus Damm <damm@opensource.se>

Pass NULL to of_platform_populate instead of passing
an empty list. This cleans up the code and reduces the
number of lines.

Signed-off-by: Magnus Damm <damm@opensource.se>
---

 arch/arm/mach-shmobile/setup-sh7372.c |    7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

--- 0001/arch/arm/mach-shmobile/setup-sh7372.c
+++ work/arch/arm/mach-shmobile/setup-sh7372.c	2013-06-28 15:41:15.000000000 +0900
@@ -1147,10 +1147,6 @@ void __init sh7372_add_early_devices_dt(
 	shmobile_setup_console();
 }
 
-static const struct of_dev_auxdata sh7372_auxdata_lookup[] __initconst = {
-	{ }
-};
-
 void __init sh7372_add_standard_devices_dt(void)
 {
 	/* clocks are setup late during boot in the case of DT */
@@ -1159,8 +1155,7 @@ void __init sh7372_add_standard_devices_
 	platform_add_devices(sh7372_early_devices,
 			    ARRAY_SIZE(sh7372_early_devices));
 
-	of_platform_populate(NULL, of_default_bus_match_table,
-			     sh7372_auxdata_lookup, NULL);
+	of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
 }
 
 static const char *sh7372_boards_compat_dt[] __initdata = {

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

* [PATCH 06/07] ARM: shmobile: Remove unused sh73a0 auxdata table
  2013-07-01  5:41 [PATCH v2 00/07] ARM: shmobile: Remove unused auxdata and callbacks Magnus Damm
                   ` (4 preceding siblings ...)
  2013-07-01  5:41 ` [PATCH 05/07] ARM: shmobile: Remove unused sh7372 " Magnus Damm
@ 2013-07-01  5:42 ` Magnus Damm
  2013-07-01  5:42 ` [PATCH 07/07] ARM: shmobile: Remove redundant r8a7790 callback Magnus Damm
  6 siblings, 0 replies; 8+ messages in thread
From: Magnus Damm @ 2013-07-01  5:42 UTC (permalink / raw)
  To: linux-arm-kernel

From: Magnus Damm <damm@opensource.se>

Pass NULL to of_platform_populate instead of passing
an empty list. This cleans up the code and reduces the
number of lines.

Signed-off-by: Magnus Damm <damm@opensource.se>
---

 arch/arm/mach-shmobile/setup-sh73a0.c |    7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

--- 0001/arch/arm/mach-shmobile/setup-sh73a0.c
+++ work/arch/arm/mach-shmobile/setup-sh73a0.c	2013-06-28 19:16:07.000000000 +0900
@@ -958,10 +958,6 @@ void __init sh73a0_add_early_devices(voi
 
 #ifdef CONFIG_USE_OF
 
-static const struct of_dev_auxdata sh73a0_auxdata_lookup[] __initconst = {
-	{},
-};
-
 void __init sh73a0_add_standard_devices_dt(void)
 {
 	struct platform_device_info devinfo = { .name = "cpufreq-cpu0", .id = -1, };
@@ -971,8 +967,7 @@ void __init sh73a0_add_standard_devices_
 
 	platform_add_devices(sh73a0_devices_dt,
 			     ARRAY_SIZE(sh73a0_devices_dt));
-	of_platform_populate(NULL, of_default_bus_match_table,
-			     sh73a0_auxdata_lookup, NULL);
+	of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
 
 	/* Instantiate cpufreq-cpu0 */
 	platform_device_register_full(&devinfo);

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

* [PATCH 07/07] ARM: shmobile: Remove redundant r8a7790 callback
  2013-07-01  5:41 [PATCH v2 00/07] ARM: shmobile: Remove unused auxdata and callbacks Magnus Damm
                   ` (5 preceding siblings ...)
  2013-07-01  5:42 ` [PATCH 06/07] ARM: shmobile: Remove unused sh73a0 " Magnus Damm
@ 2013-07-01  5:42 ` Magnus Damm
  6 siblings, 0 replies; 8+ messages in thread
From: Magnus Damm @ 2013-07-01  5:42 UTC (permalink / raw)
  To: linux-arm-kernel

From: Magnus Damm <damm@opensource.se>

Replace the SoC-specific callback init_machine() with 
a NULL to use the default code. This cleans up the code
and reduces the number of lines.

Signed-off-by: Magnus Damm <damm@opensource.se>
---

 arch/arm/mach-shmobile/setup-r8a7790.c |    5 -----
 1 file changed, 5 deletions(-)

--- 0001/arch/arm/mach-shmobile/setup-r8a7790.c
+++ work/arch/arm/mach-shmobile/setup-r8a7790.c	2013-07-01 13:24:33.000000000 +0900
@@ -217,10 +217,6 @@ void __init r8a7790_init_delay(void)
 }
 
 #ifdef CONFIG_USE_OF
-void __init r8a7790_add_standard_devices_dt(void)
-{
-	of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
-}
 
 static const char *r8a7790_boards_compat_dt[] __initdata = {
 	"renesas,r8a7790",
@@ -230,7 +226,6 @@ static const char *r8a7790_boards_compat
 DT_MACHINE_START(R8A7790_DT, "Generic R8A7790 (Flattened Device Tree)")
 	.init_early	= r8a7790_init_delay,
 	.init_irq	= irqchip_init,
-	.init_machine	= r8a7790_add_standard_devices_dt,
 	.init_time	= r8a7790_timer_init,
 	.dt_compat	= r8a7790_boards_compat_dt,
 MACHINE_END

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

end of thread, other threads:[~2013-07-01  5:42 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-07-01  5:41 [PATCH v2 00/07] ARM: shmobile: Remove unused auxdata and callbacks Magnus Damm
2013-07-01  5:41 ` [PATCH 01/07] ARM: shmobile: Remove unused EMEV2 auxdata and callback Magnus Damm
2013-07-01  5:41 ` [PATCH 02/07] ARM: shmobile: Remove unused r8a7740 auxdata table Magnus Damm
2013-07-01  5:41 ` [PATCH 03/07] ARM: shmobile: Remove unused r8a7778 auxdata and callback Magnus Damm
2013-07-01  5:41 ` [PATCH 04/07] ARM: shmobile: Remove unused r8a7779 auxdata table Magnus Damm
2013-07-01  5:41 ` [PATCH 05/07] ARM: shmobile: Remove unused sh7372 " Magnus Damm
2013-07-01  5:42 ` [PATCH 06/07] ARM: shmobile: Remove unused sh73a0 " Magnus Damm
2013-07-01  5:42 ` [PATCH 07/07] ARM: shmobile: Remove redundant r8a7790 callback Magnus Damm

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).