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]
Date:	Tue, 3 Aug 2010 14:09:42 GMT
From:	"tip-bot for H. Peter Anvin" <hpa@...or.com>
To:	linux-tip-commits@...r.kernel.org
Cc:	linux-kernel@...r.kernel.org, jdike@...toit.com, hpa@...or.com,
	mingo@...hat.com, tglx@...utronix.de
Subject: [tip:x86/asm] um, x86: Cast to (u64 *) inside set_64bit()

Commit-ID:  bf676945cb5bfe455321f57968967c18976f4995
Gitweb:     http://git.kernel.org/tip/bf676945cb5bfe455321f57968967c18976f4995
Author:     H. Peter Anvin <hpa@...or.com>
AuthorDate: Tue, 3 Aug 2010 07:00:16 -0700
Committer:  H. Peter Anvin <hpa@...or.com>
CommitDate: Tue, 3 Aug 2010 07:00:16 -0700

um, x86: Cast to (u64 *) inside set_64bit()

After tightening up the types passed to set_64bit(), the cast to
(phys_t *) triggers a warning apparently because phys_t is defined as
"unsigned long" when building on 64 bits; however, u64 is defined as
"unsigned long long".  This is, however, a explicit cast inside a
size-specific call, so just make the cast explicitly (u64 *).

Signed-off-by: H. Peter Anvin <hpa@...or.com>
Cc: Jeff Dike <jdike@...toit.com>
LKML-Reference: <tip-69309a05907546fb686b251d4ab041c26afe1e1d@....kernel.org>
---
 arch/um/include/asm/pgtable-3level.h |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/um/include/asm/pgtable-3level.h b/arch/um/include/asm/pgtable-3level.h
index 084de4a..0032f92 100644
--- a/arch/um/include/asm/pgtable-3level.h
+++ b/arch/um/include/asm/pgtable-3level.h
@@ -60,7 +60,7 @@
 	set_pud(pud, __pud(_PAGE_TABLE + __pa(pmd)))
 
 #ifdef CONFIG_64BIT
-#define set_pud(pudptr, pudval) set_64bit((phys_t *) (pudptr), pud_val(pudval))
+#define set_pud(pudptr, pudval) set_64bit((u64 *) (pudptr), pud_val(pudval))
 #else
 #define set_pud(pudptr, pudval) (*(pudptr) = (pudval))
 #endif
@@ -73,7 +73,7 @@ static inline int pgd_newpage(pgd_t pgd)
 static inline void pgd_mkuptodate(pgd_t pgd) { pgd_val(pgd) &= ~_PAGE_NEWPAGE; }
 
 #ifdef CONFIG_64BIT
-#define set_pmd(pmdptr, pmdval) set_64bit((phys_t *) (pmdptr), pmd_val(pmdval))
+#define set_pmd(pmdptr, pmdval) set_64bit((u64 *) (pmdptr), pmd_val(pmdval))
 #else
 #define set_pmd(pmdptr, pmdval) (*(pmdptr) = (pmdval))
 #endif
--
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