mirror of
https://github.com/coolsnowwolf/lede.git
synced 2025-07-30 22:36:58 +08:00

These patches were generated from: https://github.com/raspberrypi/linux/commits/rpi-6.12.y With the following command: git format-patch -N v6.12.27..HEAD (HEAD -> 8d3206ee456a5ecdf9ddbfd8e5e231e4f0cd716e) Exceptions: - (def)configs patches - github workflows patches - applied & reverted patches - readme patches - wireless patches Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
36 lines
1.2 KiB
Diff
36 lines
1.2 KiB
Diff
From e85b586e92a53944abbe1263080c92e2b1c688ec Mon Sep 17 00:00:00 2001
|
|
From: Phil Elwell <phil@raspberrypi.com>
|
|
Date: Tue, 29 Apr 2025 14:00:13 +0100
|
|
Subject: [PATCH] watchdog: Reduce severity of release without stop
|
|
|
|
Distinguish between releasing the watchdog without requesting that it is
|
|
stopped, and failing to stop it when requested. The former is standard
|
|
behaviour for systemd, while the latter may be unexpected.
|
|
|
|
Signed-off-by: Phil Elwell <phil@raspberrypi.com>
|
|
---
|
|
drivers/watchdog/watchdog_dev.c | 5 ++++-
|
|
1 file changed, 4 insertions(+), 1 deletion(-)
|
|
|
|
--- a/drivers/watchdog/watchdog_dev.c
|
|
+++ b/drivers/watchdog/watchdog_dev.c
|
|
@@ -943,7 +943,7 @@ static int watchdog_release(struct inode
|
|
{
|
|
struct watchdog_core_data *wd_data = file->private_data;
|
|
struct watchdog_device *wdd;
|
|
- int err = -EBUSY;
|
|
+ int err = EBUSY; /* +ve because this may be expected behaviour */
|
|
bool running;
|
|
|
|
mutex_lock(&wd_data->lock);
|
|
@@ -967,6 +967,9 @@ static int watchdog_release(struct inode
|
|
if (err < 0) {
|
|
pr_crit("watchdog%d: watchdog did not stop!\n", wdd->id);
|
|
watchdog_ping(wdd);
|
|
+ } else if (err > 0) {
|
|
+ pr_info("watchdog%d: watchdog left running\n", wdd->id);
|
|
+ watchdog_ping(wdd);
|
|
}
|
|
|
|
watchdog_update_worker(wdd);
|