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]
Message-Id: <20241212012009.2147-1-zhangjiao2@cmss.chinamobile.com>
Date: Thu, 12 Dec 2024 09:20:09 +0800
From: zhangjiao2 <zhangjiao2@...s.chinamobile.com>
To: tglx@...utronix.de
Cc: mingo@...hat.com,
	bp@...en8.de,
	dave.hansen@...ux.intel.com,
	linux-kernel@...r.kernel.org,
	x86@...nel.org,
	zhang jiao <zhangjiao2@...s.chinamobile.com>
Subject: [PATCH] mm/x86: Redefine pgd_clear

From: zhang jiao <zhangjiao2@...s.chinamobile.com>

Do not use the 'void' type in conditional expression.

Signed-off-by: zhang jiao <zhangjiao2@...s.chinamobile.com>
---
 arch/x86/include/asm/pgtable.h | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/arch/x86/include/asm/pgtable.h b/arch/x86/include/asm/pgtable.h
index 593f10aabd45..c149e47122b8 100644
--- a/arch/x86/include/asm/pgtable.h
+++ b/arch/x86/include/asm/pgtable.h
@@ -74,7 +74,10 @@ extern pmdval_t early_pmd_flags;
 
 #ifndef __PAGETABLE_P4D_FOLDED
 #define set_pgd(pgdp, pgd)		native_set_pgd(pgdp, pgd)
-#define pgd_clear(pgd)			(pgtable_l5_enabled() ? native_pgd_clear(pgd) : 0)
+#define pgd_clear(pgd) do {						\
+	if (pgtable_l5_enabled())					\
+		native_pgd_clear(pgd);			\
+} while (0)
 #endif
 
 #ifndef set_p4d
-- 
2.33.0




Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ