watchdog: imgpdc: Allow timeout to be set in device-tree
authorAndrew Bresticker <abrestic@chromium.org>
Fri, 3 Apr 2015 17:05:20 +0000 (10:05 -0700)
committerWim Van Sebroeck <wim@iguana.be>
Mon, 22 Jun 2015 13:54:12 +0000 (15:54 +0200)
commit7094e1dd2ba98f1eb534c262deebbc65e34fe132
tree676f6c41e114e7ce940ade74b76a1187100f4809
parent530c11d432727c697629ad5f9d00ee8e2864d453
watchdog: imgpdc: Allow timeout to be set in device-tree

Since the heartbeat is statically initialized to its default value,
watchdog_init_timeout() will never look in the device-tree for a
timeout-sec value.  Instead of statically initializing heartbeat,
fall back to the default timeout value if watchdog_init_timeout()
fails.

Signed-off-by: Andrew Bresticker <abrestic@chromium.org>
Reviewed-by: Ezequiel Garcia <ezequiel.garcia@imgtec.com>
Tested-by: Ezequiel Garcia <ezequiel.garcia@imgtec.com>
Cc: James Hogan <james.hogan@imgtec.com>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
drivers/watchdog/imgpdc_wdt.c