30 May, 2018
1 commit
-
[ Upstream commit 3c829f47e33eb0398a9a14e357a05199a7be0277 ]
If devm_reset_control_get_exclusive() fails, asm9260_wdt_probe()
returns immediately. But clks has been already enabled at that point,
so it is required to disable them or to move the code around.Found by Linux Driver Verification project (linuxtesting.org).
Signed-off-by: Alexey Khoroshilov
Reviewed-by: Guenter Roeck
Signed-off-by: Guenter Roeck
Signed-off-by: Wim Van Sebroeck
Signed-off-by: Sasha Levin
Signed-off-by: Greg Kroah-Hartman
10 Sep, 2017
2 commits
-
We should never return more time left than there actually is. So, switch
to a plain divider instead of DIV_ROUND_CLOSEST.Signed-off-by: Wolfram Sang
Reviewed-by: Guenter Roeck
Signed-off-by: Guenter Roeck
Signed-off-by: Wim Van Sebroeck -
Commit a53e35db70d1 ("reset: Ensure drivers are explicit when requesting
reset lines") started to transition the reset control request API calls
to explicitly state whether the driver needs exclusive or shared reset
control behavior. Convert all drivers requesting exclusive resets to the
explicit API call so the temporary transition helpers can be removed.No functional changes.
Cc: linux-watchdog@vger.kernel.org
Signed-off-by: Philipp Zabel
Reviewed-by: Guenter Roeck
Signed-off-by: Guenter Roeck
Signed-off-by: Wim Van Sebroeck
25 Feb, 2017
2 commits
-
Declare watchdog_ops structures as const as they are only stored in the
ops field of a watchdog_device structure. This field is of type const, so
watchdog_ops structures having this property can be made const too.
Done using Coccinelle:@r disable optional_qualifier@
identifier x;
position p;
@@
static struct watchdog_ops x@p={...};@ok@
struct watchdog_device w;
identifier r.x;
position p;
@@
w.ops=&x@p;@bad@
position p != {r.p,ok.p};
identifier r.x;
@@
x@p@depends on !bad disable optional_qualifier@
identifier r.x;
@@
+const
struct watchdog_ops x;File size details before and after patching.
First line of every .o file shows the file size before patching
and second line shows the size after patching.text data bss dec hex filename
1340 544 0 1884 75c drivers/watchdog/bcm_kona_wdt.o
1436 440 0 1876 754 drivers/watchdog/bcm_kona_wdt.o1176 544 4 1724 6bc drivers/watchdog/digicolor_wdt.o
1272 440 4 1716 6b4 drivers/watchdog/digicolor_wdt.o925 580 89 1594 63a drivers/watchdog/ep93xx_wdt.o
1021 476 89 1586 632 drivers/watchdog/ep93xx_wdt.o4932 288 17 5237 1475 drivers/watchdog/s3c2410_wdt.o
5028 192 17 5237 1475 drivers/watchdog/s3c2410_wdt.o1977 292 1 2270 8de drivers/watchdog/sama5d4_wdt.o
2073 196 1 2270 8de drivers/watchdog/sama5d4_wdt.o1375 484 1 1860 744 drivers/watchdog/sirfsoc_wdt.o
1471 380 1 1852 73c drivers/watchdog/sirfsoc_wdt.oSize remains the same for the files drivers/watchdog/diag288_wdt.o
drivers/watchdog/asm9260_wdt.o and drivers/watchdog/atlas7_wdt.oThe following .o files did not compile:
drivers/watchdog/sun4v_wdt.o, drivers/watchdog/sbsa_gwdt.o,
drivers/watchdog/rt2880_wdt.o, drivers/watchdog/booke_wdt.o
drivers/watchdog/mt7621_wdt.oSigned-off-by: Bhumika Goyal
Signed-off-by: Guenter Roeck -
Use the infrastructure provided by the watchdog core to install
the restart handler.Signed-off-by: Guenter Roeck
24 Sep, 2016
1 commit
-
The field "owner" is set by core. Thus delete an extra initialisation.
Generated by: scripts/coccinelle/api/platform_no_drv_owner.cocci
Signed-off-by: Markus Elfring
Reviewed-by: Guenter Roeck
Signed-off-by: Guenter Roeck
Signed-off-by: Wim Van Sebroeck
12 Jan, 2016
1 commit
-
The probe and release functions in this driver are marked
as __init and __exit, but this is wrong as indicated by this
Kbuild error message:WARNING: vmlinux.o(.data+0x1d2308): Section mismatch in reference from the variable asm9260_wdt_driver to the function .init.text:asm9260_wdt_probe()
This removes the annotations, to make the sysfs unbind attribute
and deferred probing work.Signed-off-by: Arnd Bergmann
Fixes: aae03dc98177 ("watchdog: add Alphascale asm9260-wdt driver")
Signed-off-by: Guenter Roeck
Signed-off-by: Wim Van Sebroeck
29 Dec, 2015
1 commit
-
Add WD support for Alphascale asm9260 SoC. This driver
provide support for different function modes:
- HW mode to trigger SoC reset on timeout
- SW mode do soft reset if needed
- DEBUG modeSigned-off-by: Oleksij Rempel
Signed-off-by: Guenter Roeck
Signed-off-by: Wim Van Sebroeck