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: <alpine.DEB.1.10.0906301011210.6124@gentwo.org>
Date:	Tue, 30 Jun 2009 10:13:34 -0400 (EDT)
From:	Christoph Lameter <cl@...ux-foundation.org>
To:	KOSAKI Motohiro <kosaki.motohiro@...fujitsu.com>
cc:	Minchan Kim <minchan.kim@...il.com>,
	Johannes Weiner <hannes@...xchg.org>,
	David Howells <dhowells@...hat.com>,
	"riel@...hat.com" <riel@...hat.com>,
	Andrew Morton <akpm@...ux-foundation.org>,
	LKML <linux-kernel@...r.kernel.org>,
	"peterz@...radead.org" <peterz@...radead.org>,
	"tytso@....edu" <tytso@....edu>,
	"linux-mm@...ck.org" <linux-mm@...ck.org>,
	"elladan@...imo.com" <elladan@...imo.com>,
	"npiggin@...e.de" <npiggin@...e.de>,
	"Barnes, Jesse" <jesse.barnes@...el.com>
Subject: Re: [PATCH] Show kernel stack usage to /proc/meminfo and OOM log

On Tue, 30 Jun 2009, KOSAKI Motohiro wrote:

> +static void account_kernel_stack(struct thread_info *ti, int on)

static inline?

> +{
> +	struct zone* zone = page_zone(virt_to_page(ti));
> +	int sign = on ? 1 : -1;
> +	long acct = sign * (THREAD_SIZE / PAGE_SIZE);

int pages = THREAD_SIZE / PAGE_SIZE;

?

> +
> +	mod_zone_page_state(zone, NR_KERNEL_STACK, acct);

mod_zone_page_state(zone, NR_KERNEL_STACK, on ? pages : -pages);


--
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