BUSYBOX: adapt to new version of KIRKSTONE
Signed-off-by: Christophe Priouzeau <christophe.priouzeau@foss.st.com>
This commit is contained in:
parent
5a6099a634
commit
a3425ad76b
|
|
@ -1,20 +1,20 @@
|
||||||
From 08d9bcdef21f117511e109d28507c9f76045914f Mon Sep 17 00:00:00 2001
|
From 6369613da1d212c67c2c6001a77f4949938addc7 Mon Sep 17 00:00:00 2001
|
||||||
From: Yannick Fertre <yannick.fertre@st.com>
|
From: Christophe Priouzeau <christophe.priouzeau@foss.st.com>
|
||||||
Date: Fri, 16 Sep 2016 16:59:37 +0200
|
Date: Mon, 3 Jan 2022 16:03:20 +0100
|
||||||
Subject: [PATCH] miscutils: watchdog: Add gettimeleft
|
Subject: [PATCH] miscutils: watchdog: Add gettimeleft
|
||||||
|
|
||||||
For purpose debug only, call of ioctl GETTIMELEFT
|
For purpose debug only, call of ioctl GETTIMELEFT
|
||||||
|
|
||||||
Signed-off-by: Yannick Fertre <yannick.fertre@st.com>
|
Signed-off-by: Yannick Fertre <yannick.fertre@st.com>
|
||||||
---
|
---
|
||||||
/miscutils/watchdog.c | 5 +++++
|
miscutils/watchdog.c | 4 ++++
|
||||||
1 file changed, 5 insertions(+)
|
1 file changed, 4 insertions(+)
|
||||||
|
|
||||||
diff --git a//miscutils/watchdog.c b//miscutils/watchdog.c
|
diff --git a/miscutils/watchdog.c b/miscutils/watchdog.c
|
||||||
index d3a76ed..d8e1c0e 100644
|
index d8e9c78..4227188 100644
|
||||||
--- a//miscutils/watchdog.c
|
--- a/miscutils/watchdog.c
|
||||||
+++ b//miscutils/watchdog.c
|
+++ b/miscutils/watchdog.c
|
||||||
@@ -50,6 +50,7 @@ int watchdog_main(int argc, char **argv)
|
@@ -110,6 +110,7 @@ int watchdog_main(int argc UNUSED_PARAM, char **argv)
|
||||||
unsigned opts;
|
unsigned opts;
|
||||||
unsigned stimer_duration; /* how often to restart */
|
unsigned stimer_duration; /* how often to restart */
|
||||||
unsigned htimer_duration = 60000; /* reboots after N ms if not restarted */
|
unsigned htimer_duration = 60000; /* reboots after N ms if not restarted */
|
||||||
|
|
@ -22,11 +22,10 @@ index d3a76ed..d8e1c0e 100644
|
||||||
char *st_arg;
|
char *st_arg;
|
||||||
char *ht_arg;
|
char *ht_arg;
|
||||||
|
|
||||||
@@ -105,6 +106,10 @@ int watchdog_main(int argc, char **argv)
|
@@ -160,6 +161,9 @@ int watchdog_main(int argc UNUSED_PARAM, char **argv)
|
||||||
*/
|
*/
|
||||||
write(3, "", 1); /* write zero byte */
|
write(3, "", 1); /* write zero byte */
|
||||||
usleep(stimer_duration * 1000L);
|
msleep(stimer_duration);
|
||||||
+
|
|
||||||
+#ifdef WDIOC_GETTIMELEFT
|
+#ifdef WDIOC_GETTIMELEFT
|
||||||
+ ioctl_or_warn(3, WDIOC_GETTIMELEFT, &time_left);
|
+ ioctl_or_warn(3, WDIOC_GETTIMELEFT, &time_left);
|
||||||
+#endif
|
+#endif
|
||||||
|
|
@ -34,5 +33,5 @@ index d3a76ed..d8e1c0e 100644
|
||||||
return EXIT_SUCCESS; /* - not reached, but gcc 4.2.1 is too dumb! */
|
return EXIT_SUCCESS; /* - not reached, but gcc 4.2.1 is too dumb! */
|
||||||
}
|
}
|
||||||
--
|
--
|
||||||
1.9.1
|
2.25.1
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue