All of lore.kernel.org
 help / color / mirror / Atom feed
From: Magnus Damm <magnus.damm@gmail.com>
To: linux-clk@vger.kernel.org
Cc: kuninori.morimoto.gx@renesas.com,linux-sh@vger.kernel.org,mturquette@baylibre.com,gaku.inami.xw@bp.renesas.com,sboyd@codeaurora.org,horms@verge.net.au,geert@linux-m68k.org,laurent.pinchart@ideasonboard.com,Magnus
	Damm <magnus.damm@gmail.com>
Subject: [PATCH v8 05/05] drivers: sh: Handle PM_GENERIC_DOMAINS_OF=n with r8a7795 MSSR
Date: Thu, 01 Oct 2015 23:38:07 +0900	[thread overview]
Message-ID: <20151001143807.20618.67920.sendpatchset@little-apple> (raw)
In-Reply-To: <20151001143717.20618.26365.sendpatchset@little-apple>

From: Geert Uytterhoeven <geert+renesas@glider.be>

If the new CPG/MSSR device node is present, but
CONFIG_PM_GENERIC_DOMAINS_OF=n, the legacy clock domain should be
enabled. Else the module clocks are not properly enabled when needed.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
---

 Changes since V7: (Magnus Damm <damm+renesas@opensource.se>)
 - New patch, based on local r8a7791 patch from Geert
   "drivers: sh: Handle CONFIG_PM_GENERIC_DOMAINS_OF=n with new CPG/MSSR"
 - Modified to match on r8a7795

 drivers/sh/pm_runtime.c |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

--- 0001/drivers/sh/pm_runtime.c
+++ work/drivers/sh/pm_runtime.c	2015-10-01 18:51:47.280513000 +0900
@@ -36,7 +36,10 @@ static int __init sh_pm_runtime_init(voi
 {
 	if (IS_ENABLED(CONFIG_ARCH_SHMOBILE)) {
 		if (!of_find_compatible_node(NULL, NULL,
-					     "renesas,cpg-mstp-clocks"))
+					     "renesas,cpg-mstp-clocks") &&
+		    (IS_ENABLED(CONFIG_PM_GENERIC_DOMAINS_OF) ||
+		     !of_find_compatible_node(NULL, NULL,
+					     "renesas,r8a7795-cpg-mssr")))
 			return 0;
 		if (IS_ENABLED(CONFIG_PM_GENERIC_DOMAINS_OF) &&
 		    of_find_node_with_property(NULL, "#power-domain-cells"))

WARNING: multiple messages have this Message-ID (diff)
From: Magnus Damm <magnus.damm@gmail.com>
To: linux-clk@vger.kernel.org
Cc: kuninori.morimoto.gx@renesas.com, linux-sh@vger.kernel.org,
	mturquette@baylibre.com, gaku.inami.xw@bp.renesas.com,
	sboyd@codeaurora.org, horms@verge.net.au, geert@linux-m68k.org,
	laurent.pinchart@ideasonboard.com,
	Magnus Damm <magnus.damm@gmail.com>
Subject: [PATCH v8 05/05] drivers: sh: Handle PM_GENERIC_DOMAINS_OF=n with r8a7795 MSSR
Date: Thu, 01 Oct 2015 14:38:07 +0000	[thread overview]
Message-ID: <20151001143807.20618.67920.sendpatchset@little-apple> (raw)
In-Reply-To: <20151001143717.20618.26365.sendpatchset@little-apple>

From: Geert Uytterhoeven <geert+renesas@glider.be>

If the new CPG/MSSR device node is present, but
CONFIG_PM_GENERIC_DOMAINS_OF=n, the legacy clock domain should be
enabled. Else the module clocks are not properly enabled when needed.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
---

 Changes since V7: (Magnus Damm <damm+renesas@opensource.se>)
 - New patch, based on local r8a7791 patch from Geert
   "drivers: sh: Handle CONFIG_PM_GENERIC_DOMAINS_OF=n with new CPG/MSSR"
 - Modified to match on r8a7795

 drivers/sh/pm_runtime.c |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

--- 0001/drivers/sh/pm_runtime.c
+++ work/drivers/sh/pm_runtime.c	2015-10-01 18:51:47.280513000 +0900
@@ -36,7 +36,10 @@ static int __init sh_pm_runtime_init(voi
 {
 	if (IS_ENABLED(CONFIG_ARCH_SHMOBILE)) {
 		if (!of_find_compatible_node(NULL, NULL,
-					     "renesas,cpg-mstp-clocks"))
+					     "renesas,cpg-mstp-clocks") &&
+		    (IS_ENABLED(CONFIG_PM_GENERIC_DOMAINS_OF) ||
+		     !of_find_compatible_node(NULL, NULL,
+					     "renesas,r8a7795-cpg-mssr")))
 			return 0;
 		if (IS_ENABLED(CONFIG_PM_GENERIC_DOMAINS_OF) &&
 		    of_find_node_with_property(NULL, "#power-domain-cells"))

  parent reply	other threads:[~2015-10-01 14:38 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-10-01 14:37 [PATCH v8 00/05] Renesas R-Car Gen3 CPG support V8 Magnus Damm
2015-10-01 14:37 ` Magnus Damm
2015-10-01 14:37 ` [PATCH v8 01/05] clk: shmobile: Rework CONFIG_ARCH_SHMOBILE_MULTI Magnus Damm
2015-10-01 14:37   ` Magnus Damm
2015-10-01 14:37 ` [PATCH v8 02/05] clk: shmobile: Add Renesas R-Car Gen3 CPG support Magnus Damm
2015-10-01 14:37   ` Magnus Damm
2015-10-01 14:37 ` [PATCH v8 03/05] clk: shmobile: Add Renesas Module Standby and Reset driver Magnus Damm
2015-10-01 14:37   ` Magnus Damm
2015-10-01 15:28   ` Geert Uytterhoeven
2015-10-01 15:28     ` Geert Uytterhoeven
2015-10-02  4:10     ` Magnus Damm
2015-10-02  4:10       ` Magnus Damm
2015-10-02  7:12       ` Geert Uytterhoeven
2015-10-02  7:12         ` Geert Uytterhoeven
2015-10-01 14:37 ` [PATCH v8 04/05] clk: shmobile: Add r8a7795 MSSR support Magnus Damm
2015-10-01 14:37   ` Magnus Damm
2015-10-01 14:38 ` Magnus Damm [this message]
2015-10-01 14:38   ` [PATCH v8 05/05] drivers: sh: Handle PM_GENERIC_DOMAINS_OF=n with r8a7795 MSSR Magnus Damm
2015-10-02  7:43 ` [PATCH v8 00/05] Renesas R-Car Gen3 CPG support V8 Geert Uytterhoeven
2015-10-02  7:43   ` Geert Uytterhoeven

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20151001143807.20618.67920.sendpatchset@little-apple \
    --to=magnus.damm@gmail.com \
    --cc=gaku.inami.xw@bp.renesas.com \
    --cc=geert@linux-m68k.org \
    --cc=horms@verge.net.au \
    --cc=kuninori.morimoto.gx@renesas.com \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linux-clk@vger.kernel.org \
    --cc=linux-sh@vger.kernel.org \
    --cc=mturquette@baylibre.com \
    --cc=sboyd@codeaurora.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.