lkml.org 
[lkml]   [2015]   [Dec]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: vmstat: make vmstat_updater deferrable again and shut down on idle
Hmmm... We got a race condition since quiet_vmstat touches cpu_stat_off
which may not be allocated early in the bootup sequence. Causes oopses on
boot.



Subject: vmstat: quieting vmstat requires a running system

Do not do anything unless the system is actually running. Otherwise
we may crash on bootup.

Signed-off-by: Christoph Lameter <cl@linux.com>

Index: linux/mm/vmstat.c
===================================================================
--- linux.orig/mm/vmstat.c
+++ linux/mm/vmstat.c
@@ -1270,6 +1270,9 @@ static void vmstat_update(struct work_st
*/
void quiet_vmstat(void)
{
+ if (system_state != SYSTEM_RUNNING)
+ return;
+
do {
if (!cpumask_test_and_set_cpu(smp_processor_id(), cpu_stat_off))
cancel_delayed_work(this_cpu_ptr(&vmstat_work));

\
 
 \ /
  Last update: 2015-12-14 20:01    [W:0.056 / U:0.208 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site