-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path0105-ksm-wakeups.patch
33 lines (31 loc) · 1.56 KB
/
0105-ksm-wakeups.patch
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
diff -up linux-6.8-rc3/kernel/watchdog.c.55~ linux-6.8-rc3/kernel/watchdog.c
--- linux-6.8-rc3/kernel/watchdog.c.55~ 2024-02-04 13:20:36.000000000 +0100
+++ linux-6.8-rc3/kernel/watchdog.c 2024-02-09 15:09:25.100848779 +0100
@@ -39,7 +39,7 @@ unsigned long __read_mostly watchdog_ena
int __read_mostly watchdog_user_enabled = 1;
static int __read_mostly watchdog_hardlockup_user_enabled = WATCHDOG_HARDLOCKUP_DEFAULT;
static int __read_mostly watchdog_softlockup_user_enabled = 1;
-int __read_mostly watchdog_thresh = 10;
+int __read_mostly watchdog_thresh = 40;
static int __read_mostly watchdog_hardlockup_available;
struct cpumask watchdog_cpumask __read_mostly;
diff -up linux-6.8-rc3/mm/ksm.c.55~ linux-6.8-rc3/mm/ksm.c
--- linux-6.8-rc3/mm/ksm.c.55~ 2024-02-09 15:09:25.100848779 +0100
+++ linux-6.8-rc3/mm/ksm.c 2024-02-09 15:16:55.289135994 +0100
@@ -2782,9 +2782,14 @@ static int ksm_scan_thread(void *nothing
if (ksmd_should_run()) {
sleep_ms = READ_ONCE(ksm_thread_sleep_millisecs);
- wait_event_freezable_timeout(ksm_iter_wait,
- sleep_ms != READ_ONCE(ksm_thread_sleep_millisecs),
- msecs_to_jiffies(sleep_ms));
+ if (sleep_ms >= 1000)
+ wait_event_freezable_timeout(ksm_iter_wait,
+ sleep_ms != READ_ONCE(ksm_thread_sleep_millisecs),
+ msecs_to_jiffies(round_jiffies_relative(sleep_ms)));
+ else
+ wait_event_freezable_timeout(ksm_iter_wait,
+ sleep_ms != READ_ONCE(ksm_thread_sleep_millisecs),
+ msecs_to_jiffies(sleep_ms));
} else {
wait_event_freezable(ksm_thread_wait,
ksmd_should_run() || kthread_should_stop());