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: <aAhcU3Y9yjUcSWoc@casper.infradead.org>
Date: Wed, 23 Apr 2025 04:19:47 +0100
From: Matthew Wilcox <willy@...radead.org>
To: nifan.cxl@...il.com
Cc: muchun.song@...ux.dev, mcgrof@...nel.org, a.manzanares@...sung.com,
	dave@...olabs.net, akpm@...ux-foundation.org, david@...hat.com,
	linux-mm@...ck.org, linux-kernel@...r.kernel.org,
	Fan Ni <fan.ni@...sung.com>
Subject: Re: [PATCH v2 3/4] mm/hugetlb: Refactor __unmap_hugepage_range() to
 take folio instead of page

On Fri, Apr 18, 2025 at 09:57:41AM -0700, nifan.cxl@...il.com wrote:
> @@ -5910,8 +5910,8 @@ void __unmap_hugepage_range(struct mmu_gather *tlb, struct vm_area_struct *vma,
>  		 * page is being unmapped, not a range. Ensure the page we
>  		 * are about to unmap is the actual page of interest.
>  		 */
> -		if (ref_page) {
> -			if (page != ref_page) {
> +		if (ref_folio) {
> +			if (page != folio_page(ref_folio, 0)) {

I think this is actually wrong.  Shouldn't it be:

			if (page_folio(page) != ref_folio)

so that it doesn't matter which page in the folio we found; we just need
to know if the page belongs to the same folio or not?


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ