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] [day] [month] [year] [list]
Message-ID: <a15b93d8-3b8a-4b3a-a40b-016efe9d12a2@arm.com>
Date: Fri, 21 Mar 2025 10:18:15 +0530
From: Anshuman Khandual <anshuman.khandual@....com>
To: Ye Liu <ye.liu@...ux.dev>, akpm@...ux-foundation.org
Cc: linux-mm@...ck.org, linux-kernel@...r.kernel.org,
 Ye Liu <liuye@...inos.cn>
Subject: Re: [PATCH] mm/page_alloc: Replace flag check with PageHWPoison() in
 check_new_page_bad()



On 3/20/25 12:03, Ye Liu wrote:
> From: Ye Liu <liuye@...inos.cn>
> 
> This patch replaces the direct check for the __PG_HWPOISON flag with
> the PageHWPoison() macro, improving code readability and maintaining
> consistency with other parts of the memory management code.
> 
> Signed-off-by: Ye Liu <liuye@...inos.cn>
> ---
>  mm/page_alloc.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/mm/page_alloc.c b/mm/page_alloc.c
> index fe76fd237dd0..6ef54abebf51 100644
> --- a/mm/page_alloc.c
> +++ b/mm/page_alloc.c
> @@ -1427,7 +1427,7 @@ static __always_inline void page_del_and_expand(struct zone *zone,
>  
>  static void check_new_page_bad(struct page *page)
>  {
> -	if (unlikely(page->flags & __PG_HWPOISON)) {
> +	if (unlikely(PageHWPoison(page))) {
>  		/* Don't complain about hwpoisoned pages */
>  		if (PageBuddy(page))
>  			__ClearPageBuddy(page);

Reviewed-by: Anshuman Khandual <anshuman.khandual@....com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ