Re: [PATCH v8 03/05] clk: shmobile: Add Renesas Module Standby and Reset driver

Geert Uytterhoeven
2015-10-01T15:28:29Z

Hi Magnus,

On Thu, Oct 1, 2015 at 4:37 PM, Magnus Damm <magnus.damm@gmail.com> wrote:
> From: Geert Uytterhoeven <geert+renesas@glider.be>
>
> Add a driver for the Renesas Module Standby and Software Reset module
> found in several Renesas SoCs.
>
> This driver is based on the existing R-Car MSTP driver, and is intended
> to replace it.
> The existing driver is limited to Module Standby, and has bindings that
> are difficult to extend to more register sets for e.g. reset control.
>
> TODO:
> - Implement module reset handling,
> - Write binding documentation.
>
> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
> Signed-off-by: Magnus Damm <damm+renesas@opensource.se>

Thanks, I'm happy you like it!

> ---
>
> Changes since V7: (Magnus Damm <damm+renesas@opensource.se>)
> - New patch, took local v3 patch from Geert and removed r8a7791 references.

You forgot one reference indicated below.

> drivers/clk/shmobile/clk-mssr.c | 392 +++++++++++++++++++++++++++++++++++++++
> include/linux/clk/shmobile.h | 2
> 2 files changed, 394 insertions(+)
>
> --- /dev/null
> +++ work/drivers/clk/shmobile/clk-mssr.c 2015-10-01 18:38:50.320513000 +0900
> @@ -0,0 +1,392 @@

> +#ifdef CONFIG_PM_GENERIC_DOMAINS_OF
> +static int cpg_mssr_attach_dev(struct generic_pm_domain *domain,
> + struct device *dev)
> +{
> + struct device_node *np = dev->of_node;
> + struct of_phandle_args clkspec;
> + struct clk *clk;
> + int i = 0;
> + int error;
> +
> + while (!of_parse_phandle_with_args(np, "clocks", "#clock-cells", i,
> + &clkspec)) {
> + if (of_device_is_compatible(clkspec.np,
> + "renesas,r8a7791-cpg-mssr"))

renesas,r8a7795-cpg-mssr

Else it won't manage the module clocks, and things may fail miserably.

> + goto found;

Gr{oetje,eeting}s,

Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@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