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>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20090227063955.GS11421@balbir.in.ibm.com>
Date:	Fri, 27 Feb 2009 12:09:55 +0530
From:	Balbir Singh <balbir@...ux.vnet.ibm.com>
To:	KAMEZAWA Hiroyuki <kamezawa.hiroyu@...fujitsu.com>
Cc:	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	kenchen@...gle.com, "menage@...gle.com" <menage@...gle.com>,
	"lizf@...fujitsu.com" <lizf@...fujitsu.com>, mingo@...e.hu,
	"akpm@...ux-foundation.org" <akpm@...ux-foundation.org>
Subject: Re: [PATCH] change cpuacct usage percpu format

* KAMEZAWA Hiroyuki <kamezawa.hiroyu@...fujitsu.com> [2009-02-27 14:05:37]:

> I'd like to change cpuacct.usage_percpu format before it's widely used.
> Current format is not easy to use in hardware with DR feature.
> 
> ==
> cpuacct.usage_percpu shows per cpu usage information via cgroupfs.
> It shows all present cpus information and "whose information ?"
> is explained just by index of data implicitly.
> 
> IIRC, there is physical cpu hotplug and it can remove
> cpus and change present map. Considering a software which records
> this information pediodically(like sar.), its better to show id of cpu
> in explict way.
> 
> Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@...fujitsu.com>
> ---
>  kernel/sched.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> Index: mmotm-2.6.29-Feb24/kernel/sched.c
> ===================================================================
> --- mmotm-2.6.29-Feb24.orig/kernel/sched.c
> +++ mmotm-2.6.29-Feb24/kernel/sched.c
> @@ -9719,7 +9719,7 @@ static int cpuacct_percpu_seq_read(struc
> 
>  	for_each_present_cpu(i) {
>  		percpu = cpuacct_cpuusage_read(ca, i);
> -		seq_printf(m, "%llu ", (unsigned long long) percpu);
> +		seq_printf(m, "%d %llu\n", i, (unsigned long long) percpu);

Seems like a reasonable change, but I wonder if " " should the
separator between the CPU and data, I wounder if we should use
cpu:usage_per_cpu.
-- 
	Balbir
--
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