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]
Date:	Fri, 12 Nov 2010 10:36:14 -0800 (PST)
From:	David Rientjes <rientjes@...gle.com>
To:	Artur Baruchi <mail.baruchi@...il.com>
cc:	linux-kernel@...r.kernel.org
Subject: Re: mem_map array on NUMA

On Fri, 12 Nov 2010, Artur Baruchi wrote:

> Hi David.
> 
> Thanks for your answer.
> 
> Basically, I would like to get information about memory pages, without
> "worry" about which zone its owned. I tried to use the code you've send, but
> some macros are not beeing exported by the Kernel (I cannot use it in
> drivers/modules). Im facing the follow errors:
> 
> *WARNING: "next_zone" [/root/DRIVER/xxxxxxxx.ko] undefined!
> WARNING: "first_online_pgdat" [/root/DRIVER/**xxxxxxxx.ko**] undefined!*
> 
> Do you have any idea about how can I handle this error?
> 

For your use-case, you can simply iterate through each pfn without 
worrying about their zones, something like:

	unsigned long pfn;

	for (pfn = 0; pfn < max_pfn; pfn++) {
		struct page *page;

		if (!pfn_valid(pfn))
			continue;
		page = pfn_to_page(pfn);
		/* do something with page */
	}		

> Thanks in advance.
> 
> Att.
> Artur Baruchi
--
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