lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <Pine.LNX.4.64.0705101055060.9982@schroedinger.engr.sgi.com>
Date:	Thu, 10 May 2007 10:55:42 -0700 (PDT)
From:	Christoph Lameter <clameter@....com>
To:	Arjan van de Ven <arjan@...ux.intel.com>
cc:	linux-kernel@...r.kernel.org
Subject: VM statistics: Make timer deferrable

VM statistics updates do not matter if the kernel is in idle powersaving mode.
So allow the timer to be deferred.

It would be better though if we could switch the timer between deferrable
and nondeferrable based on differentials present. The timer would
start out nondeferrable and if we find that there were no updates in
the last statistics interval then we would switch the timer to deferrable.
If the timer later finds again that there are differentials then go to
nondeferrable again.

And yet another way would be to run the timer shortly before going to idle?

The solution here means that the VM counters may be slightly off during idle
since differentials may be still pending while the timer is deferred.

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

---
 mm/vmstat.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Index: slub/mm/vmstat.c
===================================================================
--- slub.orig/mm/vmstat.c	2007-05-10 10:09:19.000000000 -0700
+++ slub/mm/vmstat.c	2007-05-10 10:10:14.000000000 -0700
@@ -698,7 +698,7 @@ static void __devinit start_cpu_timer(in
 {
 	struct delayed_work *vmstat_work = &per_cpu(vmstat_work, cpu);
 
-	INIT_DELAYED_WORK(vmstat_work, vmstat_update);
+	INIT_DELAYED_WORK_DEFERRABLE(vmstat_work, vmstat_update);
 	schedule_delayed_work_on(cpu, vmstat_work, HZ + cpu);
 }
 
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ