All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v4 0/3] watchdog: add wdt and reset for renesas r7s72100
@ 2017-03-02 13:57 ` Chris Brandt
  0 siblings, 0 replies; 21+ messages in thread
From: Chris Brandt @ 2017-03-02 13:57 UTC (permalink / raw)
  To: Wim Van Sebroeck, Guenter Roeck, Sebastian Reichel, Rob Herring,
	Mark Rutland, Simon Horman, Geert Uytterhoeven
  Cc: linux-renesas-soc-u79uwXL29TY76Z2rM5mHXA,
	devicetree-u79uwXL29TY76Z2rM5mHXA,
	linux-watchdog-u79uwXL29TY76Z2rM5mHXA, Chris Brandt

Some Renesas SoCs do not have a reset register and the only way to do a SW
controlled reset is to use the watchdog timer. So while this series started
out by only adding a reset feature, now it's a full watchdog timer driver that
includes a reset handler.

The longest WDT overflow you can get with a RZ/A1 (R7S72100) with its 8-bit
wide counter is 125ms. Not very long.

However, by setting max_hw_heartbeat_ms, the watchdog core will now handle
pinging the WDT automatically and allow the user to set times as big as they
want. Therefore, the default timeout for this driver is 30 seconds.

Of course if system interrupts are disabled too long and wdt can't be pinged
by the watchdog core, then the system will reset before the user specified
timeout. But hey, it's better nothing.

This driver was tested on an RZ/A1 RSK board using watchdog-simple.c from
samples/watchdog/.

v4:
* r7s72100.dtsi: changed from timer@ to watchdog@

v3:
* changed from a reset driver to a watchdog timer driver
* use udelay(20) instead of msleep for reset handler
* added Reviewed-by for r7s72100.dtsi and renesas-wdt.txt
* added Acked-by for renesas-wdt.txt

v2:
* added to renesas-wdt.txt instead of creating a new file
* changed "renesas,r7s72100-reset" to "renesas,r7s72100-wdt"
* changed "renesas,wdt-reset" to "renesas,rza-wdt"
* added "renesas,rza-wdt" as a fallback
* added interupt property (even though it is not used)
* added clocks property
* changed hard coded register values to defines
* added msleep to while(1) loop
* removed unnecessary #include files
* added Reviewed-by: Geert Uytterhoeven for renesas-reset.c

Chris Brandt (3):
  watchdog: add rza_wdt driver
  watchdog: renesas-wdt: add support for rza
  ARM: dts: r7s72100: Add watchdog timer

 .../devicetree/bindings/watchdog/renesas-wdt.txt   |   4 +-
 arch/arm/boot/dts/r7s72100.dtsi                    |   7 +
 drivers/watchdog/Kconfig                           |   8 +
 drivers/watchdog/Makefile                          |   1 +
 drivers/watchdog/rza_wdt.c                         | 208 +++++++++++++++++++++
 5 files changed, 227 insertions(+), 1 deletion(-)
 create mode 100644 drivers/watchdog/rza_wdt.c

-- 
2.10.1


--
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	[flat|nested] 21+ messages in thread

end of thread, other threads:[~2017-03-03 10:17 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-03-02 13:57 [PATCH v4 0/3] watchdog: add wdt and reset for renesas r7s72100 Chris Brandt
2017-03-02 13:57 ` Chris Brandt
     [not found] ` <20170302135746.30550-1-chris.brandt-zM6kxYcvzFBBDgjK7y7TUQ@public.gmane.org>
2017-03-02 13:57   ` [PATCH v4 1/3] watchdog: add rza_wdt driver Chris Brandt
2017-03-02 13:57     ` Chris Brandt
     [not found]     ` <20170302135746.30550-2-chris.brandt-zM6kxYcvzFBBDgjK7y7TUQ@public.gmane.org>
2017-03-02 14:56       ` Guenter Roeck
2017-03-02 14:56         ` Guenter Roeck
     [not found]         ` <bf76e106-9272-622c-8d4e-c270a6b51d16-0h96xk9xTtrk1uMJSBkQmQ@public.gmane.org>
2017-03-02 15:38           ` Chris Brandt
2017-03-02 15:38             ` Chris Brandt
2017-03-02 17:11             ` Guenter Roeck
     [not found]               ` <20170302171148.GA28554-0h96xk9xTtrk1uMJSBkQmQ@public.gmane.org>
2017-03-02 17:31                 ` Chris Brandt
2017-03-02 17:31                   ` Chris Brandt
     [not found]                   ` <SG2PR06MB11656393CB487F8413DAD58C8A280-ESzmfEwOt/xoAsOJh7vwSm0DtJ1/0DrXvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
2017-03-02 17:48                     ` Guenter Roeck
2017-03-02 17:48                       ` Guenter Roeck
     [not found]                       ` <20170302174855.GD28554-0h96xk9xTtrk1uMJSBkQmQ@public.gmane.org>
2017-03-02 18:22                         ` Chris Brandt
2017-03-02 18:22                           ` Chris Brandt
     [not found]                           ` <SG2PR06MB1165F37B234CE0353B4E86B98A280-ESzmfEwOt/xoAsOJh7vwSm0DtJ1/0DrXvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
2017-03-02 18:39                             ` Guenter Roeck
2017-03-02 18:39                               ` Guenter Roeck
     [not found]             ` <SG2PR06MB11656FE3E3CF8BAA1B8A86688A280-ESzmfEwOt/xoAsOJh7vwSm0DtJ1/0DrXvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
2017-03-03 10:16               ` Geert Uytterhoeven
2017-03-03 10:16                 ` Geert Uytterhoeven
2017-03-02 13:57 ` [PATCH v4 2/3] watchdog: renesas-wdt: add support for rza Chris Brandt
2017-03-02 13:57 ` [PATCH v4 3/3] ARM: dts: r7s72100: Add watchdog timer Chris Brandt

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.