summaryrefslogtreecommitdiff
path: root/drivers/watchdog
diff options
context:
space:
mode:
authorKari Argillander2025-12-19 22:42:38 +0200
committerWim Van Sebroeck2026-01-18 10:56:10 +0100
commit439cf01b2e0030eed6020a03a7df4a528f8db7ba (patch)
treefa2db4c8c73ad4f332e510cdd813857771d24f1c /drivers/watchdog
parentd303d37ef5cf86c8c3b2daefd2a7d7fd8ca1ec14 (diff)
watchdog: Make API functions const correct
Many watchdog API functions do not modify the watchdog_device nor device. Mark their arguments as const to reflect this and improve const-correctness of the API. No functional change intended. Signed-off-by: Kari Argillander <kari.argillander@gmail.com> Reviewed-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@linux-watchdog.org>
Diffstat (limited to 'drivers/watchdog')
-rw-r--r--drivers/watchdog/watchdog_core.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/watchdog/watchdog_core.c b/drivers/watchdog/watchdog_core.c
index 6152dba4b52c..8300520688d0 100644
--- a/drivers/watchdog/watchdog_core.c
+++ b/drivers/watchdog/watchdog_core.c
@@ -117,7 +117,8 @@ static void watchdog_check_min_max_timeout(struct watchdog_device *wdd)
* bounds.
*/
int watchdog_init_timeout(struct watchdog_device *wdd,
- unsigned int timeout_parm, struct device *dev)
+ unsigned int timeout_parm,
+ const struct device *dev)
{
const char *dev_str = wdd->parent ? dev_name(wdd->parent) :
(const char *)wdd->info->identity;