All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 00/04] ARM: shmobile: ARCH_MULTIPLATFORM for EMEV2 and KZM9D
@ 2013-07-09  5:43 ` Magnus Damm
  0 siblings, 0 replies; 28+ messages in thread
From: Magnus Damm @ 2013-07-09  5:43 UTC (permalink / raw)
  To: linux-arm-kernel

ARM: shmobile: ARCH_MULTIPLATFORM for EMEV2 and KZM9D

[PATCH 01/04] ARM: shmobile: Only build clocks when COMMON_CLK=n
[PATCH 02/04] ARM: shmobile: Introduce ARCH_SHMOBILE_MULTI
[PATCH 03/04] ARM: shmobile: Add EMEV2 and KZM9D to ARCH_SHMOBILE_MULTI
[PATCH 04/04] ARM: shmobile: Allow ARCH_SHMOBILE_MULTI timer configuration

This patch set extends mach-shmobile to allow a subset of SoCs and
boards to be built for ARCH_MULTIPLATFORM. With this series applied
the EMEV2 SoC and the KZM9D board can be built in two ways - either
as good old ARCH_SHMOBILE or new ARCH_SHMOBILE_MULTI. The latter
requires common clock framework for proper run time operation.

The goal is to over time move all DT reference implementations from
ARCH_SHMOBILE to ARCH_SHMOBILE_MULTI. Until CCF is available for a
certain SoC it is to me acceptable for a DT reference board to allow
build in both ARCH_SHMOBILE and ARCH_SHMOBILE_MULTI. The reason for
this is to allow incremental development and easy testing during
development of CCF for a certain SoC. The KZM9D board is now in this
state while it is waiting for common clocks to become ready.

In the near future a prototype hack will be posted that comments
out the clock framework bits on EMEV2 and will allow boot of KZM9D
in the case of ARCH_SHMOBILE_MULTI even though CCF is not yet
available.

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

 Built on top of renesas-next-20130704v2 and
 [PATCH] ARM: shmobile: KZM9D DT reference implementation

 arch/arm/Makefile                    |    1 
 arch/arm/boot/dts/Makefile           |    1 
 arch/arm/mach-shmobile/Kconfig       |   52 ++++++++++++++++++++++++++++++----
 arch/arm/mach-shmobile/Makefile      |   32 +++++++++++++++-----
 arch/arm/mach-shmobile/setup-emev2.c |    5 +++
 5 files changed, 77 insertions(+), 14 deletions(-)

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

* [PATCH 00/04] ARM: shmobile: ARCH_MULTIPLATFORM for EMEV2 and KZM9D
@ 2013-07-09  5:43 ` Magnus Damm
  0 siblings, 0 replies; 28+ messages in thread
From: Magnus Damm @ 2013-07-09  5:43 UTC (permalink / raw)
  To: linux-arm-kernel

ARM: shmobile: ARCH_MULTIPLATFORM for EMEV2 and KZM9D

[PATCH 01/04] ARM: shmobile: Only build clocks when COMMON_CLK=n
[PATCH 02/04] ARM: shmobile: Introduce ARCH_SHMOBILE_MULTI
[PATCH 03/04] ARM: shmobile: Add EMEV2 and KZM9D to ARCH_SHMOBILE_MULTI
[PATCH 04/04] ARM: shmobile: Allow ARCH_SHMOBILE_MULTI timer configuration

This patch set extends mach-shmobile to allow a subset of SoCs and
boards to be built for ARCH_MULTIPLATFORM. With this series applied
the EMEV2 SoC and the KZM9D board can be built in two ways - either
as good old ARCH_SHMOBILE or new ARCH_SHMOBILE_MULTI. The latter
requires common clock framework for proper run time operation.

The goal is to over time move all DT reference implementations from
ARCH_SHMOBILE to ARCH_SHMOBILE_MULTI. Until CCF is available for a
certain SoC it is to me acceptable for a DT reference board to allow
build in both ARCH_SHMOBILE and ARCH_SHMOBILE_MULTI. The reason for
this is to allow incremental development and easy testing during
development of CCF for a certain SoC. The KZM9D board is now in this
state while it is waiting for common clocks to become ready.

In the near future a prototype hack will be posted that comments
out the clock framework bits on EMEV2 and will allow boot of KZM9D
in the case of ARCH_SHMOBILE_MULTI even though CCF is not yet
available.

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

 Built on top of renesas-next-20130704v2 and
 [PATCH] ARM: shmobile: KZM9D DT reference implementation

 arch/arm/Makefile                    |    1 
 arch/arm/boot/dts/Makefile           |    1 
 arch/arm/mach-shmobile/Kconfig       |   52 ++++++++++++++++++++++++++++++----
 arch/arm/mach-shmobile/Makefile      |   32 +++++++++++++++-----
 arch/arm/mach-shmobile/setup-emev2.c |    5 +++
 5 files changed, 77 insertions(+), 14 deletions(-)

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

* [PATCH 01/04] ARM: shmobile: Only build clocks when COMMON_CLK=n
  2013-07-09  5:43 ` Magnus Damm
@ 2013-07-09  5:43   ` Magnus Damm
  -1 siblings, 0 replies; 28+ messages in thread
From: Magnus Damm @ 2013-07-09  5:43 UTC (permalink / raw)
  To: linux-arm-kernel

From: Magnus Damm <damm@opensource.se>

Move shared clock.c file and per-SoC clock-xxx.c files
to only build when CONFIG_COMMON_CLK != y.

The regular ARCH_SHMOBILE case with legacy SH clock framework
will build just as before with this patch applied, however
the case when COMMON_CLK=y will exclude all the clock files.

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

 arch/arm/mach-shmobile/Makefile |   30 +++++++++++++++++++++---------
 1 file changed, 21 insertions(+), 9 deletions(-)

--- 0002/arch/arm/mach-shmobile/Makefile
+++ work/arch/arm/mach-shmobile/Makefile	2013-07-09 12:21:29.000000000 +0900
@@ -3,17 +3,28 @@
 #
 
 # Common objects
-obj-y				:= timer.o console.o clock.o
+obj-y				:= timer.o console.o
 
 # CPU objects
-obj-$(CONFIG_ARCH_SH7372)	+= setup-sh7372.o clock-sh7372.o intc-sh7372.o
-obj-$(CONFIG_ARCH_SH73A0)	+= setup-sh73a0.o clock-sh73a0.o intc-sh73a0.o
-obj-$(CONFIG_ARCH_R8A73A4)	+= setup-r8a73a4.o clock-r8a73a4.o
-obj-$(CONFIG_ARCH_R8A7740)	+= setup-r8a7740.o clock-r8a7740.o intc-r8a7740.o
-obj-$(CONFIG_ARCH_R8A7778)	+= setup-r8a7778.o clock-r8a7778.o
-obj-$(CONFIG_ARCH_R8A7779)	+= setup-r8a7779.o clock-r8a7779.o intc-r8a7779.o
-obj-$(CONFIG_ARCH_R8A7790)	+= setup-r8a7790.o clock-r8a7790.o
-obj-$(CONFIG_ARCH_EMEV2)	+= setup-emev2.o clock-emev2.o
+obj-$(CONFIG_ARCH_SH7372)	+= setup-sh7372.o intc-sh7372.o
+obj-$(CONFIG_ARCH_SH73A0)	+= setup-sh73a0.o intc-sh73a0.o
+obj-$(CONFIG_ARCH_R8A73A4)	+= setup-r8a73a4.o
+obj-$(CONFIG_ARCH_R8A7740)	+= setup-r8a7740.o intc-r8a7740.o
+obj-$(CONFIG_ARCH_R8A7778)	+= setup-r8a7778.o
+obj-$(CONFIG_ARCH_R8A7779)	+= setup-r8a7779.o intc-r8a7779.o
+obj-$(CONFIG_ARCH_R8A7790)	+= setup-r8a7790.o
+obj-$(CONFIG_ARCH_EMEV2)	+= setup-emev2.o
+
+# Clock objects
+clk-y				:= clock.o
+clk-$(CONFIG_ARCH_SH7372)	+= clock-sh7372.o
+clk-$(CONFIG_ARCH_SH73A0)	+= clock-sh73a0.o
+clk-$(CONFIG_ARCH_R8A73A4)	+= clock-r8a73a4.o
+clk-$(CONFIG_ARCH_R8A7740)	+= clock-r8a7740.o
+clk-$(CONFIG_ARCH_R8A7778)	+= clock-r8a7778.o
+clk-$(CONFIG_ARCH_R8A7779)	+= clock-r8a7779.o
+clk-$(CONFIG_ARCH_R8A7790)	+= clock-r8a7790.o
+clk-$(CONFIG_ARCH_EMEV2)	+= clock-emev2.o
 
 # SMP objects
 smp-y				:= platsmp.o headsmp.o
@@ -53,3 +64,4 @@ obj-$(CONFIG_MACH_KZM9G_REFERENCE)	+= bo
 
 # Framework support
 obj-$(CONFIG_SMP)		+= $(smp-y)
+obj-y				+= $(clk-y$(CONFIG_COMMON_CLK))

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

* [PATCH 01/04] ARM: shmobile: Only build clocks when COMMON_CLK=n
@ 2013-07-09  5:43   ` Magnus Damm
  0 siblings, 0 replies; 28+ messages in thread
From: Magnus Damm @ 2013-07-09  5:43 UTC (permalink / raw)
  To: linux-arm-kernel

From: Magnus Damm <damm@opensource.se>

Move shared clock.c file and per-SoC clock-xxx.c files
to only build when CONFIG_COMMON_CLK != y.

The regular ARCH_SHMOBILE case with legacy SH clock framework
will build just as before with this patch applied, however
the case when COMMON_CLK=y will exclude all the clock files.

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

 arch/arm/mach-shmobile/Makefile |   30 +++++++++++++++++++++---------
 1 file changed, 21 insertions(+), 9 deletions(-)

--- 0002/arch/arm/mach-shmobile/Makefile
+++ work/arch/arm/mach-shmobile/Makefile	2013-07-09 12:21:29.000000000 +0900
@@ -3,17 +3,28 @@
 #
 
 # Common objects
-obj-y				:= timer.o console.o clock.o
+obj-y				:= timer.o console.o
 
 # CPU objects
-obj-$(CONFIG_ARCH_SH7372)	+= setup-sh7372.o clock-sh7372.o intc-sh7372.o
-obj-$(CONFIG_ARCH_SH73A0)	+= setup-sh73a0.o clock-sh73a0.o intc-sh73a0.o
-obj-$(CONFIG_ARCH_R8A73A4)	+= setup-r8a73a4.o clock-r8a73a4.o
-obj-$(CONFIG_ARCH_R8A7740)	+= setup-r8a7740.o clock-r8a7740.o intc-r8a7740.o
-obj-$(CONFIG_ARCH_R8A7778)	+= setup-r8a7778.o clock-r8a7778.o
-obj-$(CONFIG_ARCH_R8A7779)	+= setup-r8a7779.o clock-r8a7779.o intc-r8a7779.o
-obj-$(CONFIG_ARCH_R8A7790)	+= setup-r8a7790.o clock-r8a7790.o
-obj-$(CONFIG_ARCH_EMEV2)	+= setup-emev2.o clock-emev2.o
+obj-$(CONFIG_ARCH_SH7372)	+= setup-sh7372.o intc-sh7372.o
+obj-$(CONFIG_ARCH_SH73A0)	+= setup-sh73a0.o intc-sh73a0.o
+obj-$(CONFIG_ARCH_R8A73A4)	+= setup-r8a73a4.o
+obj-$(CONFIG_ARCH_R8A7740)	+= setup-r8a7740.o intc-r8a7740.o
+obj-$(CONFIG_ARCH_R8A7778)	+= setup-r8a7778.o
+obj-$(CONFIG_ARCH_R8A7779)	+= setup-r8a7779.o intc-r8a7779.o
+obj-$(CONFIG_ARCH_R8A7790)	+= setup-r8a7790.o
+obj-$(CONFIG_ARCH_EMEV2)	+= setup-emev2.o
+
+# Clock objects
+clk-y				:= clock.o
+clk-$(CONFIG_ARCH_SH7372)	+= clock-sh7372.o
+clk-$(CONFIG_ARCH_SH73A0)	+= clock-sh73a0.o
+clk-$(CONFIG_ARCH_R8A73A4)	+= clock-r8a73a4.o
+clk-$(CONFIG_ARCH_R8A7740)	+= clock-r8a7740.o
+clk-$(CONFIG_ARCH_R8A7778)	+= clock-r8a7778.o
+clk-$(CONFIG_ARCH_R8A7779)	+= clock-r8a7779.o
+clk-$(CONFIG_ARCH_R8A7790)	+= clock-r8a7790.o
+clk-$(CONFIG_ARCH_EMEV2)	+= clock-emev2.o
 
 # SMP objects
 smp-y				:= platsmp.o headsmp.o
@@ -53,3 +64,4 @@ obj-$(CONFIG_MACH_KZM9G_REFERENCE)	+= bo
 
 # Framework support
 obj-$(CONFIG_SMP)		+= $(smp-y)
+obj-y				+= $(clk-y$(CONFIG_COMMON_CLK))

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

* [PATCH 02/04] ARM: shmobile: Introduce ARCH_SHMOBILE_MULTI
  2013-07-09  5:43 ` Magnus Damm
@ 2013-07-09  5:43   ` Magnus Damm
  -1 siblings, 0 replies; 28+ messages in thread
From: Magnus Damm @ 2013-07-09  5:43 UTC (permalink / raw)
  To: linux-arm-kernel

From: Magnus Damm <damm@opensource.se>

Add ARCH_SHMOBILE_MULTI to mach-shmobile that can be used
to enable ARCH_MULTIPLATFORM on selected SoCs and boards.

The headers stay under arch/arm/mach-shmobile/include/mach/
for now, they can and will be migrated independently over time.

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

 arch/arm/Makefile               |    1 +
 arch/arm/mach-shmobile/Kconfig  |   21 +++++++++++++++++++++
 arch/arm/mach-shmobile/Makefile |    2 ++
 3 files changed, 24 insertions(+)

--- 0001/arch/arm/Makefile
+++ work/arch/arm/Makefile	2013-07-08 19:17:00.000000000 +0900
@@ -181,6 +181,7 @@ machine-$(CONFIG_ARCH_EXYNOS)		+= exynos
 machine-$(CONFIG_ARCH_SA1100)		+= sa1100
 machine-$(CONFIG_ARCH_SHARK)		+= shark
 machine-$(CONFIG_ARCH_SHMOBILE) 	+= shmobile
+machine-$(CONFIG_ARCH_SHMOBILE_MULTI) 	+= shmobile
 machine-$(CONFIG_ARCH_TEGRA)		+= tegra
 machine-$(CONFIG_ARCH_U300)		+= u300
 machine-$(CONFIG_ARCH_U8500)		+= ux500
--- 0002/arch/arm/mach-shmobile/Kconfig
+++ work/arch/arm/mach-shmobile/Kconfig	2013-07-08 19:19:21.000000000 +0900
@@ -1,3 +1,24 @@
+config ARCH_SHMOBILE_MULTI
+	bool "SH-Mobile Series" if ARCH_MULTI_V7
+	depends on MMU
+	select CPU_V7
+	select GENERIC_CLOCKEVENTS
+	select HAVE_ARM_SCU if SMP
+	select HAVE_ARM_TWD if LOCAL_TIMERS
+	select HAVE_SMP
+	select ARM_GIC
+	select MIGHT_HAVE_CACHE_L2X0
+	select NO_IOPORT
+	select PINCTRL
+	select ARCH_REQUIRE_GPIOLIB
+	select CLKDEV_LOOKUP
+
+if ARCH_SHMOBILE_MULTI
+
+comment "SH-Mobile System Type"
+
+endif
+
 if ARCH_SHMOBILE
 
 comment "SH-Mobile System Type"
--- 0003/arch/arm/mach-shmobile/Makefile
+++ work/arch/arm/mach-shmobile/Makefile	2013-07-08 19:18:20.000000000 +0900
@@ -2,6 +2,8 @@
 # Makefile for the linux kernel.
 #
 
+ccflags-$(CONFIG_ARCH_MULTIPLATFORM) := -I$(srctree)/arch/arm/mach-shmobile/include
+
 # Common objects
 obj-y				:= timer.o console.o
 

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

* [PATCH 02/04] ARM: shmobile: Introduce ARCH_SHMOBILE_MULTI
@ 2013-07-09  5:43   ` Magnus Damm
  0 siblings, 0 replies; 28+ messages in thread
From: Magnus Damm @ 2013-07-09  5:43 UTC (permalink / raw)
  To: linux-arm-kernel

From: Magnus Damm <damm@opensource.se>

Add ARCH_SHMOBILE_MULTI to mach-shmobile that can be used
to enable ARCH_MULTIPLATFORM on selected SoCs and boards.

The headers stay under arch/arm/mach-shmobile/include/mach/
for now, they can and will be migrated independently over time.

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

 arch/arm/Makefile               |    1 +
 arch/arm/mach-shmobile/Kconfig  |   21 +++++++++++++++++++++
 arch/arm/mach-shmobile/Makefile |    2 ++
 3 files changed, 24 insertions(+)

--- 0001/arch/arm/Makefile
+++ work/arch/arm/Makefile	2013-07-08 19:17:00.000000000 +0900
@@ -181,6 +181,7 @@ machine-$(CONFIG_ARCH_EXYNOS)		+= exynos
 machine-$(CONFIG_ARCH_SA1100)		+= sa1100
 machine-$(CONFIG_ARCH_SHARK)		+= shark
 machine-$(CONFIG_ARCH_SHMOBILE) 	+= shmobile
+machine-$(CONFIG_ARCH_SHMOBILE_MULTI) 	+= shmobile
 machine-$(CONFIG_ARCH_TEGRA)		+= tegra
 machine-$(CONFIG_ARCH_U300)		+= u300
 machine-$(CONFIG_ARCH_U8500)		+= ux500
--- 0002/arch/arm/mach-shmobile/Kconfig
+++ work/arch/arm/mach-shmobile/Kconfig	2013-07-08 19:19:21.000000000 +0900
@@ -1,3 +1,24 @@
+config ARCH_SHMOBILE_MULTI
+	bool "SH-Mobile Series" if ARCH_MULTI_V7
+	depends on MMU
+	select CPU_V7
+	select GENERIC_CLOCKEVENTS
+	select HAVE_ARM_SCU if SMP
+	select HAVE_ARM_TWD if LOCAL_TIMERS
+	select HAVE_SMP
+	select ARM_GIC
+	select MIGHT_HAVE_CACHE_L2X0
+	select NO_IOPORT
+	select PINCTRL
+	select ARCH_REQUIRE_GPIOLIB
+	select CLKDEV_LOOKUP
+
+if ARCH_SHMOBILE_MULTI
+
+comment "SH-Mobile System Type"
+
+endif
+
 if ARCH_SHMOBILE
 
 comment "SH-Mobile System Type"
--- 0003/arch/arm/mach-shmobile/Makefile
+++ work/arch/arm/mach-shmobile/Makefile	2013-07-08 19:18:20.000000000 +0900
@@ -2,6 +2,8 @@
 # Makefile for the linux kernel.
 #
 
+ccflags-$(CONFIG_ARCH_MULTIPLATFORM) := -I$(srctree)/arch/arm/mach-shmobile/include
+
 # Common objects
 obj-y				:= timer.o console.o
 

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

* [PATCH 03/04] ARM: shmobile: Add EMEV2 and KZM9D to ARCH_SHMOBILE_MULTI
  2013-07-09  5:43 ` Magnus Damm
@ 2013-07-09  5:43   ` Magnus Damm
  -1 siblings, 0 replies; 28+ messages in thread
From: Magnus Damm @ 2013-07-09  5:43 UTC (permalink / raw)
  To: linux-arm-kernel

From: Magnus Damm <damm@opensource.se>

Enable build of EMEV2 and KZM9D DT Reference in
case of ARCH_MULTIPLATFORM and ARCH_SHMOBILE_MULTI.

A weak symbol covers the case when the clock-emev2.c
file is not built when COMMON_CLK=y.

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

 arch/arm/boot/dts/Makefile           |    1 +
 arch/arm/mach-shmobile/Kconfig       |   15 +++++++++++++++
 arch/arm/mach-shmobile/setup-emev2.c |    5 +++++
 3 files changed, 21 insertions(+)

--- 0002/arch/arm/boot/dts/Makefile
+++ work/arch/arm/boot/dts/Makefile	2013-07-09 13:10:52.000000000 +0900
@@ -171,6 +171,7 @@ dtb-$(CONFIG_ARCH_SHMOBILE) += emev2-kzm
 	sh73a0-kzm9g-reference.dtb \
 	r8a73a4-ape6evm.dtb \
 	sh7372-mackerel.dtb
+dtb-$(CONFIG_ARCH_SHMOBILE_MULTI) += emev2-kzm9d-reference.dtb
 dtb-$(CONFIG_ARCH_SOCFPGA) += socfpga_cyclone5.dtb \
 	socfpga_vt.dtb
 dtb-$(CONFIG_ARCH_SPEAR13XX) += spear1310-evb.dtb \
--- 0004/arch/arm/mach-shmobile/Kconfig
+++ work/arch/arm/mach-shmobile/Kconfig	2013-07-09 13:03:45.000000000 +0900
@@ -17,6 +17,21 @@ if ARCH_SHMOBILE_MULTI
 
 comment "SH-Mobile System Type"
 
+config ARCH_EMEV2
+	bool "Emma Mobile EV2"
+
+comment "SH-Mobile Board Type"
+
+config MACH_KZM9D_REFERENCE
+	bool "KZM9D board - Reference Device Tree Implementation"
+	depends on ARCH_EMEV2
+	select REGULATOR_FIXED_VOLTAGE if REGULATOR
+	---help---
+	   Use reference implementation of KZM9D board support
+	   which makes a greater use of device tree at the expense
+	   of not supporting a number of devices.
+
+	   This is intended to aid developers
 endif
 
 if ARCH_SHMOBILE
--- 0001/arch/arm/mach-shmobile/setup-emev2.c
+++ work/arch/arm/mach-shmobile/setup-emev2.c	2013-07-09 13:03:45.000000000 +0900
@@ -190,6 +190,11 @@ void __init emev2_add_standard_devices(v
 	emev2_register_pmu();
 }
 
+void __init __weak emev2_clock_init(void)
+{
+	/* in case legacy clocks are disabled then do nothing */
+}
+
 void __init emev2_init_delay(void)
 {
 	shmobile_setup_delay(533, 1, 3); /* Cortex-A9 @ 533MHz */

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

* [PATCH 03/04] ARM: shmobile: Add EMEV2 and KZM9D to ARCH_SHMOBILE_MULTI
@ 2013-07-09  5:43   ` Magnus Damm
  0 siblings, 0 replies; 28+ messages in thread
From: Magnus Damm @ 2013-07-09  5:43 UTC (permalink / raw)
  To: linux-arm-kernel

From: Magnus Damm <damm@opensource.se>

Enable build of EMEV2 and KZM9D DT Reference in
case of ARCH_MULTIPLATFORM and ARCH_SHMOBILE_MULTI.

A weak symbol covers the case when the clock-emev2.c
file is not built when COMMON_CLK=y.

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

 arch/arm/boot/dts/Makefile           |    1 +
 arch/arm/mach-shmobile/Kconfig       |   15 +++++++++++++++
 arch/arm/mach-shmobile/setup-emev2.c |    5 +++++
 3 files changed, 21 insertions(+)

--- 0002/arch/arm/boot/dts/Makefile
+++ work/arch/arm/boot/dts/Makefile	2013-07-09 13:10:52.000000000 +0900
@@ -171,6 +171,7 @@ dtb-$(CONFIG_ARCH_SHMOBILE) += emev2-kzm
 	sh73a0-kzm9g-reference.dtb \
 	r8a73a4-ape6evm.dtb \
 	sh7372-mackerel.dtb
+dtb-$(CONFIG_ARCH_SHMOBILE_MULTI) += emev2-kzm9d-reference.dtb
 dtb-$(CONFIG_ARCH_SOCFPGA) += socfpga_cyclone5.dtb \
 	socfpga_vt.dtb
 dtb-$(CONFIG_ARCH_SPEAR13XX) += spear1310-evb.dtb \
--- 0004/arch/arm/mach-shmobile/Kconfig
+++ work/arch/arm/mach-shmobile/Kconfig	2013-07-09 13:03:45.000000000 +0900
@@ -17,6 +17,21 @@ if ARCH_SHMOBILE_MULTI
 
 comment "SH-Mobile System Type"
 
+config ARCH_EMEV2
+	bool "Emma Mobile EV2"
+
+comment "SH-Mobile Board Type"
+
+config MACH_KZM9D_REFERENCE
+	bool "KZM9D board - Reference Device Tree Implementation"
+	depends on ARCH_EMEV2
+	select REGULATOR_FIXED_VOLTAGE if REGULATOR
+	---help---
+	   Use reference implementation of KZM9D board support
+	   which makes a greater use of device tree at the expense
+	   of not supporting a number of devices.
+
+	   This is intended to aid developers
 endif
 
 if ARCH_SHMOBILE
--- 0001/arch/arm/mach-shmobile/setup-emev2.c
+++ work/arch/arm/mach-shmobile/setup-emev2.c	2013-07-09 13:03:45.000000000 +0900
@@ -190,6 +190,11 @@ void __init emev2_add_standard_devices(v
 	emev2_register_pmu();
 }
 
+void __init __weak emev2_clock_init(void)
+{
+	/* in case legacy clocks are disabled then do nothing */
+}
+
 void __init emev2_init_delay(void)
 {
 	shmobile_setup_delay(533, 1, 3); /* Cortex-A9 @ 533MHz */

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

* [PATCH 04/04] ARM: shmobile: Allow ARCH_SHMOBILE_MULTI timer configuration
  2013-07-09  5:43 ` Magnus Damm
@ 2013-07-09  5:44   ` Magnus Damm
  -1 siblings, 0 replies; 28+ messages in thread
From: Magnus Damm @ 2013-07-09  5:44 UTC (permalink / raw)
  To: linux-arm-kernel

From: Magnus Damm <damm@opensource.se>

Move the timer configuration bits to allow use in
case of ARCH_SHMOBILE or ARCH_SHMOBILE_MULTI.

The timers all make use of the regular driver model
so they are safe to enable for ARCH_MULTIPLATFORM.

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

 arch/arm/mach-shmobile/Kconfig |   16 +++++++++++-----
 1 file changed, 11 insertions(+), 5 deletions(-)

--- 0005/arch/arm/mach-shmobile/Kconfig
+++ work/arch/arm/mach-shmobile/Kconfig	2013-07-09 12:07:23.000000000 +0900
@@ -30,6 +30,8 @@ config MACH_KZM9D_REFERENCE
 	   of not supporting a number of devices.
 
 	   This is intended to aid developers
+
+comment "SH-Mobile System Configuration"
 endif
 
 if ARCH_SHMOBILE
@@ -243,6 +245,15 @@ config CPU_HAS_INTEVT
         bool
 	default y
 
+config SH_CLK_CPG
+	bool
+
+source "drivers/sh/Kconfig"
+
+endif
+
+if ARCH_SHMOBILE || ARCH_SHMOBILE_MULTI
+
 menu "Timer and clock configuration"
 
 config SHMOBILE_TIMER_HZ
@@ -277,9 +288,4 @@ config EM_TIMER_STI
 
 endmenu
 
-config SH_CLK_CPG
-	bool
-
-source "drivers/sh/Kconfig"
-
 endif

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

* [PATCH 04/04] ARM: shmobile: Allow ARCH_SHMOBILE_MULTI timer configuration
@ 2013-07-09  5:44   ` Magnus Damm
  0 siblings, 0 replies; 28+ messages in thread
From: Magnus Damm @ 2013-07-09  5:44 UTC (permalink / raw)
  To: linux-arm-kernel

From: Magnus Damm <damm@opensource.se>

Move the timer configuration bits to allow use in
case of ARCH_SHMOBILE or ARCH_SHMOBILE_MULTI.

The timers all make use of the regular driver model
so they are safe to enable for ARCH_MULTIPLATFORM.

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

 arch/arm/mach-shmobile/Kconfig |   16 +++++++++++-----
 1 file changed, 11 insertions(+), 5 deletions(-)

--- 0005/arch/arm/mach-shmobile/Kconfig
+++ work/arch/arm/mach-shmobile/Kconfig	2013-07-09 12:07:23.000000000 +0900
@@ -30,6 +30,8 @@ config MACH_KZM9D_REFERENCE
 	   of not supporting a number of devices.
 
 	   This is intended to aid developers
+
+comment "SH-Mobile System Configuration"
 endif
 
 if ARCH_SHMOBILE
@@ -243,6 +245,15 @@ config CPU_HAS_INTEVT
         bool
 	default y
 
+config SH_CLK_CPG
+	bool
+
+source "drivers/sh/Kconfig"
+
+endif
+
+if ARCH_SHMOBILE || ARCH_SHMOBILE_MULTI
+
 menu "Timer and clock configuration"
 
 config SHMOBILE_TIMER_HZ
@@ -277,9 +288,4 @@ config EM_TIMER_STI
 
 endmenu
 
-config SH_CLK_CPG
-	bool
-
-source "drivers/sh/Kconfig"
-
 endif

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

* Re: [PATCH 03/04] ARM: shmobile: Add EMEV2 and KZM9D to ARCH_SHMOBILE_MULTI
  2013-07-09  5:43   ` Magnus Damm
@ 2013-07-09  7:37     ` Arnd Bergmann
  -1 siblings, 0 replies; 28+ messages in thread
From: Arnd Bergmann @ 2013-07-09  7:37 UTC (permalink / raw)
  To: linux-arm-kernel

On Tuesday 09 July 2013, Magnus Damm wrote:
> +void __init __weak emev2_clock_init(void)
> +{
> +       /* in case legacy clocks are disabled then do nothing */
> +}

Nitpicking:

I don't like the __weak symbols too much, in general I prefer
doing either

	if (IS_ENABLED(CONFIG_SHMOBILE_CLOCKS)
		emev2_clock_init()

or using an inline alternative in the header file.

	Arnd

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

* [PATCH 03/04] ARM: shmobile: Add EMEV2 and KZM9D to ARCH_SHMOBILE_MULTI
@ 2013-07-09  7:37     ` Arnd Bergmann
  0 siblings, 0 replies; 28+ messages in thread
From: Arnd Bergmann @ 2013-07-09  7:37 UTC (permalink / raw)
  To: linux-arm-kernel

On Tuesday 09 July 2013, Magnus Damm wrote:
> +void __init __weak emev2_clock_init(void)
> +{
> +       /* in case legacy clocks are disabled then do nothing */
> +}

Nitpicking:

I don't like the __weak symbols too much, in general I prefer
doing either

	if (IS_ENABLED(CONFIG_SHMOBILE_CLOCKS)
		emev2_clock_init()

or using an inline alternative in the header file.

	Arnd

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

* Re: [PATCH 01/04] ARM: shmobile: Only build clocks when COMMON_CLK=n
  2013-07-09  5:43   ` Magnus Damm
@ 2013-07-09  7:43     ` Arnd Bergmann
  -1 siblings, 0 replies; 28+ messages in thread
From: Arnd Bergmann @ 2013-07-09  7:43 UTC (permalink / raw)
  To: linux-arm-kernel

On Tuesday 09 July 2013, Magnus Damm wrote:
> +obj-y                          += $(clk-y$(CONFIG_COMMON_CLK))

It took me a bit to understand the Makefile trick you are using here.
I assume other readers will have the same problem. How about just
doing

+ifndef CONFIG_COMMON_CLK
 obj-$(CONFIG_ARCH_SH7372)      += setup-sh7372.o intc-sh7372.o
 obj-$(CONFIG_ARCH_SH73A0)      += setup-sh73a0.o intc-sh73a0.o
 obj-$(CONFIG_ARCH_R8A73A4)     += setup-r8a73a4.o
 obj-$(CONFIG_ARCH_R8A7740)     += setup-r8a7740.o intc-r8a7740.o
 obj-$(CONFIG_ARCH_R8A7778)     += setup-r8a7778.o
 obj-$(CONFIG_ARCH_R8A7779)     += setup-r8a7779.o intc-r8a7779.o
 obj-$(CONFIG_ARCH_R8A7790)     += setup-r8a7790.o
 obj-$(CONFIG_ARCH_EMEV2)       += setup-emev2.o
+endif

	Arnd

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

* [PATCH 01/04] ARM: shmobile: Only build clocks when COMMON_CLK=n
@ 2013-07-09  7:43     ` Arnd Bergmann
  0 siblings, 0 replies; 28+ messages in thread
From: Arnd Bergmann @ 2013-07-09  7:43 UTC (permalink / raw)
  To: linux-arm-kernel

On Tuesday 09 July 2013, Magnus Damm wrote:
> +obj-y                          += $(clk-y$(CONFIG_COMMON_CLK))

It took me a bit to understand the Makefile trick you are using here.
I assume other readers will have the same problem. How about just
doing

+ifndef CONFIG_COMMON_CLK
 obj-$(CONFIG_ARCH_SH7372)      += setup-sh7372.o intc-sh7372.o
 obj-$(CONFIG_ARCH_SH73A0)      += setup-sh73a0.o intc-sh73a0.o
 obj-$(CONFIG_ARCH_R8A73A4)     += setup-r8a73a4.o
 obj-$(CONFIG_ARCH_R8A7740)     += setup-r8a7740.o intc-r8a7740.o
 obj-$(CONFIG_ARCH_R8A7778)     += setup-r8a7778.o
 obj-$(CONFIG_ARCH_R8A7779)     += setup-r8a7779.o intc-r8a7779.o
 obj-$(CONFIG_ARCH_R8A7790)     += setup-r8a7790.o
 obj-$(CONFIG_ARCH_EMEV2)       += setup-emev2.o
+endif

	Arnd

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

* Re: [PATCH 00/04] ARM: shmobile: ARCH_MULTIPLATFORM for EMEV2 and KZM9D
  2013-07-09  5:43 ` Magnus Damm
@ 2013-07-09  7:45   ` Arnd Bergmann
  -1 siblings, 0 replies; 28+ messages in thread
From: Arnd Bergmann @ 2013-07-09  7:45 UTC (permalink / raw)
  To: linux-arm-kernel

On Tuesday 09 July 2013, Magnus Damm wrote:
> ARM: shmobile: ARCH_MULTIPLATFORM for EMEV2 and KZM9D
> 
> [PATCH 01/04] ARM: shmobile: Only build clocks when COMMON_CLK=n
> [PATCH 02/04] ARM: shmobile: Introduce ARCH_SHMOBILE_MULTI
> [PATCH 03/04] ARM: shmobile: Add EMEV2 and KZM9D to ARCH_SHMOBILE_MULTI
> [PATCH 04/04] ARM: shmobile: Allow ARCH_SHMOBILE_MULTI timer configuration
> 
> This patch set extends mach-shmobile to allow a subset of SoCs and
> boards to be built for ARCH_MULTIPLATFORM. With this series applied
> the EMEV2 SoC and the KZM9D board can be built in two ways - either
> as good old ARCH_SHMOBILE or new ARCH_SHMOBILE_MULTI. The latter
> requires common clock framework for proper run time operation.
> 
> The goal is to over time move all DT reference implementations from
> ARCH_SHMOBILE to ARCH_SHMOBILE_MULTI. Until CCF is available for a
> certain SoC it is to me acceptable for a DT reference board to allow
> build in both ARCH_SHMOBILE and ARCH_SHMOBILE_MULTI. The reason for
> this is to allow incremental development and easy testing during
> development of CCF for a certain SoC. The KZM9D board is now in this
> state while it is waiting for common clocks to become ready.
> 
> In the near future a prototype hack will be posted that comments
> out the clock framework bits on EMEV2 and will allow boot of KZM9D
> in the case of ARCH_SHMOBILE_MULTI even though CCF is not yet
> available.
> 
> Signed-off-by: Magnus Damm <damm@opensource.se>

Great stuff, very glad you got this far!

I have two small style comments, nothing important.

	Arnd

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

* [PATCH 00/04] ARM: shmobile: ARCH_MULTIPLATFORM for EMEV2 and KZM9D
@ 2013-07-09  7:45   ` Arnd Bergmann
  0 siblings, 0 replies; 28+ messages in thread
From: Arnd Bergmann @ 2013-07-09  7:45 UTC (permalink / raw)
  To: linux-arm-kernel

On Tuesday 09 July 2013, Magnus Damm wrote:
> ARM: shmobile: ARCH_MULTIPLATFORM for EMEV2 and KZM9D
> 
> [PATCH 01/04] ARM: shmobile: Only build clocks when COMMON_CLK=n
> [PATCH 02/04] ARM: shmobile: Introduce ARCH_SHMOBILE_MULTI
> [PATCH 03/04] ARM: shmobile: Add EMEV2 and KZM9D to ARCH_SHMOBILE_MULTI
> [PATCH 04/04] ARM: shmobile: Allow ARCH_SHMOBILE_MULTI timer configuration
> 
> This patch set extends mach-shmobile to allow a subset of SoCs and
> boards to be built for ARCH_MULTIPLATFORM. With this series applied
> the EMEV2 SoC and the KZM9D board can be built in two ways - either
> as good old ARCH_SHMOBILE or new ARCH_SHMOBILE_MULTI. The latter
> requires common clock framework for proper run time operation.
> 
> The goal is to over time move all DT reference implementations from
> ARCH_SHMOBILE to ARCH_SHMOBILE_MULTI. Until CCF is available for a
> certain SoC it is to me acceptable for a DT reference board to allow
> build in both ARCH_SHMOBILE and ARCH_SHMOBILE_MULTI. The reason for
> this is to allow incremental development and easy testing during
> development of CCF for a certain SoC. The KZM9D board is now in this
> state while it is waiting for common clocks to become ready.
> 
> In the near future a prototype hack will be posted that comments
> out the clock framework bits on EMEV2 and will allow boot of KZM9D
> in the case of ARCH_SHMOBILE_MULTI even though CCF is not yet
> available.
> 
> Signed-off-by: Magnus Damm <damm@opensource.se>

Great stuff, very glad you got this far!

I have two small style comments, nothing important.

	Arnd

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

* Re: [PATCH 01/04] ARM: shmobile: Only build clocks when COMMON_CLK=n
  2013-07-09  7:43     ` Arnd Bergmann
@ 2013-07-09  7:45       ` Laurent Pinchart
  -1 siblings, 0 replies; 28+ messages in thread
From: Laurent Pinchart @ 2013-07-09  7:45 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Arnd and Magnus,

On Tuesday 09 July 2013 09:43:07 Arnd Bergmann wrote:
> On Tuesday 09 July 2013, Magnus Damm wrote:
> > +obj-y                          += $(clk-y$(CONFIG_COMMON_CLK))
> 
> It took me a bit to understand the Makefile trick you are using here.
> I assume other readers will have the same problem. How about just
> doing
> 
> +ifndef CONFIG_COMMON_CLK
>  obj-$(CONFIG_ARCH_SH7372)      += setup-sh7372.o intc-sh7372.o
>  obj-$(CONFIG_ARCH_SH73A0)      += setup-sh73a0.o intc-sh73a0.o
>  obj-$(CONFIG_ARCH_R8A73A4)     += setup-r8a73a4.o
>  obj-$(CONFIG_ARCH_R8A7740)     += setup-r8a7740.o intc-r8a7740.o
>  obj-$(CONFIG_ARCH_R8A7778)     += setup-r8a7778.o
>  obj-$(CONFIG_ARCH_R8A7779)     += setup-r8a7779.o intc-r8a7779.o
>  obj-$(CONFIG_ARCH_R8A7790)     += setup-r8a7790.o
>  obj-$(CONFIG_ARCH_EMEV2)       += setup-emev2.o
> +endif

I was about to mention the same, so I think that would be a good idea.

-- 
Regards,

Laurent Pinchart


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

* [PATCH 01/04] ARM: shmobile: Only build clocks when COMMON_CLK=n
@ 2013-07-09  7:45       ` Laurent Pinchart
  0 siblings, 0 replies; 28+ messages in thread
From: Laurent Pinchart @ 2013-07-09  7:45 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Arnd and Magnus,

On Tuesday 09 July 2013 09:43:07 Arnd Bergmann wrote:
> On Tuesday 09 July 2013, Magnus Damm wrote:
> > +obj-y                          += $(clk-y$(CONFIG_COMMON_CLK))
> 
> It took me a bit to understand the Makefile trick you are using here.
> I assume other readers will have the same problem. How about just
> doing
> 
> +ifndef CONFIG_COMMON_CLK
>  obj-$(CONFIG_ARCH_SH7372)      += setup-sh7372.o intc-sh7372.o
>  obj-$(CONFIG_ARCH_SH73A0)      += setup-sh73a0.o intc-sh73a0.o
>  obj-$(CONFIG_ARCH_R8A73A4)     += setup-r8a73a4.o
>  obj-$(CONFIG_ARCH_R8A7740)     += setup-r8a7740.o intc-r8a7740.o
>  obj-$(CONFIG_ARCH_R8A7778)     += setup-r8a7778.o
>  obj-$(CONFIG_ARCH_R8A7779)     += setup-r8a7779.o intc-r8a7779.o
>  obj-$(CONFIG_ARCH_R8A7790)     += setup-r8a7790.o
>  obj-$(CONFIG_ARCH_EMEV2)       += setup-emev2.o
> +endif

I was about to mention the same, so I think that would be a good idea.

-- 
Regards,

Laurent Pinchart

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

* Re: [PATCH 01/04] ARM: shmobile: Only build clocks when COMMON_CLK=n
  2013-07-09  7:45       ` Laurent Pinchart
@ 2013-07-09  9:09         ` Magnus Damm
  -1 siblings, 0 replies; 28+ messages in thread
From: Magnus Damm @ 2013-07-09  9:09 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Laurent and Arnd,

On Tue, Jul 9, 2013 at 4:45 PM, Laurent Pinchart
<laurent.pinchart@ideasonboard.com> wrote:
> Hi Arnd and Magnus,
>
> On Tuesday 09 July 2013 09:43:07 Arnd Bergmann wrote:
>> On Tuesday 09 July 2013, Magnus Damm wrote:
>> > +obj-y                          += $(clk-y$(CONFIG_COMMON_CLK))
>>
>> It took me a bit to understand the Makefile trick you are using here.
>> I assume other readers will have the same problem. How about just
>> doing
>>
>> +ifndef CONFIG_COMMON_CLK
>>  obj-$(CONFIG_ARCH_SH7372)      += setup-sh7372.o intc-sh7372.o
>>  obj-$(CONFIG_ARCH_SH73A0)      += setup-sh73a0.o intc-sh73a0.o
>>  obj-$(CONFIG_ARCH_R8A73A4)     += setup-r8a73a4.o
>>  obj-$(CONFIG_ARCH_R8A7740)     += setup-r8a7740.o intc-r8a7740.o
>>  obj-$(CONFIG_ARCH_R8A7778)     += setup-r8a7778.o
>>  obj-$(CONFIG_ARCH_R8A7779)     += setup-r8a7779.o intc-r8a7779.o
>>  obj-$(CONFIG_ARCH_R8A7790)     += setup-r8a7790.o
>>  obj-$(CONFIG_ARCH_EMEV2)       += setup-emev2.o
>> +endif
>
> I was about to mention the same, so I think that would be a good idea.

Sure, that may be a more common way to handle this. =)

To be clear, I assume you wanted that ifndef to cover the clock-xxx.c
files instead of setup-xxx.c. So I will do that in next version.

Thanks for your comments!

Cheers,

/ magnus

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

* [PATCH 01/04] ARM: shmobile: Only build clocks when COMMON_CLK=n
@ 2013-07-09  9:09         ` Magnus Damm
  0 siblings, 0 replies; 28+ messages in thread
From: Magnus Damm @ 2013-07-09  9:09 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Laurent and Arnd,

On Tue, Jul 9, 2013 at 4:45 PM, Laurent Pinchart
<laurent.pinchart@ideasonboard.com> wrote:
> Hi Arnd and Magnus,
>
> On Tuesday 09 July 2013 09:43:07 Arnd Bergmann wrote:
>> On Tuesday 09 July 2013, Magnus Damm wrote:
>> > +obj-y                          += $(clk-y$(CONFIG_COMMON_CLK))
>>
>> It took me a bit to understand the Makefile trick you are using here.
>> I assume other readers will have the same problem. How about just
>> doing
>>
>> +ifndef CONFIG_COMMON_CLK
>>  obj-$(CONFIG_ARCH_SH7372)      += setup-sh7372.o intc-sh7372.o
>>  obj-$(CONFIG_ARCH_SH73A0)      += setup-sh73a0.o intc-sh73a0.o
>>  obj-$(CONFIG_ARCH_R8A73A4)     += setup-r8a73a4.o
>>  obj-$(CONFIG_ARCH_R8A7740)     += setup-r8a7740.o intc-r8a7740.o
>>  obj-$(CONFIG_ARCH_R8A7778)     += setup-r8a7778.o
>>  obj-$(CONFIG_ARCH_R8A7779)     += setup-r8a7779.o intc-r8a7779.o
>>  obj-$(CONFIG_ARCH_R8A7790)     += setup-r8a7790.o
>>  obj-$(CONFIG_ARCH_EMEV2)       += setup-emev2.o
>> +endif
>
> I was about to mention the same, so I think that would be a good idea.

Sure, that may be a more common way to handle this. =)

To be clear, I assume you wanted that ifndef to cover the clock-xxx.c
files instead of setup-xxx.c. So I will do that in next version.

Thanks for your comments!

Cheers,

/ magnus

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

* Re: [PATCH 00/04] ARM: shmobile: ARCH_MULTIPLATFORM for EMEV2 and KZM9D
  2013-07-09  7:45   ` Arnd Bergmann
@ 2013-07-09  9:11     ` Magnus Damm
  -1 siblings, 0 replies; 28+ messages in thread
From: Magnus Damm @ 2013-07-09  9:11 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Jul 9, 2013 at 4:45 PM, Arnd Bergmann <arnd@arndb.de> wrote:
> On Tuesday 09 July 2013, Magnus Damm wrote:
>> ARM: shmobile: ARCH_MULTIPLATFORM for EMEV2 and KZM9D
>>
>> [PATCH 01/04] ARM: shmobile: Only build clocks when COMMON_CLK=n
>> [PATCH 02/04] ARM: shmobile: Introduce ARCH_SHMOBILE_MULTI
>> [PATCH 03/04] ARM: shmobile: Add EMEV2 and KZM9D to ARCH_SHMOBILE_MULTI
>> [PATCH 04/04] ARM: shmobile: Allow ARCH_SHMOBILE_MULTI timer configuration
>>
>> This patch set extends mach-shmobile to allow a subset of SoCs and
>> boards to be built for ARCH_MULTIPLATFORM. With this series applied
>> the EMEV2 SoC and the KZM9D board can be built in two ways - either
>> as good old ARCH_SHMOBILE or new ARCH_SHMOBILE_MULTI. The latter
>> requires common clock framework for proper run time operation.
>>
>> The goal is to over time move all DT reference implementations from
>> ARCH_SHMOBILE to ARCH_SHMOBILE_MULTI. Until CCF is available for a
>> certain SoC it is to me acceptable for a DT reference board to allow
>> build in both ARCH_SHMOBILE and ARCH_SHMOBILE_MULTI. The reason for
>> this is to allow incremental development and easy testing during
>> development of CCF for a certain SoC. The KZM9D board is now in this
>> state while it is waiting for common clocks to become ready.
>>
>> In the near future a prototype hack will be posted that comments
>> out the clock framework bits on EMEV2 and will allow boot of KZM9D
>> in the case of ARCH_SHMOBILE_MULTI even though CCF is not yet
>> available.
>>
>> Signed-off-by: Magnus Damm <damm@opensource.se>
>
> Great stuff, very glad you got this far!

Thanks, I'm happy to hear that!

> I have two small style comments, nothing important.

Sure, I will fix up and resend. Thanks for your feedback!

/ magnus

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

* [PATCH 00/04] ARM: shmobile: ARCH_MULTIPLATFORM for EMEV2 and KZM9D
@ 2013-07-09  9:11     ` Magnus Damm
  0 siblings, 0 replies; 28+ messages in thread
From: Magnus Damm @ 2013-07-09  9:11 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Jul 9, 2013 at 4:45 PM, Arnd Bergmann <arnd@arndb.de> wrote:
> On Tuesday 09 July 2013, Magnus Damm wrote:
>> ARM: shmobile: ARCH_MULTIPLATFORM for EMEV2 and KZM9D
>>
>> [PATCH 01/04] ARM: shmobile: Only build clocks when COMMON_CLK=n
>> [PATCH 02/04] ARM: shmobile: Introduce ARCH_SHMOBILE_MULTI
>> [PATCH 03/04] ARM: shmobile: Add EMEV2 and KZM9D to ARCH_SHMOBILE_MULTI
>> [PATCH 04/04] ARM: shmobile: Allow ARCH_SHMOBILE_MULTI timer configuration
>>
>> This patch set extends mach-shmobile to allow a subset of SoCs and
>> boards to be built for ARCH_MULTIPLATFORM. With this series applied
>> the EMEV2 SoC and the KZM9D board can be built in two ways - either
>> as good old ARCH_SHMOBILE or new ARCH_SHMOBILE_MULTI. The latter
>> requires common clock framework for proper run time operation.
>>
>> The goal is to over time move all DT reference implementations from
>> ARCH_SHMOBILE to ARCH_SHMOBILE_MULTI. Until CCF is available for a
>> certain SoC it is to me acceptable for a DT reference board to allow
>> build in both ARCH_SHMOBILE and ARCH_SHMOBILE_MULTI. The reason for
>> this is to allow incremental development and easy testing during
>> development of CCF for a certain SoC. The KZM9D board is now in this
>> state while it is waiting for common clocks to become ready.
>>
>> In the near future a prototype hack will be posted that comments
>> out the clock framework bits on EMEV2 and will allow boot of KZM9D
>> in the case of ARCH_SHMOBILE_MULTI even though CCF is not yet
>> available.
>>
>> Signed-off-by: Magnus Damm <damm@opensource.se>
>
> Great stuff, very glad you got this far!

Thanks, I'm happy to hear that!

> I have two small style comments, nothing important.

Sure, I will fix up and resend. Thanks for your feedback!

/ magnus

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

* Re: [PATCH 03/04] ARM: shmobile: Add EMEV2 and KZM9D to ARCH_SHMOBILE_MULTI
  2013-07-09  7:37     ` Arnd Bergmann
@ 2013-07-09  9:15       ` Magnus Damm
  -1 siblings, 0 replies; 28+ messages in thread
From: Magnus Damm @ 2013-07-09  9:15 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Arnd,

On Tue, Jul 9, 2013 at 4:37 PM, Arnd Bergmann <arnd@arndb.de> wrote:
> On Tuesday 09 July 2013, Magnus Damm wrote:
>> +void __init __weak emev2_clock_init(void)
>> +{
>> +       /* in case legacy clocks are disabled then do nothing */
>> +}
>
> Nitpicking:
>
> I don't like the __weak symbols too much, in general I prefer
> doing either
>
>         if (IS_ENABLED(CONFIG_SHMOBILE_CLOCKS)
>                 emev2_clock_init()
>
> or using an inline alternative in the header file.

Sure, good idea. I plan on using the following if you don't mind:

         if (!IS_ENABLED(CONFIG_COMMON_CLK)
                 emev2_clock_init()

Cheers,

/ magnus

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

* [PATCH 03/04] ARM: shmobile: Add EMEV2 and KZM9D to ARCH_SHMOBILE_MULTI
@ 2013-07-09  9:15       ` Magnus Damm
  0 siblings, 0 replies; 28+ messages in thread
From: Magnus Damm @ 2013-07-09  9:15 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Arnd,

On Tue, Jul 9, 2013 at 4:37 PM, Arnd Bergmann <arnd@arndb.de> wrote:
> On Tuesday 09 July 2013, Magnus Damm wrote:
>> +void __init __weak emev2_clock_init(void)
>> +{
>> +       /* in case legacy clocks are disabled then do nothing */
>> +}
>
> Nitpicking:
>
> I don't like the __weak symbols too much, in general I prefer
> doing either
>
>         if (IS_ENABLED(CONFIG_SHMOBILE_CLOCKS)
>                 emev2_clock_init()
>
> or using an inline alternative in the header file.

Sure, good idea. I plan on using the following if you don't mind:

         if (!IS_ENABLED(CONFIG_COMMON_CLK)
                 emev2_clock_init()

Cheers,

/ magnus

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

* Re: [PATCH 01/04] ARM: shmobile: Only build clocks when COMMON_CLK=n
  2013-07-09  9:09         ` Magnus Damm
@ 2013-07-09 21:06           ` Arnd Bergmann
  -1 siblings, 0 replies; 28+ messages in thread
From: Arnd Bergmann @ 2013-07-09 21:06 UTC (permalink / raw)
  To: linux-arm-kernel

On Tuesday 09 July 2013, Magnus Damm wrote:
> >>
> >> +ifndef CONFIG_COMMON_CLK
> >>  obj-$(CONFIG_ARCH_SH7372)      += setup-sh7372.o intc-sh7372.o
> >>  obj-$(CONFIG_ARCH_SH73A0)      += setup-sh73a0.o intc-sh73a0.o
> >>  obj-$(CONFIG_ARCH_R8A73A4)     += setup-r8a73a4.o
> >>  obj-$(CONFIG_ARCH_R8A7740)     += setup-r8a7740.o intc-r8a7740.o
> >>  obj-$(CONFIG_ARCH_R8A7778)     += setup-r8a7778.o
> >>  obj-$(CONFIG_ARCH_R8A7779)     += setup-r8a7779.o intc-r8a7779.o
> >>  obj-$(CONFIG_ARCH_R8A7790)     += setup-r8a7790.o
> >>  obj-$(CONFIG_ARCH_EMEV2)       += setup-emev2.o
> >> +endif
> >
> > I was about to mention the same, so I think that would be a good idea.
> 
> Sure, that may be a more common way to handle this. =)
> 
> To be clear, I assume you wanted that ifndef to cover the clock-xxx.c
> files instead of setup-xxx.c. So I will do that in next version.
> 

Yes, that's right, sorry for screwing up the example.

	Arnd

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

* [PATCH 01/04] ARM: shmobile: Only build clocks when COMMON_CLK=n
@ 2013-07-09 21:06           ` Arnd Bergmann
  0 siblings, 0 replies; 28+ messages in thread
From: Arnd Bergmann @ 2013-07-09 21:06 UTC (permalink / raw)
  To: linux-arm-kernel

On Tuesday 09 July 2013, Magnus Damm wrote:
> >>
> >> +ifndef CONFIG_COMMON_CLK
> >>  obj-$(CONFIG_ARCH_SH7372)      += setup-sh7372.o intc-sh7372.o
> >>  obj-$(CONFIG_ARCH_SH73A0)      += setup-sh73a0.o intc-sh73a0.o
> >>  obj-$(CONFIG_ARCH_R8A73A4)     += setup-r8a73a4.o
> >>  obj-$(CONFIG_ARCH_R8A7740)     += setup-r8a7740.o intc-r8a7740.o
> >>  obj-$(CONFIG_ARCH_R8A7778)     += setup-r8a7778.o
> >>  obj-$(CONFIG_ARCH_R8A7779)     += setup-r8a7779.o intc-r8a7779.o
> >>  obj-$(CONFIG_ARCH_R8A7790)     += setup-r8a7790.o
> >>  obj-$(CONFIG_ARCH_EMEV2)       += setup-emev2.o
> >> +endif
> >
> > I was about to mention the same, so I think that would be a good idea.
> 
> Sure, that may be a more common way to handle this. =)
> 
> To be clear, I assume you wanted that ifndef to cover the clock-xxx.c
> files instead of setup-xxx.c. So I will do that in next version.
> 

Yes, that's right, sorry for screwing up the example.

	Arnd

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

* Re: [PATCH 03/04] ARM: shmobile: Add EMEV2 and KZM9D to ARCH_SHMOBILE_MULTI
  2013-07-09  9:15       ` Magnus Damm
@ 2013-07-09 21:07         ` Arnd Bergmann
  -1 siblings, 0 replies; 28+ messages in thread
From: Arnd Bergmann @ 2013-07-09 21:07 UTC (permalink / raw)
  To: linux-arm-kernel

On Tuesday 09 July 2013, Magnus Damm wrote:
> Sure, good idea. I plan on using the following if you don't mind:
> 
>          if (!IS_ENABLED(CONFIG_COMMON_CLK)
>                  emev2_clock_init()
> 

Yes, looks good.

	Arnd

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

* [PATCH 03/04] ARM: shmobile: Add EMEV2 and KZM9D to ARCH_SHMOBILE_MULTI
@ 2013-07-09 21:07         ` Arnd Bergmann
  0 siblings, 0 replies; 28+ messages in thread
From: Arnd Bergmann @ 2013-07-09 21:07 UTC (permalink / raw)
  To: linux-arm-kernel

On Tuesday 09 July 2013, Magnus Damm wrote:
> Sure, good idea. I plan on using the following if you don't mind:
> 
>          if (!IS_ENABLED(CONFIG_COMMON_CLK)
>                  emev2_clock_init()
> 

Yes, looks good.

	Arnd

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

end of thread, other threads:[~2013-07-09 21:07 UTC | newest]

Thread overview: 28+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-07-09  5:43 [PATCH 00/04] ARM: shmobile: ARCH_MULTIPLATFORM for EMEV2 and KZM9D Magnus Damm
2013-07-09  5:43 ` Magnus Damm
2013-07-09  5:43 ` [PATCH 01/04] ARM: shmobile: Only build clocks when COMMON_CLK=n Magnus Damm
2013-07-09  5:43   ` Magnus Damm
2013-07-09  7:43   ` Arnd Bergmann
2013-07-09  7:43     ` Arnd Bergmann
2013-07-09  7:45     ` Laurent Pinchart
2013-07-09  7:45       ` Laurent Pinchart
2013-07-09  9:09       ` Magnus Damm
2013-07-09  9:09         ` Magnus Damm
2013-07-09 21:06         ` Arnd Bergmann
2013-07-09 21:06           ` Arnd Bergmann
2013-07-09  5:43 ` [PATCH 02/04] ARM: shmobile: Introduce ARCH_SHMOBILE_MULTI Magnus Damm
2013-07-09  5:43   ` Magnus Damm
2013-07-09  5:43 ` [PATCH 03/04] ARM: shmobile: Add EMEV2 and KZM9D to ARCH_SHMOBILE_MULTI Magnus Damm
2013-07-09  5:43   ` Magnus Damm
2013-07-09  7:37   ` Arnd Bergmann
2013-07-09  7:37     ` Arnd Bergmann
2013-07-09  9:15     ` Magnus Damm
2013-07-09  9:15       ` Magnus Damm
2013-07-09 21:07       ` Arnd Bergmann
2013-07-09 21:07         ` Arnd Bergmann
2013-07-09  5:44 ` [PATCH 04/04] ARM: shmobile: Allow ARCH_SHMOBILE_MULTI timer configuration Magnus Damm
2013-07-09  5:44   ` Magnus Damm
2013-07-09  7:45 ` [PATCH 00/04] ARM: shmobile: ARCH_MULTIPLATFORM for EMEV2 and KZM9D Arnd Bergmann
2013-07-09  7:45   ` Arnd Bergmann
2013-07-09  9:11   ` Magnus Damm
2013-07-09  9:11     ` Magnus Damm

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.