ARM: shmobile: Let CPG use syscon for MD pin values
Subsystems (6)
Geert Uytterhoeven
maintainercover ARM: shmobile: Let CPG use syscon for MD pin values
Hi,
Currently the R-Car Gen2 Clock Pulse Generator (CPG) driver obtains the values of the MD pins by a direct call from the R-Car Gen2 platform code. This is a bit messy, and creates a dependency between driver and platform code.
This RFC patch series makes the CPG driver obtain the MD pin values by reading the Mode Monitoring Register (MODEMR) using syscon and regmap instead. The syscon device and register offset to use are obtained from the "renesas,modemr" property in DT, which contains a phandle to the Reset Controller module, and the register offset of the MODEMR register inside the RST module's register block.
For backward-compatibility with old DTs, a fallback is added to call rcar_gen2_read_mode_pins() in the R-Car Gen2 platform code when needed. Once backward-compatibility is deemed no longer necessary, the call to rcar_gen2_read_mode_pins() can be removed.
Patches:
- Patch 1 adds syscon/regmap support to the CPG driver,
- Patches 2-5 add device nodes for the RST modules on all R-Car Gen2 SoCs,
- Patches 6-9 add "renesas,modemr" links on all R-Car Gen2 SoCs,
- Patch 10 removes the old call from platform code to CPG driver,
- Patch 11 removes the obsolete code called by the platform code from the CPG driver.
TODO:
- Write DT binding docs for the RST Reset Controller Module,
- Document the "renesas,modemr" DT property in the R-Car Gen2 CPG DT binding docs,
- Extend this technique to R-Car Gen1 (r8a7778/r8a7779) and RZ
(r7s72100) SoCs.
Dependencies:
- This patch series is against my local tree, which a.o. contains the R-Car Gen2 CPG/MSTP Clock Domain and R-Car Gen2 SYSC PM Domain patches. This mostly impacts the .dtsi patches. But there's no functional dependency, only contextually.
- Patch 10 (run-time) depends on patches 1-9,
- Patch 11 (build-time) depends on patch 10.
Geert Uytterhoeven (11):
clk: shmobile: rcar-gen2: Obtain MD pin values using syscon/regmap
ARM: shmobile: r8a7790 dtsi: Add device node for RST module
ARM: shmobile: r8a7791 dtsi: Add device node for RST module
ARM: shmobile: r8a7793 dtsi: Add device node for RST module
ARM: shmobile: r8a7794 dtsi: Add device node for RST module
ARM: shmobile: r8a7790: Link CPG to RST using "renesas,modemr"
ARM: shmobile: r8a7791: Link CPG to RST using "renesas,modemr"
ARM: shmobile: r8a7793: Link CPG to RST using "renesas,modemr"
ARM: shmobile: r8a7794: Link CPG to RST using "renesas,modemr"
ARM: shmobile: rcar-gen2: Use syscon to configure the CPG
clk: shmobile: rcar-gen2: Remove obsolete rcar_gen2_clocks_init()
arch/arm/boot/dts/r8a7790.dtsi | 6 ++++++ arch/arm/boot/dts/r8a7791.dtsi | 6 ++++++ arch/arm/boot/dts/r8a7793.dtsi | 6 ++++++ arch/arm/boot/dts/r8a7794.dtsi | 6 ++++++ arch/arm/mach-shmobile/Kconfig | 1 + arch/arm/mach-shmobile/setup-rcar-gen2.c | 3 ++- drivers/clk/shmobile/clk-rcar-gen2.c | 22 +++++++++++++++------- include/linux/clk/shmobile.h | 1 - 8 files changed, 42 insertions(+), 9 deletions(-)
Signature · 12 lines
1.9.1
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert at linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus TorvaldsGeert Uytterhoeven
maintainerPATCH 1/11 clk: shmobile: rcar-gen2: Obtain MD pin values using syscon/regmap
Obtain the values of the MD pins by reading the Mode Monitoring Register (MODEMR) using syscon and regmap. The syscon device and register offset to use are obtained from the "renesas,modemr" property in DT.
Fall back to calling rcar_gen2_read_mode_pins() in the R-Car Gen2 platform code for backward-compatibility with old DTs.
TODO Document "renesas,modemr" property in DT binding doc.
--- drivers/clk/shmobile/clk-rcar-gen2.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+)
drivers/clk/shmobile/clk-rcar-gen2.c +15 -0
@@ -15,8 +15,10 @@#include <linux/init.h> #include <linux/kernel.h> #include <linux/math64.h> +#include <linux/mfd/syscon.h> #include <linux/of.h> #include <linux/of_address.h> +#include <linux/regmap.h> #include <linux/slab.h> #include <linux/spinlock.h>
@@ -368,9 +370,22 @@ static void __init rcar_gen2_cpg_clocks_init(struct device_node *np) {const struct cpg_pll_config *config;struct rcar_gen2_cpg *cpg; +struct regmap *regmap;struct clk **clks;unsigned int i;int num_clks; +u32 reg; + + regmap =syscon_regmap_lookup_by_phandle (np,"renesas,modemr" ); +if (IS_ERR (regmap) || +of_property_read_u32_index (np,"renesas,modemr" ,1 , ®) || +regmap_read (regmap, reg, &cpg_mode)) { +/* Backward-compatibility with old DT */ +extern u32 rcar_gen2_read_mode_pins (void ); + +pr_warn ("%s: failed to parse renesas,modemr\n" , np->full_name); + cpg_mode =rcar_gen2_read_mode_pins (); + } num_clks =of_property_count_strings (np,"clock-output-names" );if (num_clks <0 ) {
Signature · 1 line
1.9.1
Geert Uytterhoeven
maintainerPATCH 2/11 ARM: shmobile: r8a7790 dtsi: Add device node for RST module
In reply to Geert UytterhoevenAdd a device node for the RST module, which provides reset control. Declare it to be a system controller (syscon), so other device nodes can refer to its registers.
TODO Add DT binding documentation.
--- arch/arm/boot/dts/r8a7790.dtsi | 5 +++++ 1 file changed, 5 insertions(+)
arch/arm/boot/dts/r8a7790.dtsi +5 -0
@@ -1495,6 +1495,11 @@ }; }; + rst: reset-controller at e616000 { + compatible = "renesas,rst-r8a7790", "syscon"; + reg = <0 0xe6160000 0 0x0100>; + }; + sysc: system-controller at e6180000 { compatible = "renesas,sysc-r8a7790", "renesas,sysc-rcar"; reg = <0 0xe6180000 0 0x0200>;
Signature · 1 line
1.9.1
Geert Uytterhoeven
maintainerPATCH 3/11 ARM: shmobile: r8a7791 dtsi: Add device node for RST module
In reply to Geert UytterhoevenAdd a device node for the RST module, which provides reset control. Declare it to be a system controller (syscon), so other device nodes can refer to its registers.
TODO Add DT binding documentation.
--- arch/arm/boot/dts/r8a7791.dtsi | 5 +++++ 1 file changed, 5 insertions(+)
arch/arm/boot/dts/r8a7791.dtsi +5 -0
@@ -1405,6 +1405,11 @@ }; }; + rst: reset-controller at e616000 { + compatible = "renesas,rst-r8a7791", "syscon"; + reg = <0 0xe6160000 0 0x0100>; + }; + sysc: system-controller at e6180000 { compatible = "renesas,sysc-r8a7791", "renesas,sysc-rcar"; reg = <0 0xe6180000 0 0x0200>;
Signature · 1 line
1.9.1
Geert Uytterhoeven
maintainerPATCH 4/11 ARM: shmobile: r8a7793 dtsi: Add device node for RST module
In reply to Geert UytterhoevenAdd a device node for the RST module, which provides reset control. Declare it to be a system controller (syscon), so other device nodes can refer to its registers.
TODO Add DT binding documentation.
--- arch/arm/boot/dts/r8a7793.dtsi | 5 +++++ 1 file changed, 5 insertions(+)
arch/arm/boot/dts/r8a7793.dtsi +5 -0
@@ -394,6 +394,11 @@ }; }; + rst: reset-controller at e616000 { + compatible = "renesas,rst-r8a7793", "syscon"; + reg = <0 0xe6160000 0 0x0100>; + }; + sysc: system-controller at e6180000 { compatible = "renesas,sysc-r8a7793", "renesas,sysc-rcar"; reg = <0 0xe6180000 0 0x0200>;
Signature · 1 line
1.9.1
Geert Uytterhoeven
maintainerPATCH 5/11 ARM: shmobile: r8a7794 dtsi: Add device node for RST module
In reply to Geert UytterhoevenAdd a device node for the RST module, which provides reset control. Declare it to be a system controller (syscon), so other device nodes can refer to its registers.
TODO Add DT binding documentation.
--- arch/arm/boot/dts/r8a7794.dtsi | 5 +++++ 1 file changed, 5 insertions(+)
arch/arm/boot/dts/r8a7794.dtsi +5 -0
@@ -786,6 +786,11 @@ }; }; + rst: reset-controller at e616000 { + compatible = "renesas,rst-r8a7794", "syscon"; + reg = <0 0xe6160000 0 0x0100>; + }; + sysc: system-controller at e6180000 { compatible = "renesas,sysc-r8a7794", "renesas,sysc-rcar"; reg = <0 0xe6180000 0 0x0200>;
Signature · 1 line
1.9.1
Geert Uytterhoeven
maintainerPATCH 6/11 ARM: shmobile: r8a7790: Link CPG to RST using "renesas, modemr"
In reply to Geert UytterhoevenAdd a link from the Clock Pulse Generator node to the Reset Controller node, so the CPG can read the Mode Monitoring Register (MODEMR) to obtain the MD pin values.x
--- arch/arm/boot/dts/r8a7790.dtsi | 1 + 1 file changed, 1 insertion(+)
arch/arm/boot/dts/r8a7790.dtsi +1 -0
@@ -1115,6 +1115,7 @@ "lb", "qspi", "sdh", "sd0", "sd1", "z", "rcan", "adsp"; #power-domain-cells = <0>; + renesas,modemr = <&rst 0x60>; }; /* Variable factor clocks */
Signature · 1 line
1.9.1
PATCH 6/11 ARM: shmobile: r8a7790: Link CPG to RST using "renesas, modemr"
Hi Geert,
Thank you for the patches.
Quoted 14 lines · On Tuesday 07 July 2015 16:10:12 Geert Uytterhoeven wrote:
Add a link from the Clock Pulse Generator node to the Reset Controller node, so the CPG can read the Mode Monitoring Register (MODEMR) to obtain the MD pin values.x
Signed-off-by Geert Uytterhoeven <[email protected]>--- arch/arm/boot/dts/r8a7790.dtsi | 1 + 1 file changed, 1 insertion(+)arch/arm/boot/dts/r8a7790.dtsi +0
-0
arch/arm/boot/dts/r8a7790.dtsi line 1118
Quoted 4 lines
arch/arm/boot/dts/r8a7790.dtsi +1
-0@@ -1115,6 +1115,7 @@ "lb", "qspi", "sdh", "sd0", "sd1", "z", "rcan", "adsp"; #power-domain-cells = <0>; + renesas,modemr = <&rst 0x60>;
I have mixed feelings about this as I don't think it really describes the hardware.
Wouldn't it make sense to instead add a standard kernel API to retrieve the boot mode value ? It seems to be a pretty common feature of SoCs across all vendors.
Quoted 3 lines
arch/arm/boot/dts/r8a7790.dtsi +0
-0}; /* Variable factor clocks */
Signature · 3 lines
Regards, Laurent Pinchart
PATCH 6/11 ARM: shmobile: r8a7790: Link CPG to RST using "renesas, modemr"
Hi Laurent,
Quoted 23 lines · Laurent Pinchart
Quoted 14 lines · On Tuesday 07 July 2015 16:10:12 Geert Uytterhoeven wrote:
Add a link from the Clock Pulse Generator node to the Reset Controller node, so the CPG can read the Mode Monitoring Register (MODEMR) to obtain the MD pin values.x
Signed-off-by Geert Uytterhoeven <[email protected]>--- arch/arm/boot/dts/r8a7790.dtsi | 1 + 1 file changed, 1 insertion(+)arch/arm/boot/dts/r8a7790.dtsi +0
-0arch/arm/boot/dts/r8a7790.dtsi line 1118
Quoted 4 lines
arch/arm/boot/dts/r8a7790.dtsi +1
-0@@ -1115,6 +1115,7 @@ "lb", "qspi", "sdh", "sd0", "sd1", "z", "rcan", "adsp"; #power-domain-cells = <0>; + renesas,modemr = <&rst 0x60>;I have mixed feelings about this as I don't think it really describes the hardware.
Quoted 1 line
From the R-Car Gen2 manual:
8. Reset (RST)
8.1 Features
The following functions are implemented by RST. [...]
Latching of the levels on mode pins when PRESET# is negated Mode monitoring register
7. Clock Pulse Generator (CPG)
7.2 Input/Output Pins
Table 7.1 lists the CPG pin configuration.
Table 7.1 Pin Configuration and Functions of CPG
Pin Name Function I/O Description
[...]
MD0 Mode 0 ...
Hence there definitely is a link between the (latched) values in the RST module and CPG configuration. This link is expressed using the "renesas,modemr" property, where the phandle provides the link to the RST block, and the register offset provides a way for software to read the configuration.
Quoted 3 lines
Wouldn't it make sense to instead add a standard kernel API to retrieve the boot mode value ? It seems to be a pretty common feature of SoCs across all vendors.
What format would the boot mode value be in? One u32 word, an array of u32s?
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert at linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
PATCH 6/11 ARM: shmobile: r8a7790: Link CPG to RST using "renesas, modemr"
Hi Geert,
Quoted 44 lines · On Tuesday 07 July 2015 16:58:21 Geert Uytterhoeven wrote:
Quoted 11 lines · Laurent Pinchart
Quoted 10 lines · On Tuesday 07 July 2015 16:10:12 Geert Uytterhoeven wrote:
Add a link from the Clock Pulse Generator node to the Reset Controller node, so the CPG can read the Mode Monitoring Register (MODEMR) to obtain the MD pin values.x
Signed-off-by Geert Uytterhoeven <[email protected]>---
arch/arm/boot/dts/r8a7790.dtsi | 1 + 1 file changed, 1 insertion(+)Quoted 14 lines
arch/arm/boot/dts/r8a7790.dtsi line 1119
Quoted 11 lines
(quoted diff) +0
-0
b/arch/arm/boot/dts/r8a7790.dtsiindex08067ae177643b8f..4ee5523fc3e13e12100644arch/arm/boot/dts/r8a7790.dtsi +1
-0@@ -1115,6 +1115,7 @@ "lb", "qspi", "sdh", "sd0", "sd1", "z", "rcan", "adsp"; #power-domain-cells = <0>; + renesas,modemr = <&rst 0x60>;I have mixed feelings about this as I don't think it really describes the hardware.
From the R-Car Gen2 manual:
8. Reset (RST)
8.1 Features
The following functions are implemented by RST. [...]
Latching of the levels on mode pins when PRESET# is negated Mode monitoring register7. Clock Pulse Generator (CPG)
7.2 Input/Output Pins
Table 7.1 lists the CPG pin configuration.
Table 7.1 Pin Configuration and Functions of CPG
Pin Name Function I/O Description
[...]
MD0 Mode 0 ...
Quoted 5 lines
Hence there definitely is a link between the (latched) values in the RST module and CPG configuration. This link is expressed using the "renesas,modemr" property, where the phandle provides the link to the RST block, and the register offset provides a way for software to read the configuration.
The mode bits of course influence the CPG (otherwise we wouldn't be having this discussion :-)), but to me it looks more like a configuration broadcast through the whole SoC than a real link between two IP cores. It's obviously subject to interpretation.
Quoted 6 lines
Quoted 3 lines
Wouldn't it make sense to instead add a standard kernel API to retrieve the boot mode value ? It seems to be a pretty common feature of SoCs across all vendors.
What format would the boot mode value be in? One u32 word, an array of u32s?
I'd go for a u32 as that's what all the vendors I came across use. It could easily be extended to a u64 or an array of u32/u64 later if needed. The format of the boot mode value will be SoC-specific, but that's also true of the mode register that would be read through syscon.
Signature · 3 lines
Regards, Laurent Pinchart
PATCH 6/11 ARM: shmobile: r8a7790: Link CPG to RST using "renesas, modemr"
Hi Laurent,
Quoted 35 lines · Laurent Pinchart
Quoted 29 lines
Quoted 11 lines
arch/arm/boot/dts/r8a7790.dtsi line 1119
Quoted 8 lines
arch/arm/boot/dts/r8a7790.dtsi +1
-0@@ -1115,6 +1115,7 @@ "lb", "qspi", "sdh", "sd0", "sd1", "z", "rcan", "adsp"; #power-domain-cells = <0>; + renesas,modemr = <&rst 0x60>;I have mixed feelings about this as I don't think it really describes the hardware.
From the R-Car Gen2 manual:
8. Reset (RST)
8.1 Features
The following functions are implemented by RST. [...]
Latching of the levels on mode pins when PRESET# is negated Mode monitoring register7. Clock Pulse Generator (CPG)
7.2 Input/Output Pins
Table 7.1 lists the CPG pin configuration.
Table 7.1 Pin Configuration and Functions of CPG
Pin Name Function I/O Description
[...]
MD0 Mode 0 ...Quoted 5 lines
Hence there definitely is a link between the (latched) values in the RST module and CPG configuration. This link is expressed using the "renesas,modemr" property, where the phandle provides the link to the RST block, and the register offset provides a way for software to read the configuration.
Quoted 4 lines
The mode bits of course influence the CPG (otherwise we wouldn't be having this discussion :-)), but to me it looks more like a configuration broadcast through the whole SoC than a real link between two IP cores. It's obviously subject to interpretation.
Yep.
Broadcast? Like a bus clock? For that we also have properties with phandles...
Syscon is the Hot New Abstraction for a module that provides a bunch of registers needed by drivers for other modules. Those other modules need some way to refer to the appropriate syscon register.
The RST module definitely falls in that category: CPG needs the MODEMR register, watchdog (RWDT/SWDT) needs the Watchdog Timer Reset Control Register, and APMU probably needs the CA15/7 reset control registers.
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert at linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
PATCH 6/11 ARM: shmobile: r8a7790: Link CPG to RST using "renesas, modemr"
Hi Geert,
Quoted 41 lines · On Wednesday 08 July 2015 10:29:56 Geert Uytterhoeven wrote:
Quoted 35 lines · Laurent Pinchart
Quoted 29 lines
Quoted 11 lines
arch/arm/boot/dts/r8a7790.dtsi line 1119
Quoted 8 lines
arch/arm/boot/dts/r8a7790.dtsi +1
-0@@ -1115,6 +1115,7 @@ "lb", "qspi", "sdh", "sd0", "sd1", "z", "rcan", "adsp"; #power-domain-cells = <0>; + renesas,modemr = <&rst 0x60>;I have mixed feelings about this as I don't think it really describes the hardware.
From the R-Car Gen2 manual:
8. Reset (RST)
8.1 Features
The following functions are implemented by RST. [...]
Latching of the levels on mode pins when PRESET# is negated Mode monitoring register7. Clock Pulse Generator (CPG)
7.2 Input/Output Pins
Table 7.1 lists the CPG pin configuration.
Table 7.1 Pin Configuration and Functions of CPG
Pin Name Function I/O Description
[...]
MD0 Mode 0 ...Quoted 5 lines
Hence there definitely is a link between the (latched) values in the RST module and CPG configuration. This link is expressed using the "renesas,modemr" property, where the phandle provides the link to the RST block, and the register offset provides a way for software to read the configuration.
Quoted 4 lines
The mode bits of course influence the CPG (otherwise we wouldn't be having this discussion :-)), but to me it looks more like a configuration broadcast through the whole SoC than a real link between two IP cores. It's obviously subject to interpretation.
Quoted 4 lines
Yep.
Broadcast? Like a bus clock? For that we also have properties with phandles...
I knew someone would raise that topic ;-)
Quoted 7 lines
Syscon is the Hot New Abstraction for a module that provides a bunch of registers needed by drivers for other modules. Those other modules need some way to refer to the appropriate syscon register.
The RST module definitely falls in that category: CPG needs the MODEMR register, watchdog (RWDT/SWDT) needs the Watchdog Timer Reset Control Register, and APMU probably needs the CA15/7 reset control registers.
syscon is a quick hack to be used when no clean solution exists. Sometimes implementing a proper API is just overkill, especially when the "system controller" aggregates registers that really belong to individual IP cores.
Proper abstract kernel APIs should of course be used wherever possible. Some system controllers are already supported in such a way, using the MFD subsystem and exposing proper APIs for part of their features, and letting drivers access registers directly for other features.
In the boot mode case I believe adding a new API would be both useful and quite simple, so I'd like to explore that option.
By the way, regarding the CA15/7 reset control registers, shouldn't they be exposed through the reset controller API ?
Signature · 3 lines
Regards, Laurent Pinchart
Geert Uytterhoeven
maintainerPATCH 7/11 ARM: shmobile: r8a7791: Link CPG to RST using "renesas, modemr"
In reply to Geert UytterhoevenAdd a link from the Clock Pulse Generator node to the Reset Controller node, so the CPG can read the Mode Monitoring Register (MODEMR) to obtain the MD pin values.
--- arch/arm/boot/dts/r8a7791.dtsi | 1 + 1 file changed, 1 insertion(+)
arch/arm/boot/dts/r8a7791.dtsi +1 -0
@@ -1033,6 +1033,7 @@ "lb", "qspi", "sdh", "sd0", "z", "rcan", "adsp"; #power-domain-cells = <0>; + renesas,modemr = <&rst 0x60>; }; /* Variable factor clocks */
Signature · 1 line
1.9.1
Geert Uytterhoeven
maintainerPATCH 8/11 ARM: shmobile: r8a7793: Link CPG to RST using "renesas, modemr"
In reply to Geert UytterhoevenAdd a link from the Clock Pulse Generator node to the Reset Controller node, so the CPG can read the Mode Monitoring Register (MODEMR) to obtain the MD pin values.
--- arch/arm/boot/dts/r8a7793.dtsi | 1 + 1 file changed, 1 insertion(+)
arch/arm/boot/dts/r8a7793.dtsi +1 -0
@@ -192,6 +192,7 @@ "lb", "qspi", "sdh", "sd0", "z", "rcan", "adsp"; #power-domain-cells = <0>; + renesas,modemr = <&rst 0x60>; }; /* Variable factor clocks */
Signature · 1 line
1.9.1
Geert Uytterhoeven
maintainerPATCH 9/11 ARM: shmobile: r8a7794: Link CPG to RST using "renesas, modemr"
In reply to Geert UytterhoevenAdd a link from the Clock Pulse Generator node to the Reset Controller node, so the CPG can read the Mode Monitoring Register (MODEMR) to obtain MD pin values.
--- arch/arm/boot/dts/r8a7794.dtsi | 1 + 1 file changed, 1 insertion(+)
arch/arm/boot/dts/r8a7794.dtsi +1 -0
@@ -484,6 +484,7 @@ clock-output-names = "main", "pll0", "pll1", "pll3", "lb", "qspi", "sdh", "sd0", "z"; #power-domain-cells = <0>; + renesas,modemr = <&rst 0x60>; }; /* Variable factor clocks */ sd2_clk: sd2_clk at e6150078 {
Signature · 1 line
1.9.1
Geert Uytterhoeven
maintainerPATCH 10/11 ARM: shmobile: rcar-gen2: Use syscon to configure the CPG
In reply to Geert UytterhoevenLet the R-Car Gen2 CPG clock driver rely on syscon to read the Mode Monitoring Register (MODEMR), instead of passing the register value directly.
--- arch/arm/mach-shmobile/Kconfig | 1 + arch/arm/mach-shmobile/setup-rcar-gen2.c | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-)
arch/arm/mach-shmobile/Kconfig +1 -0
@@ -23,6 +23,7 @@ config ARCH_RCAR_GEN2 select SYS_SUPPORTS_SH_CMT select PCI_DOMAINS if PCI select HAVE_ARM_ARCH_TIMER + select MFD_SYSCON config ARCH_RMOBILE bool
arch/arm/mach-shmobile/setup-rcar-gen2.c +2 -1
@@ -15,6 +15,7 @@* GNU General Public License for more details. */ +#include <linux/clk-provider.h> #include <linux/clk/shmobile.h> #include <linux/clocksource.h> #include <linux/device.h>
@@ -125,7 +126,7 @@ void __init rcar_gen2_timer_init(void)iounmap (base); -rcar_gen2_clocks_init (mode); +of_clk_init (NULL );clocksource_of_init (); }
Signature · 1 line
1.9.1
Geert Uytterhoeven
maintainerPATCH 11/11 clk: shmobile: rcar-gen2: Remove obsolete rcar_gen2_clocks_init()
In reply to Geert UytterhoevenSince "ARM: shmobile: rcar-gen2: Use syscon to configure the CPG", rcar_gen2_clocks_init() is no longer called by the R-Car Gen2 platform code. Remove it.
--- drivers/clk/shmobile/clk-rcar-gen2.c | 7 ------- include/linux/clk/shmobile.h | 1 - 2 files changed, 8 deletions(-)
drivers/clk/shmobile/clk-rcar-gen2.c +0 -7
@@ -435,10 +435,3 @@ static void __init rcar_gen2_cpg_clocks_init(struct device_node *np) }CLK_OF_DECLARE (rcar_gen2_cpg_clks,"renesas,rcar-gen2-cpg-clocks" , rcar_gen2_cpg_clocks_init); - -void __init rcar_gen2_clocks_init (u32 mode) -{ - cpg_mode = mode; - -of_clk_init (NULL ); -}
include/linux/clk/shmobile.h +0 -1
@@ -22,7 +22,6 @@ struct generic_pm_domain;void r8a7778_clocks_init (u32 mode);void r8a7779_clocks_init (u32 mode); -void rcar_gen2_clocks_init (u32 mode);#ifdef CONFIG_PM_GENERIC_DOMAINS_OF void cpg_mstp_add_clk_domain (struct device_node *np);
Signature · 1 line
1.9.1