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:	Thu, 10 Oct 2013 18:12:40 +0200
From:	Andrea Arcangeli <aarcange@...hat.com>
To:	Andrew Morton <akpm@...ux-foundation.org>
Cc:	qemu-devel@...gnu.org, kvm@...r.kernel.org, linux-mm@...ck.org,
	linux-kernel@...r.kernel.org, Gleb Natapov <gleb@...hat.com>,
	Mel Gorman <mgorman@...e.de>, Rik van Riel <riel@...hat.com>,
	Hugh Dickins <hughd@...gle.com>
Subject: [PATCH] initialize PG_reserved for tail pages of gigantig compound pages

Hi,

large CC list because the below patch is important to merge before
3.12 final, either that or 11feeb498086a3a5907b8148bdf1786a9b18fc55
should be reverted ASAP.

The optimization 11feeb498086a3a5907b8148bdf1786a9b18fc55 avoids
deferefencing the head page during KVM mmio vmexit, and it is a
worthwhile optimization.

However for it to work, PG_reserved must be identical between tail and
head pages of all compound pages (at least those that can end up used
as guest physical memory). That looked a safe assumption to make and
it is enforced everywhere except by the gigantic compound page
initialization code (i.e. KVM running on hugepagesz=1g didn't work as
expected).

This further patch enforces the above assumption for gigantic compound
pages too. It has been successfully verified to fix the gigantic
compound pages memory leak in combination with patch
11feeb498086a3a5907b8148bdf1786a9b18fc55.

Enforcing PG_reserved not set for tail pages of hugetlbfs gigantic
compound pages sounds safer regardless of commit
11feeb498086a3a5907b8148bdf1786a9b18fc55 to be consistent with the
other hugetlbfs page sizes (i.e hugetlbfs page order < MAX_ORDER).

Thanks,
Andrea

Andrea Arcangeli (1):
  mm: hugetlb: initialize PG_reserved for tail pages of gigantig
    compound pages

 mm/hugetlb.c | 18 +++++++++++++++++-
 1 file changed, 17 insertions(+), 1 deletion(-)

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