* [RFC v4 02/26] ARM: dts: r8a7743: Adjust SMP routine size
[not found] ` <1517423070-24236-1-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
@ 2018-01-31 18:24 ` Fabrizio Castro
2018-01-31 18:24 ` [RFC v4 03/26] ARM: dts: r8a7745: " Fabrizio Castro
` (14 subsequent siblings)
15 siblings, 0 replies; 54+ messages in thread
From: Fabrizio Castro @ 2018-01-31 18:24 UTC (permalink / raw)
To: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang
Cc: Guenter Roeck, devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-watchdog-u79uwXL29TY76Z2rM5mHXA,
linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-clk-u79uwXL29TY76Z2rM5mHXA, Chris Paterson, Biju Das,
Fabrizio Castro, Ramesh Shanmugasundaram
This patch adjusts the definition of the SMP routine size according
to the latest changes made by commit:
"ARM: shmobile: Add watchdog support"
Signed-off-by: Fabrizio Castro <fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Reviewed-by: Geert Uytterhoeven <geert+renesas-gXvu3+zWzMSzQB+pC5nmwQ@public.gmane.org>
---
v3->4:
* no change
arch/arm/boot/dts/r8a7743.dtsi | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/arm/boot/dts/r8a7743.dtsi b/arch/arm/boot/dts/r8a7743.dtsi
index 47b62f6..c2943d7 100644
--- a/arch/arm/boot/dts/r8a7743.dtsi
+++ b/arch/arm/boot/dts/r8a7743.dtsi
@@ -973,7 +973,7 @@
smp-sram@0 {
compatible = "renesas,smp-sram";
- reg = <0 0x10>;
+ reg = <0 0x100>;
};
};
--
2.7.4
--
To unsubscribe from this list: send the line "unsubscribe linux-watchdog" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 54+ messages in thread
* [RFC v4 03/26] ARM: dts: r8a7745: Adjust SMP routine size
[not found] ` <1517423070-24236-1-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
2018-01-31 18:24 ` [RFC v4 02/26] ARM: dts: r8a7743: Adjust SMP routine size Fabrizio Castro
@ 2018-01-31 18:24 ` Fabrizio Castro
2018-01-31 18:24 ` [RFC v4 05/26] ARM: dts: r8a7791: " Fabrizio Castro
` (13 subsequent siblings)
15 siblings, 0 replies; 54+ messages in thread
From: Fabrizio Castro @ 2018-01-31 18:24 UTC (permalink / raw)
To: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang
Cc: Guenter Roeck, devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-watchdog-u79uwXL29TY76Z2rM5mHXA,
linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-clk-u79uwXL29TY76Z2rM5mHXA, Chris Paterson, Biju Das,
Fabrizio Castro, Ramesh Shanmugasundaram
This patch adjusts the definition of the SMP routine size according
to the latest changes made by commit:
"ARM: shmobile: Add watchdog support"
Signed-off-by: Fabrizio Castro <fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Reviewed-by: Geert Uytterhoeven <geert+renesas-gXvu3+zWzMSzQB+pC5nmwQ@public.gmane.org>
---
v3->4:
* no change
arch/arm/boot/dts/r8a7745.dtsi | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/arm/boot/dts/r8a7745.dtsi b/arch/arm/boot/dts/r8a7745.dtsi
index ddc3da2..6bc1cf4 100644
--- a/arch/arm/boot/dts/r8a7745.dtsi
+++ b/arch/arm/boot/dts/r8a7745.dtsi
@@ -755,7 +755,7 @@
smp-sram@0 {
compatible = "renesas,smp-sram";
- reg = <0 0x10>;
+ reg = <0 0x100>;
};
};
--
2.7.4
--
To unsubscribe from this list: send the line "unsubscribe linux-watchdog" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 54+ messages in thread
* [RFC v4 05/26] ARM: dts: r8a7791: Adjust SMP routine size
[not found] ` <1517423070-24236-1-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
2018-01-31 18:24 ` [RFC v4 02/26] ARM: dts: r8a7743: Adjust SMP routine size Fabrizio Castro
2018-01-31 18:24 ` [RFC v4 03/26] ARM: dts: r8a7745: " Fabrizio Castro
@ 2018-01-31 18:24 ` Fabrizio Castro
2018-01-31 18:24 ` [RFC v4 07/26] ARM: dts: r8a7793: " Fabrizio Castro
` (12 subsequent siblings)
15 siblings, 0 replies; 54+ messages in thread
From: Fabrizio Castro @ 2018-01-31 18:24 UTC (permalink / raw)
To: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang
Cc: Guenter Roeck, devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-watchdog-u79uwXL29TY76Z2rM5mHXA,
linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-clk-u79uwXL29TY76Z2rM5mHXA, Chris Paterson, Biju Das,
Fabrizio Castro, Ramesh Shanmugasundaram
This patch adjusts the definition of the SMP routine size according
to the latest changes made by commit:
"ARM: shmobile: Add watchdog support"
Signed-off-by: Fabrizio Castro <fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Reviewed-by: Geert Uytterhoeven <geert+renesas-gXvu3+zWzMSzQB+pC5nmwQ@public.gmane.org>
---
v3->4:
* no change
arch/arm/boot/dts/r8a7791.dtsi | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/arm/boot/dts/r8a7791.dtsi b/arch/arm/boot/dts/r8a7791.dtsi
index dc65935..d2a4546 100644
--- a/arch/arm/boot/dts/r8a7791.dtsi
+++ b/arch/arm/boot/dts/r8a7791.dtsi
@@ -407,7 +407,7 @@
smp-sram@0 {
compatible = "renesas,smp-sram";
- reg = <0 0x10>;
+ reg = <0 0x100>;
};
};
--
2.7.4
--
To unsubscribe from this list: send the line "unsubscribe linux-watchdog" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 54+ messages in thread
* [RFC v4 07/26] ARM: dts: r8a7793: Adjust SMP routine size
[not found] ` <1517423070-24236-1-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
` (2 preceding siblings ...)
2018-01-31 18:24 ` [RFC v4 05/26] ARM: dts: r8a7791: " Fabrizio Castro
@ 2018-01-31 18:24 ` Fabrizio Castro
2018-01-31 18:24 ` [RFC v4 10/26] ARM: shmobile: rcar-gen2: Add watchdog support Fabrizio Castro
` (11 subsequent siblings)
15 siblings, 0 replies; 54+ messages in thread
From: Fabrizio Castro @ 2018-01-31 18:24 UTC (permalink / raw)
To: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang
Cc: Guenter Roeck, devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-watchdog-u79uwXL29TY76Z2rM5mHXA,
linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-clk-u79uwXL29TY76Z2rM5mHXA, Chris Paterson, Biju Das,
Fabrizio Castro, Ramesh Shanmugasundaram
This patch adjusts the definition of the SMP routine size according
to the latest changes made by commit:
"ARM: shmobile: Add watchdog support"
Signed-off-by: Fabrizio Castro <fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Reviewed-by: Geert Uytterhoeven <geert+renesas-gXvu3+zWzMSzQB+pC5nmwQ@public.gmane.org>
---
v3->4:
* no change
arch/arm/boot/dts/r8a7793.dtsi | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/arm/boot/dts/r8a7793.dtsi b/arch/arm/boot/dts/r8a7793.dtsi
index aa7d779..bde6969 100644
--- a/arch/arm/boot/dts/r8a7793.dtsi
+++ b/arch/arm/boot/dts/r8a7793.dtsi
@@ -392,7 +392,7 @@
smp-sram@0 {
compatible = "renesas,smp-sram";
- reg = <0 0x10>;
+ reg = <0 0x100>;
};
};
--
2.7.4
--
To unsubscribe from this list: send the line "unsubscribe linux-watchdog" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 54+ messages in thread
* [RFC v4 10/26] ARM: shmobile: rcar-gen2: Add watchdog support
[not found] ` <1517423070-24236-1-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
` (3 preceding siblings ...)
2018-01-31 18:24 ` [RFC v4 07/26] ARM: dts: r8a7793: " Fabrizio Castro
@ 2018-01-31 18:24 ` Fabrizio Castro
2018-01-31 18:24 ` [RFC v4 11/26] dt-bindings: watchdog: renesas-wdt: Add R-Car Gen2 support Fabrizio Castro
` (10 subsequent siblings)
15 siblings, 0 replies; 54+ messages in thread
From: Fabrizio Castro @ 2018-01-31 18:24 UTC (permalink / raw)
To: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang
Cc: Guenter Roeck, devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-watchdog-u79uwXL29TY76Z2rM5mHXA,
linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-clk-u79uwXL29TY76Z2rM5mHXA, Chris Paterson, Biju Das,
Fabrizio Castro, Ramesh Shanmugasundaram
This patch adds watchdog support by installing shmobile_boot_vector_gen2
to ICRAM1 when enough memory is available, in which case we also keep a
copy of MPIDR to complete the reset vector logic.
Signed-off-by: Fabrizio Castro <fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
---
v3->4:
* no change
arch/arm/mach-shmobile/platsmp-apmu.c | 1 +
arch/arm/mach-shmobile/pm-rcar-gen2.c | 13 ++++++++++---
2 files changed, 11 insertions(+), 3 deletions(-)
diff --git a/arch/arm/mach-shmobile/platsmp-apmu.c b/arch/arm/mach-shmobile/platsmp-apmu.c
index 4422b61..ba732ef 100644
--- a/arch/arm/mach-shmobile/platsmp-apmu.c
+++ b/arch/arm/mach-shmobile/platsmp-apmu.c
@@ -191,6 +191,7 @@ static void __init shmobile_smp_apmu_setup_boot(void)
{
/* install boot code shared by all CPUs */
shmobile_boot_fn = __pa_symbol(shmobile_smp_boot);
+ shmobile_boot_fn_gen2 = shmobile_boot_fn;
}
void __init shmobile_smp_apmu_prepare_cpus(unsigned int max_cpus,
diff --git a/arch/arm/mach-shmobile/pm-rcar-gen2.c b/arch/arm/mach-shmobile/pm-rcar-gen2.c
index e5f215c..bfad202 100644
--- a/arch/arm/mach-shmobile/pm-rcar-gen2.c
+++ b/arch/arm/mach-shmobile/pm-rcar-gen2.c
@@ -17,6 +17,7 @@
#include <linux/smp.h>
#include <linux/soc/renesas/rcar-sysc.h>
#include <asm/io.h>
+#include <asm/cputype.h>
#include "common.h"
#include "rcar-gen2.h"
@@ -37,7 +38,6 @@
#define CA7RESCNT_CODE 0x5a5a0000
#define CA7RESCNT_CPUS 0xf /* CPU0-3 */
-
/* On-chip RAM */
#define ICRAM1 0xe63c0000 /* Inter Connect RAM1 (4 KiB) */
@@ -119,8 +119,15 @@ void __init rcar_gen2_pm_init(void)
p = ioremap(res.start, resource_size(&res));
if (!p)
return;
-
- memcpy_toio(p, shmobile_boot_vector, shmobile_boot_size);
+ /* install the reset vector, use the largest version if we have enough
+ * memory available */
+ if (resource_size(&res) >= shmobile_boot_size_gen2) {
+ shmobile_boot_cpu_gen2 = read_cpuid_mpidr();
+ memcpy_toio(p, shmobile_boot_vector_gen2,
+ shmobile_boot_size_gen2);
+ } else {
+ memcpy_toio(p, shmobile_boot_vector, shmobile_boot_size);
+ }
iounmap(p);
/* setup reset vectors */
--
2.7.4
--
To unsubscribe from this list: send the line "unsubscribe linux-watchdog" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 54+ messages in thread
* [RFC v4 11/26] dt-bindings: watchdog: renesas-wdt: Add R-Car Gen2 support
[not found] ` <1517423070-24236-1-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
` (4 preceding siblings ...)
2018-01-31 18:24 ` [RFC v4 10/26] ARM: shmobile: rcar-gen2: Add watchdog support Fabrizio Castro
@ 2018-01-31 18:24 ` Fabrizio Castro
2018-02-05 6:08 ` Rob Herring
[not found] ` <1517423070-24236-12-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
2018-01-31 18:24 ` [RFC v4 12/26] watchdog: renesas_wdt: " Fabrizio Castro
` (9 subsequent siblings)
15 siblings, 2 replies; 54+ messages in thread
From: Fabrizio Castro @ 2018-01-31 18:24 UTC (permalink / raw)
To: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang
Cc: Guenter Roeck, devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-watchdog-u79uwXL29TY76Z2rM5mHXA,
linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-clk-u79uwXL29TY76Z2rM5mHXA, Chris Paterson, Biju Das,
Fabrizio Castro, Ramesh Shanmugasundaram
This commit documents the compatibility with R-Car Gen2 and RZ/G
devices by defining the generic compatible string "renesas,rcar-gen2-wdt".
Also, this patch expands the list of SoC-specific compatible strings to
include RZ/G and R-Car Gen2 devices.
Signed-off-by: Fabrizio Castro <fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Reviewed-by: Geert Uytterhoeven <geert+renesas-gXvu3+zWzMSzQB+pC5nmwQ@public.gmane.org>
---
v3->4:
* Reinstated lost "renesas,rza-wdt" compatible string
.../devicetree/bindings/watchdog/renesas-wdt.txt | 19 ++++++++++++++-----
1 file changed, 14 insertions(+), 5 deletions(-)
diff --git a/Documentation/devicetree/bindings/watchdog/renesas-wdt.txt b/Documentation/devicetree/bindings/watchdog/renesas-wdt.txt
index bf6d1ca..4815128 100644
--- a/Documentation/devicetree/bindings/watchdog/renesas-wdt.txt
+++ b/Documentation/devicetree/bindings/watchdog/renesas-wdt.txt
@@ -1,17 +1,26 @@
Renesas Watchdog Timer (WDT) Controller
Required properties:
-- compatible : Should be "renesas,<soctype>-wdt", and
- "renesas,rcar-gen3-wdt" or "renesas,rza-wdt" as fallback.
+ - compatible : Must be "renesas,<soctype>-wdt", followed by a generic
+ fallback compatible string when compatible with the generic
+ version.
Examples with soctypes are:
+ - "renesas,r8a7743-wdt" (RZ/G1M)
+ - "renesas,r8a7745-wdt" (RZ/G1E)
+ - "renesas,r8a7790-wdt" (R-Car H2)
+ - "renesas,r8a7791-wdt" (R-Car M2-W)
+ - "renesas,r8a7792-wdt" (R-Car V2H)
+ - "renesas,r8a7793-wdt" (R-Car M2-N)
+ - "renesas,r8a7794-wdt" (R-Car E2)
- "renesas,r8a7795-wdt" (R-Car H3)
- "renesas,r8a7796-wdt" (R-Car M3-W)
- "renesas,r8a77995-wdt" (R-Car D3)
- "renesas,r7s72100-wdt" (RZ/A1)
+ The generic compatible string must be:
+ - "renesas,rza-wdt" for RZ/A
+ - "renesas,rcar-gen2-wdt" for R-Car Gen2 and RZ/G
+ - "renesas,rcar-gen3-wdt" for R-Car Gen3
- When compatible with the generic version, nodes must list the SoC-specific
- version corresponding to the platform first, followed by the generic
- version.
- reg : Should contain WDT registers location and length
- clocks : the clock feeding the watchdog timer.
--
2.7.4
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 54+ messages in thread
* Re: [RFC v4 11/26] dt-bindings: watchdog: renesas-wdt: Add R-Car Gen2 support
2018-01-31 18:24 ` [RFC v4 11/26] dt-bindings: watchdog: renesas-wdt: Add R-Car Gen2 support Fabrizio Castro
@ 2018-02-05 6:08 ` Rob Herring
[not found] ` <1517423070-24236-12-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
1 sibling, 0 replies; 54+ messages in thread
From: Rob Herring @ 2018-02-05 6:08 UTC (permalink / raw)
To: Fabrizio Castro
Cc: Mark Rutland, devicetree, Chris Paterson, Magnus Damm,
linux-watchdog, Geert Uytterhoeven, Catalin Marinas,
Michael Turquette, Will Deacon, Russell King, linux-clk,
linux-renesas-soc, Wolfram Sang, Wim Van Sebroeck, Simon Horman,
linux-arm-kernel, Philipp Zabel, Biju Das, Stephen Boyd,
Guenter Roeck, Ramesh Shanmugasundaram
On Wed, Jan 31, 2018 at 06:24:15PM +0000, Fabrizio Castro wrote:
> This commit documents the compatibility with R-Car Gen2 and RZ/G
> devices by defining the generic compatible string "renesas,rcar-gen2-wdt".
> Also, this patch expands the list of SoC-specific compatible strings to
> include RZ/G and R-Car Gen2 devices.
>
> Signed-off-by: Fabrizio Castro <fabrizio.castro@bp.renesas.com>
> Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram@bp.renesas.com>
> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
> ---
> v3->4:
> * Reinstated lost "renesas,rza-wdt" compatible string
>
> .../devicetree/bindings/watchdog/renesas-wdt.txt | 19 ++++++++++++++-----
> 1 file changed, 14 insertions(+), 5 deletions(-)
Reviewed-by: Rob Herring <robh@kernel.org>
^ permalink raw reply [flat|nested] 54+ messages in thread
[parent not found: <1517423070-24236-12-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>]
* Re: [RFC v4 11/26] dt-bindings: watchdog: renesas-wdt: Add R-Car Gen2 support
[not found] ` <1517423070-24236-12-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
@ 2018-02-07 23:04 ` Wolfram Sang
0 siblings, 0 replies; 54+ messages in thread
From: Wolfram Sang @ 2018-02-07 23:04 UTC (permalink / raw)
To: Fabrizio Castro
Cc: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang, Guenter Roeck, devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-watchdog-u79uwXL29TY76Z2rM5mHXA,
linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-clk-u79uwXL29TY76Z2rM5mHXA, Chris Paterson, Biju
[-- Attachment #1: Type: text/plain, Size: 722 bytes --]
On Wed, Jan 31, 2018 at 06:24:15PM +0000, Fabrizio Castro wrote:
> This commit documents the compatibility with R-Car Gen2 and RZ/G
> devices by defining the generic compatible string "renesas,rcar-gen2-wdt".
> Also, this patch expands the list of SoC-specific compatible strings to
> include RZ/G and R-Car Gen2 devices.
>
> Signed-off-by: Fabrizio Castro <fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
> Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram-kTT6dE0pTRj3fQ9qLvQP4Q@public.gmane.orgs.com>
> Reviewed-by: Geert Uytterhoeven <geert+renesas-gXvu3+zWzMSzQB+pC5nmwQ@public.gmane.org>
Reviewed-by: Wolfram Sang <wsa+renesas-jBu1N2QxHDJrcw3mvpCnnVaTQe2KTcn/@public.gmane.org>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 54+ messages in thread
* [RFC v4 12/26] watchdog: renesas_wdt: Add R-Car Gen2 support
[not found] ` <1517423070-24236-1-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
` (5 preceding siblings ...)
2018-01-31 18:24 ` [RFC v4 11/26] dt-bindings: watchdog: renesas-wdt: Add R-Car Gen2 support Fabrizio Castro
@ 2018-01-31 18:24 ` Fabrizio Castro
[not found] ` <1517423070-24236-13-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
2018-01-31 18:24 ` [RFC v4 13/26] watchdog: renesas_wdt: Add restart handler Fabrizio Castro
` (8 subsequent siblings)
15 siblings, 1 reply; 54+ messages in thread
From: Fabrizio Castro @ 2018-01-31 18:24 UTC (permalink / raw)
To: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang
Cc: Guenter Roeck, devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-watchdog-u79uwXL29TY76Z2rM5mHXA,
linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-clk-u79uwXL29TY76Z2rM5mHXA, Chris Paterson, Biju Das,
Fabrizio Castro, Ramesh Shanmugasundaram
Due to commits:
* "ARM: shmobile: Add watchdog support",
* "ARM: shmobile: rcar-gen2: Add watchdog support", and
* "soc: renesas: rcar-rst: Enable watchdog as reset trigger for Gen2",
we now have everything we needed for the watchdog to work on Gen2 and
RZ/G1.
This commit adds "renesas,rcar-gen2-wdt" as compatible string for R-Car
Gen2 and RZ/G1, and since on those platforms the rwdt clock needs to be
always ON, when suspending to RAM we need to explicitly disable the
counting by clearing TME from RWTCSRA.
Signed-off-by: Fabrizio Castro <fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
---
v3->4:
* in this new version the changes to the driver have been splitted into
two commits, this patch takes care of the basic Gen2 support, patch 13/26
takes care of the restart handler.
drivers/watchdog/renesas_wdt.c | 42 +++++++++++++++++++++++++++++++++++++-----
1 file changed, 37 insertions(+), 5 deletions(-)
diff --git a/drivers/watchdog/renesas_wdt.c b/drivers/watchdog/renesas_wdt.c
index 831ef83..0a1a402 100644
--- a/drivers/watchdog/renesas_wdt.c
+++ b/drivers/watchdog/renesas_wdt.c
@@ -203,13 +203,42 @@ static int rwdt_remove(struct platform_device *pdev)
return 0;
}
-/*
- * This driver does also fit for R-Car Gen2 (r8a779[0-4]) WDT. However, for SMP
- * to work there, one also needs a RESET (RST) driver which does not exist yet
- * due to HW issues. This needs to be solved before adding compatibles here.
- */
+#ifdef CONFIG_PM
+static int rwdt_suspend(struct device *dev)
+{
+ struct platform_device *pdev;
+ struct rwdt_priv *priv;
+
+ pdev = to_platform_device(dev);
+ priv = platform_get_drvdata(pdev);
+ if (watchdog_active(&priv->wdev)) {
+ rwdt_write(priv, priv->cks, RWTCSRA);
+ }
+ return 0;
+}
+
+static int rwdt_resume(struct device *dev)
+{
+ struct platform_device *pdev;
+ struct rwdt_priv *priv;
+
+ pdev = to_platform_device(dev);
+ priv = platform_get_drvdata(pdev);
+ if (watchdog_active(&priv->wdev)) {
+ rwdt_write(priv, priv->cks | RWTCSRA_TME, RWTCSRA);
+ }
+ return 0;
+}
+
+static const struct dev_pm_ops rwdt_pm = {
+ .suspend = rwdt_suspend,
+ .resume = rwdt_resume,
+};
+#endif
+
static const struct of_device_id rwdt_ids[] = {
{ .compatible = "renesas,rcar-gen3-wdt", },
+ { .compatible = "renesas,rcar-gen2-wdt", },
{ /* sentinel */ }
};
MODULE_DEVICE_TABLE(of, rwdt_ids);
@@ -218,6 +247,9 @@ static struct platform_driver rwdt_driver = {
.driver = {
.name = "renesas_wdt",
.of_match_table = rwdt_ids,
+#ifdef CONFIG_PM
+ .pm = &rwdt_pm,
+#endif
},
.probe = rwdt_probe,
.remove = rwdt_remove,
--
2.7.4
--
To unsubscribe from this list: send the line "unsubscribe linux-watchdog" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 54+ messages in thread
* [RFC v4 13/26] watchdog: renesas_wdt: Add restart handler
[not found] ` <1517423070-24236-1-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
` (6 preceding siblings ...)
2018-01-31 18:24 ` [RFC v4 12/26] watchdog: renesas_wdt: " Fabrizio Castro
@ 2018-01-31 18:24 ` Fabrizio Castro
[not found] ` <1517423070-24236-14-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
` (2 more replies)
2018-01-31 18:24 ` [RFC v4 14/26] ARM: shmobile: defconfig: Enable RENESAS_WDT_GEN Fabrizio Castro
` (7 subsequent siblings)
15 siblings, 3 replies; 54+ messages in thread
From: Fabrizio Castro @ 2018-01-31 18:24 UTC (permalink / raw)
To: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang
Cc: Guenter Roeck, devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-watchdog-u79uwXL29TY76Z2rM5mHXA,
linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-clk-u79uwXL29TY76Z2rM5mHXA, Chris Paterson, Biju Das,
Fabrizio Castro, Ramesh Shanmugasundaram
On iWave's boards iwg20d and iwg22d the only way to reboot the system is
by means of the watchdog.
This patch adds a restart handler to rwdt_ops, and also makes sure we
keep its priority to a medium level, in order to not override other more
effective handlers.
Signed-off-by: Fabrizio Castro <fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
---
v3->v4:
* New patch spawn out from patch 12/16. The restart handler on Gen3 is
controversial, hopefully this patch will help finalizing the discussion.
drivers/watchdog/renesas_wdt.c | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
diff --git a/drivers/watchdog/renesas_wdt.c b/drivers/watchdog/renesas_wdt.c
index 0a1a402..6d1c4b9 100644
--- a/drivers/watchdog/renesas_wdt.c
+++ b/drivers/watchdog/renesas_wdt.c
@@ -107,6 +107,24 @@ static unsigned int rwdt_get_timeleft(struct watchdog_device *wdev)
return DIV_BY_CLKS_PER_SEC(priv, 65536 - val);
}
+static int rwdt_restart(struct watchdog_device *wdev, unsigned long action,
+ void *data)
+{
+ struct rwdt_priv *priv = watchdog_get_drvdata(wdev);
+
+ pm_runtime_get_sync(wdev->parent);
+
+ rwdt_write(priv, 0x00, RWTCSRB);
+ rwdt_write(priv, 0x00, RWTCSRA);
+ rwdt_write(priv, 0xffff, RWTCNT);
+
+ while (readb_relaxed(priv->base + RWTCSRA) & RWTCSRA_WRFLG)
+ cpu_relax();
+
+ rwdt_write(priv, 0x80, RWTCSRA);
+ return 0;
+}
+
static const struct watchdog_info rwdt_ident = {
.options = WDIOF_MAGICCLOSE | WDIOF_KEEPALIVEPING | WDIOF_SETTIMEOUT,
.identity = "Renesas WDT Watchdog",
@@ -118,6 +136,7 @@ static const struct watchdog_ops rwdt_ops = {
.stop = rwdt_stop,
.ping = rwdt_init_timeout,
.get_timeleft = rwdt_get_timeleft,
+ .restart = rwdt_restart,
};
static int rwdt_probe(struct platform_device *pdev)
@@ -176,6 +195,7 @@ static int rwdt_probe(struct platform_device *pdev)
platform_set_drvdata(pdev, priv);
watchdog_set_drvdata(&priv->wdev, priv);
watchdog_set_nowayout(&priv->wdev, nowayout);
+ watchdog_set_restart_priority(&priv->wdev, 128);
/* This overrides the default timeout only if DT configuration was found */
ret = watchdog_init_timeout(&priv->wdev, 0, &pdev->dev);
--
2.7.4
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 54+ messages in thread
[parent not found: <1517423070-24236-14-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>]
* Re: [RFC v4 13/26] watchdog: renesas_wdt: Add restart handler
[not found] ` <1517423070-24236-14-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
@ 2018-02-02 2:58 ` Guenter Roeck
0 siblings, 0 replies; 54+ messages in thread
From: Guenter Roeck @ 2018-02-02 2:58 UTC (permalink / raw)
To: Fabrizio Castro, Philipp Zabel, Rob Herring, Mark Rutland,
Wim Van Sebroeck, Russell King, Catalin Marinas, Will Deacon,
Michael Turquette, Stephen Boyd, Simon Horman, Magnus Damm,
Geert Uytterhoeven, Wolfram Sang
Cc: devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-watchdog-u79uwXL29TY76Z2rM5mHXA,
linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-clk-u79uwXL29TY76Z2rM5mHXA, Chris Paterson, Biju Das,
Ramesh Shanmugasundaram
On 01/31/2018 10:24 AM, Fabrizio Castro wrote:
> On iWave's boards iwg20d and iwg22d the only way to reboot the system is
> by means of the watchdog.
> This patch adds a restart handler to rwdt_ops, and also makes sure we
> keep its priority to a medium level, in order to not override other more
> effective handlers.
>
> Signed-off-by: Fabrizio Castro <fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
> Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Reviewed-by: Guenter Roeck <linux-0h96xk9xTtrk1uMJSBkQmQ@public.gmane.org>
> ---
> v3->v4:
> * New patch spawn out from patch 12/16. The restart handler on Gen3 is
> controversial, hopefully this patch will help finalizing the discussion.
>
> drivers/watchdog/renesas_wdt.c | 20 ++++++++++++++++++++
> 1 file changed, 20 insertions(+)
>
> diff --git a/drivers/watchdog/renesas_wdt.c b/drivers/watchdog/renesas_wdt.c
> index 0a1a402..6d1c4b9 100644
> --- a/drivers/watchdog/renesas_wdt.c
> +++ b/drivers/watchdog/renesas_wdt.c
> @@ -107,6 +107,24 @@ static unsigned int rwdt_get_timeleft(struct watchdog_device *wdev)
> return DIV_BY_CLKS_PER_SEC(priv, 65536 - val);
> }
>
> +static int rwdt_restart(struct watchdog_device *wdev, unsigned long action,
> + void *data)
> +{
> + struct rwdt_priv *priv = watchdog_get_drvdata(wdev);
> +
> + pm_runtime_get_sync(wdev->parent);
> +
> + rwdt_write(priv, 0x00, RWTCSRB);
> + rwdt_write(priv, 0x00, RWTCSRA);
> + rwdt_write(priv, 0xffff, RWTCNT);
> +
> + while (readb_relaxed(priv->base + RWTCSRA) & RWTCSRA_WRFLG)
> + cpu_relax();
> +
> + rwdt_write(priv, 0x80, RWTCSRA);
> + return 0;
> +}
> +
> static const struct watchdog_info rwdt_ident = {
> .options = WDIOF_MAGICCLOSE | WDIOF_KEEPALIVEPING | WDIOF_SETTIMEOUT,
> .identity = "Renesas WDT Watchdog",
> @@ -118,6 +136,7 @@ static const struct watchdog_ops rwdt_ops = {
> .stop = rwdt_stop,
> .ping = rwdt_init_timeout,
> .get_timeleft = rwdt_get_timeleft,
> + .restart = rwdt_restart,
> };
>
> static int rwdt_probe(struct platform_device *pdev)
> @@ -176,6 +195,7 @@ static int rwdt_probe(struct platform_device *pdev)
> platform_set_drvdata(pdev, priv);
> watchdog_set_drvdata(&priv->wdev, priv);
> watchdog_set_nowayout(&priv->wdev, nowayout);
> + watchdog_set_restart_priority(&priv->wdev, 128);
>
> /* This overrides the default timeout only if DT configuration was found */
> ret = watchdog_init_timeout(&priv->wdev, 0, &pdev->dev);
>
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 54+ messages in thread
* Re: [RFC v4 13/26] watchdog: renesas_wdt: Add restart handler
2018-01-31 18:24 ` [RFC v4 13/26] watchdog: renesas_wdt: Add restart handler Fabrizio Castro
[not found] ` <1517423070-24236-14-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
@ 2018-02-07 15:46 ` Geert Uytterhoeven
2018-02-07 15:55 ` Fabrizio Castro
2018-02-07 23:03 ` Wolfram Sang
2 siblings, 1 reply; 54+ messages in thread
From: Geert Uytterhoeven @ 2018-02-07 15:46 UTC (permalink / raw)
To: Fabrizio Castro
Cc: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang, Guenter Roeck,
open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
Linux Watchdog Mailing List, Linux-Renesas
Hi Fabrizio,
On Wed, Jan 31, 2018 at 7:24 PM, Fabrizio Castro
<fabrizio.castro@bp.renesas.com> wrote:
> On iWave's boards iwg20d and iwg22d the only way to reboot the system is
> by means of the watchdog.
> This patch adds a restart handler to rwdt_ops, and also makes sure we
> keep its priority to a medium level, in order to not override other more
> effective handlers.
>
> Signed-off-by: Fabrizio Castro <fabrizio.castro@bp.renesas.com>
> Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram@bp.renesas.com>
> --- a/drivers/watchdog/renesas_wdt.c
> +++ b/drivers/watchdog/renesas_wdt.c
> @@ -118,6 +136,7 @@ static const struct watchdog_ops rwdt_ops = {
> .stop = rwdt_stop,
> .ping = rwdt_init_timeout,
> .get_timeleft = rwdt_get_timeleft,
> + .restart = rwdt_restart,
> };
>
> static int rwdt_probe(struct platform_device *pdev)
> @@ -176,6 +195,7 @@ static int rwdt_probe(struct platform_device *pdev)
> platform_set_drvdata(pdev, priv);
> watchdog_set_drvdata(&priv->wdev, priv);
> watchdog_set_nowayout(&priv->wdev, nowayout);
> + watchdog_set_restart_priority(&priv->wdev, 128);
Given we want to reboot R-Car Gen2 boards equipped with a suitable PMIC
(e.g. DA9063) using that PMIC, I think the priority should be lower (0?),
cfr.
* 0: use watchdog's restart function as last resort, has limited restart
* capabilies
* 128: default restart handler, use if no other handler is expected to be
* available and/or if restart is sufficient to restart the entire system
* 255: preempt all other handlers
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
^ permalink raw reply [flat|nested] 54+ messages in thread
* RE: [RFC v4 13/26] watchdog: renesas_wdt: Add restart handler
2018-02-07 15:46 ` Geert Uytterhoeven
@ 2018-02-07 15:55 ` Fabrizio Castro
0 siblings, 0 replies; 54+ messages in thread
From: Fabrizio Castro @ 2018-02-07 15:55 UTC (permalink / raw)
To: Geert Uytterhoeven
Cc: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang, Guenter Roeck,
open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
Linux Watchdog Mailing List, Linux-Renesas
Hello Geert,
> Subject: Re: [RFC v4 13/26] watchdog: renesas_wdt: Add restart handler
>
> Hi Fabrizio,
Thank you for your feedback!
>
> On Wed, Jan 31, 2018 at 7:24 PM, Fabrizio Castro
> <fabrizio.castro@bp.renesas.com> wrote:
> > On iWave's boards iwg20d and iwg22d the only way to reboot the system is
> > by means of the watchdog.
> > This patch adds a restart handler to rwdt_ops, and also makes sure we
> > keep its priority to a medium level, in order to not override other more
> > effective handlers.
> >
> > Signed-off-by: Fabrizio Castro <fabrizio.castro@bp.renesas.com>
> > Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram@bp.renesas.com>
>
> > --- a/drivers/watchdog/renesas_wdt.c
> > +++ b/drivers/watchdog/renesas_wdt.c
> > @@ -118,6 +136,7 @@ static const struct watchdog_ops rwdt_ops = {
> > .stop = rwdt_stop,
> > .ping = rwdt_init_timeout,
> > .get_timeleft = rwdt_get_timeleft,
> > + .restart = rwdt_restart,
> > };
> >
> > static int rwdt_probe(struct platform_device *pdev)
> > @@ -176,6 +195,7 @@ static int rwdt_probe(struct platform_device *pdev)
> > platform_set_drvdata(pdev, priv);
> > watchdog_set_drvdata(&priv->wdev, priv);
> > watchdog_set_nowayout(&priv->wdev, nowayout);
> > + watchdog_set_restart_priority(&priv->wdev, 128);
>
> Given we want to reboot R-Car Gen2 boards equipped with a suitable PMIC
> (e.g. DA9063) using that PMIC, I think the priority should be lower (0?),
> cfr.
Yes, can do, I have no strong opinion about this.
I'll use priority 0 for the next submission.
Thanks,
Fab
>
> * 0: use watchdog's restart function as last resort, has limited restart
> * capabilies
> * 128: default restart handler, use if no other handler is expected to be
> * available and/or if restart is sufficient to restart the entire system
> * 255: preempt all other handlers
>
> 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
Renesas Electronics Europe Ltd, Dukes Meadow, Millboard Road, Bourne End, Buckinghamshire, SL8 5FH, UK. Registered in England & Wales under Registered No. 04586709.
^ permalink raw reply [flat|nested] 54+ messages in thread
* Re: [RFC v4 13/26] watchdog: renesas_wdt: Add restart handler
2018-01-31 18:24 ` [RFC v4 13/26] watchdog: renesas_wdt: Add restart handler Fabrizio Castro
[not found] ` <1517423070-24236-14-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
2018-02-07 15:46 ` Geert Uytterhoeven
@ 2018-02-07 23:03 ` Wolfram Sang
2018-02-12 10:33 ` Fabrizio Castro
2 siblings, 1 reply; 54+ messages in thread
From: Wolfram Sang @ 2018-02-07 23:03 UTC (permalink / raw)
To: Fabrizio Castro
Cc: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang, Guenter Roeck, devicetree, linux-watchdog,
linux-renesas-soc, linux-arm-kernel, linux-clk, Chris Paterson,
Biju
[-- Attachment #1: Type: text/plain, Size: 635 bytes --]
> +static int rwdt_restart(struct watchdog_device *wdev, unsigned long action,
> + void *data)
> +{
> + struct rwdt_priv *priv = watchdog_get_drvdata(wdev);
> +
> + pm_runtime_get_sync(wdev->parent);
> +
> + rwdt_write(priv, 0x00, RWTCSRB);
> + rwdt_write(priv, 0x00, RWTCSRA);
> + rwdt_write(priv, 0xffff, RWTCNT);
> +
> + while (readb_relaxed(priv->base + RWTCSRA) & RWTCSRA_WRFLG)
> + cpu_relax();
> +
> + rwdt_write(priv, 0x80, RWTCSRA);
> + return 0;
> +}
I used to have this simpler version (back then for the UP case):
+ rwdt_start(wdev);
+ rwdt_write(priv, 0xffff, RWTCNT);
+ return 0;
It should still work probably...
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 54+ messages in thread
* RE: [RFC v4 13/26] watchdog: renesas_wdt: Add restart handler
2018-02-07 23:03 ` Wolfram Sang
@ 2018-02-12 10:33 ` Fabrizio Castro
2018-02-12 10:54 ` Wolfram Sang
0 siblings, 1 reply; 54+ messages in thread
From: Fabrizio Castro @ 2018-02-12 10:33 UTC (permalink / raw)
To: Wolfram Sang
Cc: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang, Guenter Roeck, devicetree, linux-watchdog,
linux-renesas-soc
Hello Wolfram,
thank you for your feedback!
> Subject: Re: [RFC v4 13/26] watchdog: renesas_wdt: Add restart handler
>
>
> > +static int rwdt_restart(struct watchdog_device *wdev, unsigned long action,
> > +void *data)
> > +{
> > +struct rwdt_priv *priv = watchdog_get_drvdata(wdev);
> > +
> > +pm_runtime_get_sync(wdev->parent);
> > +
> > +rwdt_write(priv, 0x00, RWTCSRB);
> > +rwdt_write(priv, 0x00, RWTCSRA);
> > +rwdt_write(priv, 0xffff, RWTCNT);
> > +
> > +while (readb_relaxed(priv->base + RWTCSRA) & RWTCSRA_WRFLG)
> > +cpu_relax();
> > +
> > +rwdt_write(priv, 0x80, RWTCSRA);
> > +return 0;
> > +}
>
> I used to have this simpler version (back then for the UP case):
>
> +rwdt_start(wdev);
> +rwdt_write(priv, 0xffff, RWTCNT);
> +return 0;
>
> It should still work probably...
It should still work, but it would be slower, I would stick with the version I have submitted if you don't mind.
Thanks,
Fabrizio
Renesas Electronics Europe Ltd, Dukes Meadow, Millboard Road, Bourne End, Buckinghamshire, SL8 5FH, UK. Registered in England & Wales under Registered No. 04586709.
^ permalink raw reply [flat|nested] 54+ messages in thread
* Re: [RFC v4 13/26] watchdog: renesas_wdt: Add restart handler
2018-02-12 10:33 ` Fabrizio Castro
@ 2018-02-12 10:54 ` Wolfram Sang
2018-02-12 11:38 ` Fabrizio Castro
0 siblings, 1 reply; 54+ messages in thread
From: Wolfram Sang @ 2018-02-12 10:54 UTC (permalink / raw)
To: Fabrizio Castro
Cc: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang, Guenter Roeck, devicetree, linux-watchdog,
linux-renesas-soc
[-- Attachment #1: Type: text/plain, Size: 512 bytes --]
> > I used to have this simpler version (back then for the UP case):
> >
> > +rwdt_start(wdev);
> > +rwdt_write(priv, 0xffff, RWTCNT);
> > +return 0;
> >
> > It should still work probably...
>
> It should still work, but it would be slower, I would stick with the
> version I have submitted if you don't mind.
Actually, I do mind. Because of code duplication reasons. We have a fix
in the works for rwdt_start() and it would be too easy to overlook the
same fix will be needed for a restart.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 54+ messages in thread
* RE: [RFC v4 13/26] watchdog: renesas_wdt: Add restart handler
2018-02-12 10:54 ` Wolfram Sang
@ 2018-02-12 11:38 ` Fabrizio Castro
0 siblings, 0 replies; 54+ messages in thread
From: Fabrizio Castro @ 2018-02-12 11:38 UTC (permalink / raw)
To: Wolfram Sang
Cc: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang, Guenter Roeck, devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-watchdog-u79uwXL29TY76Z2rM5mHXA,
linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA
> > > I used to have this simpler version (back then for the UP case):
> > >
> > > +rwdt_start(wdev);
> > > +rwdt_write(priv, 0xffff, RWTCNT);
> > > +return 0;
> > >
> > > It should still work probably...
> >
> > It should still work, but it would be slower, I would stick with the
> > version I have submitted if you don't mind.
>
> Actually, I do mind. Because of code duplication reasons. We have a fix
> in the works for rwdt_start() and it would be too easy to overlook the
> same fix will be needed for a restart.
The code is very similar indeed, but not exactly duplicated as it sets the registers in order to reset
the system as quickly as possible.
But since you have strong feelings about this I'll reuse this other version for the next submission.
Thanks,
Fabrizio
Renesas Electronics Europe Ltd, Dukes Meadow, Millboard Road, Bourne End, Buckinghamshire, SL8 5FH, UK. Registered in England & Wales under Registered No. 04586709.
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 54+ messages in thread
* [RFC v4 14/26] ARM: shmobile: defconfig: Enable RENESAS_WDT_GEN
[not found] ` <1517423070-24236-1-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
` (7 preceding siblings ...)
2018-01-31 18:24 ` [RFC v4 13/26] watchdog: renesas_wdt: Add restart handler Fabrizio Castro
@ 2018-01-31 18:24 ` Fabrizio Castro
[not found] ` <1517423070-24236-15-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
2018-01-31 18:24 ` [RFC v4 16/26] clk: renesas: r8a7745: Add rwdt clock Fabrizio Castro
` (6 subsequent siblings)
15 siblings, 1 reply; 54+ messages in thread
From: Fabrizio Castro @ 2018-01-31 18:24 UTC (permalink / raw)
To: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang
Cc: Guenter Roeck, devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-watchdog-u79uwXL29TY76Z2rM5mHXA,
linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-clk-u79uwXL29TY76Z2rM5mHXA, Chris Paterson, Biju Das,
Fabrizio Castro, Ramesh Shanmugasundaram
R-Car Gen2 and RZ/G1 platforms come with a watchdog IP, therefore enable
its driver by default.
Signed-off-by: Fabrizio Castro <fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
---
v3->4:
* no change
arch/arm/configs/shmobile_defconfig | 1 +
1 file changed, 1 insertion(+)
diff --git a/arch/arm/configs/shmobile_defconfig b/arch/arm/configs/shmobile_defconfig
index 578434c..d5cdad8 100644
--- a/arch/arm/configs/shmobile_defconfig
+++ b/arch/arm/configs/shmobile_defconfig
@@ -132,6 +132,7 @@ CONFIG_CPU_THERMAL=y
CONFIG_RCAR_THERMAL=y
CONFIG_WATCHDOG=y
CONFIG_DA9063_WATCHDOG=y
+CONFIG_RENESAS_WDT=y
CONFIG_MFD_AS3711=y
CONFIG_MFD_DA9063=y
CONFIG_REGULATOR_FIXED_VOLTAGE=y
--
2.7.4
--
To unsubscribe from this list: send the line "unsubscribe linux-watchdog" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 54+ messages in thread
* [RFC v4 16/26] clk: renesas: r8a7745: Add rwdt clock
[not found] ` <1517423070-24236-1-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
` (8 preceding siblings ...)
2018-01-31 18:24 ` [RFC v4 14/26] ARM: shmobile: defconfig: Enable RENESAS_WDT_GEN Fabrizio Castro
@ 2018-01-31 18:24 ` Fabrizio Castro
[not found] ` <1517423070-24236-17-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
2018-01-31 18:24 ` [RFC v4 18/26] clk: renesas: r8a7791/r8a7793: " Fabrizio Castro
` (5 subsequent siblings)
15 siblings, 1 reply; 54+ messages in thread
From: Fabrizio Castro @ 2018-01-31 18:24 UTC (permalink / raw)
To: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang
Cc: Guenter Roeck, devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-watchdog-u79uwXL29TY76Z2rM5mHXA,
linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-clk-u79uwXL29TY76Z2rM5mHXA, Chris Paterson, Biju Das,
Fabrizio Castro, Ramesh Shanmugasundaram
Add "rwdt" clock to r8a7745_mod_clks. Also, since we may need to access
the watchdog registers at any time, declare the clock as critical.
Signed-off-by: Fabrizio Castro <fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
---
v3->4:
* no change
drivers/clk/renesas/r8a7745-cpg-mssr.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/clk/renesas/r8a7745-cpg-mssr.c b/drivers/clk/renesas/r8a7745-cpg-mssr.c
index 2859504..87f5a36 100644
--- a/drivers/clk/renesas/r8a7745-cpg-mssr.c
+++ b/drivers/clk/renesas/r8a7745-cpg-mssr.c
@@ -114,6 +114,7 @@ static const struct mssr_mod_clk r8a7745_mod_clks[] __initconst = {
DEF_MOD("cmt1", 329, R8A7745_CLK_R),
DEF_MOD("usbhs-dmac0", 330, R8A7745_CLK_HP),
DEF_MOD("usbhs-dmac1", 331, R8A7745_CLK_HP),
+ DEF_MOD("rwdt", 402, R8A7745_CLK_R),
DEF_MOD("irqc", 407, R8A7745_CLK_CP),
DEF_MOD("intc-sys", 408, R8A7745_CLK_ZS),
DEF_MOD("audio-dmac0", 502, R8A7745_CLK_HP),
@@ -180,6 +181,7 @@ static const struct mssr_mod_clk r8a7745_mod_clks[] __initconst = {
};
static const unsigned int r8a7745_crit_mod_clks[] __initconst = {
+ MOD_CLK_ID(402), /* RWDT */
MOD_CLK_ID(408), /* INTC-SYS (GIC) */
};
--
2.7.4
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 54+ messages in thread
* [RFC v4 18/26] clk: renesas: r8a7791/r8a7793: Add rwdt clock
[not found] ` <1517423070-24236-1-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
` (9 preceding siblings ...)
2018-01-31 18:24 ` [RFC v4 16/26] clk: renesas: r8a7745: Add rwdt clock Fabrizio Castro
@ 2018-01-31 18:24 ` Fabrizio Castro
2018-02-07 23:17 ` Wolfram Sang
2018-01-31 18:24 ` [RFC v4 20/26] ARM: dts: r8a7743: Add watchdog support to SoC dtsi Fabrizio Castro
` (4 subsequent siblings)
15 siblings, 1 reply; 54+ messages in thread
From: Fabrizio Castro @ 2018-01-31 18:24 UTC (permalink / raw)
To: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang
Cc: Guenter Roeck, devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-watchdog-u79uwXL29TY76Z2rM5mHXA,
linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-clk-u79uwXL29TY76Z2rM5mHXA, Chris Paterson, Biju Das,
Fabrizio Castro, Ramesh Shanmugasundaram
Add "rwdt" clock to r8a7791_mod_clks. Also, since we may need to access
the watchdog registers at any time, declare the clock as critical.
Signed-off-by: Fabrizio Castro <fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
---
v3->4:
* no change
drivers/clk/renesas/r8a7791-cpg-mssr.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/clk/renesas/r8a7791-cpg-mssr.c b/drivers/clk/renesas/r8a7791-cpg-mssr.c
index c0b51f9..820b220 100644
--- a/drivers/clk/renesas/r8a7791-cpg-mssr.c
+++ b/drivers/clk/renesas/r8a7791-cpg-mssr.c
@@ -128,6 +128,7 @@ static const struct mssr_mod_clk r8a7791_mod_clks[] __initconst = {
DEF_MOD("cmt1", 329, R8A7791_CLK_R),
DEF_MOD("usbhs-dmac0", 330, R8A7791_CLK_HP),
DEF_MOD("usbhs-dmac1", 331, R8A7791_CLK_HP),
+ DEF_MOD("rwdt", 402, R8A7791_CLK_R),
DEF_MOD("irqc", 407, R8A7791_CLK_CP),
DEF_MOD("intc-sys", 408, R8A7791_CLK_ZS),
DEF_MOD("audio-dmac1", 501, R8A7791_CLK_HP),
@@ -209,6 +210,7 @@ static const struct mssr_mod_clk r8a7791_mod_clks[] __initconst = {
};
static const unsigned int r8a7791_crit_mod_clks[] __initconst = {
+ MOD_CLK_ID(402), /* RWDT */
MOD_CLK_ID(408), /* INTC-SYS (GIC) */
};
--
2.7.4
--
To unsubscribe from this list: send the line "unsubscribe linux-watchdog" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 54+ messages in thread
* Re: [RFC v4 18/26] clk: renesas: r8a7791/r8a7793: Add rwdt clock
2018-01-31 18:24 ` [RFC v4 18/26] clk: renesas: r8a7791/r8a7793: " Fabrizio Castro
@ 2018-02-07 23:17 ` Wolfram Sang
0 siblings, 0 replies; 54+ messages in thread
From: Wolfram Sang @ 2018-02-07 23:17 UTC (permalink / raw)
To: Fabrizio Castro
Cc: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang, Guenter Roeck, devicetree, linux-watchdog,
linux-renesas-soc, linux-arm-kernel, linux-clk, Chris Paterson,
Biju
[-- Attachment #1: Type: text/plain, Size: 431 bytes --]
On Wed, Jan 31, 2018 at 06:24:22PM +0000, Fabrizio Castro wrote:
> Add "rwdt" clock to r8a7791_mod_clks. Also, since we may need to access
> the watchdog registers at any time, declare the clock as critical.
>
> Signed-off-by: Fabrizio Castro <fabrizio.castro@bp.renesas.com>
> Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram@bp.renesas.com>
Reviewed-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 54+ messages in thread
* [RFC v4 20/26] ARM: dts: r8a7743: Add watchdog support to SoC dtsi
[not found] ` <1517423070-24236-1-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
` (10 preceding siblings ...)
2018-01-31 18:24 ` [RFC v4 18/26] clk: renesas: r8a7791/r8a7793: " Fabrizio Castro
@ 2018-01-31 18:24 ` Fabrizio Castro
[not found] ` <1517423070-24236-21-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
2018-01-31 18:24 ` [RFC v4 21/26] ARM: dts: r8a7745: " Fabrizio Castro
` (3 subsequent siblings)
15 siblings, 1 reply; 54+ messages in thread
From: Fabrizio Castro @ 2018-01-31 18:24 UTC (permalink / raw)
To: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang
Cc: Guenter Roeck, devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-watchdog-u79uwXL29TY76Z2rM5mHXA,
linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-clk-u79uwXL29TY76Z2rM5mHXA, Chris Paterson, Biju Das,
Fabrizio Castro, Ramesh Shanmugasundaram
This patch adds watchdog support to the r8a7743 SoC dtsi.
Signed-off-by: Fabrizio Castro <fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Reviewed-by: Geert Uytterhoeven <geert+renesas-gXvu3+zWzMSzQB+pC5nmwQ@public.gmane.org>
---
v3->4:
* no change
arch/arm/boot/dts/r8a7743.dtsi | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/arch/arm/boot/dts/r8a7743.dtsi b/arch/arm/boot/dts/r8a7743.dtsi
index c2943d7..1d4505f 100644
--- a/arch/arm/boot/dts/r8a7743.dtsi
+++ b/arch/arm/boot/dts/r8a7743.dtsi
@@ -368,6 +368,16 @@
reg = <0 0xe6160000 0 0x100>;
};
+ rwdt: watchdog@e6020000 {
+ compatible = "renesas,r8a7743-wdt",
+ "renesas,rcar-gen2-wdt";
+ reg = <0 0xe6020000 0 0x0c>;
+ clocks = <&cpg CPG_MOD 402>;
+ power-domains = <&sysc R8A7743_PD_ALWAYS_ON>;
+ resets = <&cpg 402>;
+ status = "disabled";
+ };
+
sysc: system-controller@e6180000 {
compatible = "renesas,r8a7743-sysc";
reg = <0 0xe6180000 0 0x200>;
--
2.7.4
--
To unsubscribe from this list: send the line "unsubscribe linux-watchdog" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 54+ messages in thread
* [RFC v4 21/26] ARM: dts: r8a7745: Add watchdog support to SoC dtsi
[not found] ` <1517423070-24236-1-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
` (11 preceding siblings ...)
2018-01-31 18:24 ` [RFC v4 20/26] ARM: dts: r8a7743: Add watchdog support to SoC dtsi Fabrizio Castro
@ 2018-01-31 18:24 ` Fabrizio Castro
[not found] ` <1517423070-24236-22-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
2018-01-31 18:24 ` [RFC v4 22/26] ARM: dts: r8a7790: " Fabrizio Castro
` (2 subsequent siblings)
15 siblings, 1 reply; 54+ messages in thread
From: Fabrizio Castro @ 2018-01-31 18:24 UTC (permalink / raw)
To: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang
Cc: Guenter Roeck, devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-watchdog-u79uwXL29TY76Z2rM5mHXA,
linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-clk-u79uwXL29TY76Z2rM5mHXA, Chris Paterson, Biju Das,
Fabrizio Castro, Ramesh Shanmugasundaram
This patch adds watchdog support to the r8a7745 SoC dtsi.
Signed-off-by: Fabrizio Castro <fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Reviewed-by: Geert Uytterhoeven <geert+renesas-gXvu3+zWzMSzQB+pC5nmwQ@public.gmane.org>
---
v3->4:
* no change
arch/arm/boot/dts/r8a7745.dtsi | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/arch/arm/boot/dts/r8a7745.dtsi b/arch/arm/boot/dts/r8a7745.dtsi
index 6bc1cf4..5d1b8f2 100644
--- a/arch/arm/boot/dts/r8a7745.dtsi
+++ b/arch/arm/boot/dts/r8a7745.dtsi
@@ -321,6 +321,16 @@
reg = <0 0xe6160000 0 0x100>;
};
+ rwdt: watchdog@e6020000 {
+ compatible = "renesas,r8a7745-wdt",
+ "renesas,rcar-gen2-wdt";
+ reg = <0 0xe6020000 0 0x0c>;
+ clocks = <&cpg CPG_MOD 402>;
+ power-domains = <&sysc R8A7745_PD_ALWAYS_ON>;
+ resets = <&cpg 402>;
+ status = "disabled";
+ };
+
sysc: system-controller@e6180000 {
compatible = "renesas,r8a7745-sysc";
reg = <0 0xe6180000 0 0x200>;
--
2.7.4
--
To unsubscribe from this list: send the line "unsubscribe linux-watchdog" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 54+ messages in thread
* [RFC v4 22/26] ARM: dts: r8a7790: Add watchdog support to SoC dtsi
[not found] ` <1517423070-24236-1-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
` (12 preceding siblings ...)
2018-01-31 18:24 ` [RFC v4 21/26] ARM: dts: r8a7745: " Fabrizio Castro
@ 2018-01-31 18:24 ` Fabrizio Castro
2018-02-07 23:20 ` Wolfram Sang
2018-01-31 18:24 ` [RFC v4 23/26] ARM: dts: r8a7791: " Fabrizio Castro
2018-01-31 18:24 ` [RFC v4 26/26] ARM: dts: iwg22m: Add watchdog support to SoM dtsi Fabrizio Castro
15 siblings, 1 reply; 54+ messages in thread
From: Fabrizio Castro @ 2018-01-31 18:24 UTC (permalink / raw)
To: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang
Cc: Guenter Roeck, devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-watchdog-u79uwXL29TY76Z2rM5mHXA,
linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-clk-u79uwXL29TY76Z2rM5mHXA, Chris Paterson, Biju Das,
Fabrizio Castro, Ramesh Shanmugasundaram
This commit adds watchdog support to the r8a7790 dtsi.
Signed-off-by: Fabrizio Castro <fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Reviewed-by: Geert Uytterhoeven <geert+renesas-gXvu3+zWzMSzQB+pC5nmwQ@public.gmane.org>
---
v3->4:
* no change
arch/arm/boot/dts/r8a7790.dtsi | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/arch/arm/boot/dts/r8a7790.dtsi b/arch/arm/boot/dts/r8a7790.dtsi
index a84bf35..83d6704 100644
--- a/arch/arm/boot/dts/r8a7790.dtsi
+++ b/arch/arm/boot/dts/r8a7790.dtsi
@@ -218,6 +218,16 @@
#size-cells = <2>;
ranges;
+ rwdt: watchdog@e6020000 {
+ compatible = "renesas,r8a7790-wdt",
+ "renesas,rcar-gen2-wdt";
+ reg = <0 0xe6020000 0 0x0c>;
+ clocks = <&cpg CPG_MOD 402>;
+ power-domains = <&sysc R8A7790_PD_ALWAYS_ON>;
+ resets = <&cpg 402>;
+ status = "disabled";
+ };
+
gpio0: gpio@e6050000 {
compatible = "renesas,gpio-r8a7790",
"renesas,rcar-gen2-gpio";
--
2.7.4
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 54+ messages in thread
* Re: [RFC v4 22/26] ARM: dts: r8a7790: Add watchdog support to SoC dtsi
2018-01-31 18:24 ` [RFC v4 22/26] ARM: dts: r8a7790: " Fabrizio Castro
@ 2018-02-07 23:20 ` Wolfram Sang
0 siblings, 0 replies; 54+ messages in thread
From: Wolfram Sang @ 2018-02-07 23:20 UTC (permalink / raw)
To: Fabrizio Castro
Cc: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang, Guenter Roeck, devicetree, linux-watchdog,
linux-renesas-soc, linux-arm-kernel, linux-clk, Chris Paterson,
Biju
[-- Attachment #1: Type: text/plain, Size: 402 bytes --]
On Wed, Jan 31, 2018 at 06:24:26PM +0000, Fabrizio Castro wrote:
> This commit adds watchdog support to the r8a7790 dtsi.
>
> Signed-off-by: Fabrizio Castro <fabrizio.castro@bp.renesas.com>
> Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram@bp.renesas.com>
> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Acked-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 54+ messages in thread
* [RFC v4 23/26] ARM: dts: r8a7791: Add watchdog support to SoC dtsi
[not found] ` <1517423070-24236-1-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
` (13 preceding siblings ...)
2018-01-31 18:24 ` [RFC v4 22/26] ARM: dts: r8a7790: " Fabrizio Castro
@ 2018-01-31 18:24 ` Fabrizio Castro
2018-02-07 23:20 ` Wolfram Sang
2018-01-31 18:24 ` [RFC v4 26/26] ARM: dts: iwg22m: Add watchdog support to SoM dtsi Fabrizio Castro
15 siblings, 1 reply; 54+ messages in thread
From: Fabrizio Castro @ 2018-01-31 18:24 UTC (permalink / raw)
To: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang
Cc: Guenter Roeck, devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-watchdog-u79uwXL29TY76Z2rM5mHXA,
linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-clk-u79uwXL29TY76Z2rM5mHXA, Chris Paterson, Biju Das,
Fabrizio Castro, Ramesh Shanmugasundaram
This commit adds watchdog support to the r8a7791 dtsi.
Signed-off-by: Fabrizio Castro <fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Reviewed-by: Geert Uytterhoeven <geert+renesas-gXvu3+zWzMSzQB+pC5nmwQ@public.gmane.org>
---
v3->4:
* no change
arch/arm/boot/dts/r8a7791.dtsi | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/arch/arm/boot/dts/r8a7791.dtsi b/arch/arm/boot/dts/r8a7791.dtsi
index d2a4546..80e20ecd 100644
--- a/arch/arm/boot/dts/r8a7791.dtsi
+++ b/arch/arm/boot/dts/r8a7791.dtsi
@@ -142,6 +142,16 @@
#size-cells = <2>;
ranges;
+ rwdt: watchdog@e6020000 {
+ compatible = "renesas,r8a7791-wdt",
+ "renesas,rcar-gen2-wdt";
+ reg = <0 0xe6020000 0 0x0c>;
+ clocks = <&cpg CPG_MOD 402>;
+ power-domains = <&sysc R8A7791_PD_ALWAYS_ON>;
+ resets = <&cpg 402>;
+ status = "disabled";
+ };
+
gpio0: gpio@e6050000 {
compatible = "renesas,gpio-r8a7791",
"renesas,rcar-gen2-gpio";
--
2.7.4
--
To unsubscribe from this list: send the line "unsubscribe linux-watchdog" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 54+ messages in thread
* Re: [RFC v4 23/26] ARM: dts: r8a7791: Add watchdog support to SoC dtsi
2018-01-31 18:24 ` [RFC v4 23/26] ARM: dts: r8a7791: " Fabrizio Castro
@ 2018-02-07 23:20 ` Wolfram Sang
0 siblings, 0 replies; 54+ messages in thread
From: Wolfram Sang @ 2018-02-07 23:20 UTC (permalink / raw)
To: Fabrizio Castro
Cc: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang, Guenter Roeck, devicetree, linux-watchdog,
linux-renesas-soc, linux-arm-kernel, linux-clk, Chris Paterson,
Biju
[-- Attachment #1: Type: text/plain, Size: 402 bytes --]
On Wed, Jan 31, 2018 at 06:24:27PM +0000, Fabrizio Castro wrote:
> This commit adds watchdog support to the r8a7791 dtsi.
>
> Signed-off-by: Fabrizio Castro <fabrizio.castro@bp.renesas.com>
> Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram@bp.renesas.com>
> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Acked-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 54+ messages in thread
* [RFC v4 26/26] ARM: dts: iwg22m: Add watchdog support to SoM dtsi
[not found] ` <1517423070-24236-1-git-send-email-fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
` (14 preceding siblings ...)
2018-01-31 18:24 ` [RFC v4 23/26] ARM: dts: r8a7791: " Fabrizio Castro
@ 2018-01-31 18:24 ` Fabrizio Castro
2018-02-07 23:21 ` Wolfram Sang
15 siblings, 1 reply; 54+ messages in thread
From: Fabrizio Castro @ 2018-01-31 18:24 UTC (permalink / raw)
To: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang
Cc: Guenter Roeck, devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-watchdog-u79uwXL29TY76Z2rM5mHXA,
linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-clk-u79uwXL29TY76Z2rM5mHXA, Chris Paterson, Biju Das,
Fabrizio Castro, Ramesh Shanmugasundaram
This patch enables the watchdog from within the iwg20m SoM dtsi.
Signed-off-by: Fabrizio Castro <fabrizio.castro-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram-kTT6dE0pTRh9uiUsa/gSgQ@public.gmane.org>
Reviewed-by: Geert Uytterhoeven <geert+renesas-gXvu3+zWzMSzQB+pC5nmwQ@public.gmane.org>
---
v3->4:
* no change
arch/arm/boot/dts/r8a7745-iwg22m.dtsi | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/arch/arm/boot/dts/r8a7745-iwg22m.dtsi b/arch/arm/boot/dts/r8a7745-iwg22m.dtsi
index 8d0a392b..29b6e10 100644
--- a/arch/arm/boot/dts/r8a7745-iwg22m.dtsi
+++ b/arch/arm/boot/dts/r8a7745-iwg22m.dtsi
@@ -91,6 +91,11 @@
};
};
+&rwdt {
+ timeout-sec = <60>;
+ status = "okay";
+};
+
&sdhi1 {
pinctrl-0 = <&sdhi1_pins>;
pinctrl-names = "default";
--
2.7.4
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 54+ messages in thread
* Re: [RFC v4 26/26] ARM: dts: iwg22m: Add watchdog support to SoM dtsi
2018-01-31 18:24 ` [RFC v4 26/26] ARM: dts: iwg22m: Add watchdog support to SoM dtsi Fabrizio Castro
@ 2018-02-07 23:21 ` Wolfram Sang
0 siblings, 0 replies; 54+ messages in thread
From: Wolfram Sang @ 2018-02-07 23:21 UTC (permalink / raw)
To: Fabrizio Castro
Cc: Philipp Zabel, Rob Herring, Mark Rutland, Wim Van Sebroeck,
Russell King, Catalin Marinas, Will Deacon, Michael Turquette,
Stephen Boyd, Simon Horman, Magnus Damm, Geert Uytterhoeven,
Wolfram Sang, Guenter Roeck, devicetree, linux-watchdog,
linux-renesas-soc, linux-arm-kernel, linux-clk, Chris Paterson,
Biju
[-- Attachment #1: Type: text/plain, Size: 415 bytes --]
On Wed, Jan 31, 2018 at 06:24:30PM +0000, Fabrizio Castro wrote:
> This patch enables the watchdog from within the iwg20m SoM dtsi.
>
> Signed-off-by: Fabrizio Castro <fabrizio.castro@bp.renesas.com>
> Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram@bp.renesas.com>
> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 54+ messages in thread