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-next>] [day] [month] [year] [list]
Date:	Mon, 22 Feb 2016 10:56:55 +0800
From:	Xishi Qiu <qiuxishi@...wei.com>
To:	Linux MM <linux-mm@...ck.org>, LKML <linux-kernel@...r.kernel.org>
Subject: [RFC] mm: why we should clear page when do anonymous page fault

handle_pte_fault()
	do_anonymous_page()
		alloc_zeroed_user_highpage_movable()

We will alloc a zeroed page when do anonymous page fault, I don't know
why should clear it? just for safe?

If user space program do like the following, there are two memset 0, right?
kernel alloc zeroed page, and user memset 0 it again, this will waste a
lot of time.

main()
{
	...
	vaddr = malloc(size)
	if (vaddr)
		memset(vaddr, 0, size);
	...
}


Thanks,
Xishi Qiu

Powered by blists - more mailing lists