Skip to contentSkip to conversation

MIPS: fix types u64 and __u64 to unsigned long long

PATCH Superseded Daniel Schwierzeck 2 participants 2 messages Mar 4, 2014 MIPS

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 MIPS: fix types u64 and __u64 to unsigned long long

Linux MIPS uses asm-generic/int-ll64.h in asm/types.h. Thus u64 and __u64 are defined as unsigned long long. Port this over to U-Boot.

---
This fixes all warnings on qemu_mips64 introduced by patch
http://patchwork.ozlabs.org/patch/324673/.

---
 arch/mips/include/asm/types.h | 23 +++--------------------
 1 file changed, 3 insertions(+), 20 deletions(-)
arch/mips/include/asm/types.h +3 -20
index d4bb859..aebafdb 100644
@@ -27,18 +27,12 @@ typedef unsigned short __u16;
 typedef __signed__ int __s32;
 typedef unsigned int __u32;
 
-#if (_MIPS_SZLONG == 64)
-
-typedef __signed__ long __s64;
-typedef unsigned long __u64;
-
-#else
-
 #if defined(__GNUC__)
 __extension__ typedef __signed__ long long __s64;
 __extension__ typedef unsigned long long __u64;
-#endif
-
+#else
+typedef __signed__ long long __s64;
+typedef unsigned long long __u64;
 #endif
 
 #endif /* __ASSEMBLY__ */
@@ -61,19 +55,8 @@ typedef unsigned short u16;
 typedef __signed int s32;
 typedef unsigned int u32;
 
-#if (_MIPS_SZLONG == 64)
-
-typedef __signed__ long s64;
-typedef unsigned long u64;
-
-#else
-
-#if defined(__GNUC__) && !defined(__STRICT_ANSI__)
 typedef __signed__ long long s64;
 typedef unsigned long long u64;
-#endif
-
-#endif
 
 #if (defined(CONFIG_HIGHMEM) && defined(CONFIG_64BIT_PHYS_ADDR)) \
     || defined(CONFIG_64BIT)
Signature · 1 line
1.8.3.2
#1 lore raw

PATCH 1/1 MIPS: fix types u64 and __u64 to unsigned long long

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 4 lines · Daniel Schwierzeck

Linux MIPS uses asm-generic/int-ll64.h in asm/types.h. Thus u64 and __u64 are defined as unsigned long long. Port this over to U-Boot.

I hoped this would be the fix, thanks!

And if you want to get me a u-boot-mips PR soon I'll take it along.

- --
Tom
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQIcBAEBAgAGBQJTFlU3AAoJENk4IS6UOR1WhPcP/39Tsq5DayeAgqxrPKvuKs1G MkceDhyn+cu/48vNRPNw4q3DtCa80w8V39TL/lNdSgNVti1H22BVJZptFlOwcsMG pxlav080EVtYOcLarCf4FysJXy78Wnz5EGp0McolwRYTrGQpjAfiBoeoRqrvtZ8K dLzROa5FptTOnMzeQ+j/OTUGoFri+ZhXzLD6h1MgB/awraM/LMd3myYK+KQyk05U ju+n9HkhZO+cicwnjEFsW8sQyY1/vNzp5du7xA5n3Jhi4vMvgsUWkzKkWtx//eQV ZTvLTgg6AK6D0tsa3G5xcHkgTJlRDw09aiTyOWP6sdD1+sc1R/7ajAwoo5tjI6LD kmy1eTpjjXGIya37N1qlwHhYdo3YtjGOfbomgqfwUvVDJMiPhQ61aZsERCYbIC0z Z69JzHjyMCrv8YjOU3aC7rH9ZXvJGFjMa0vzwrSq8dMwFcYkOGyk/CMdslQtEly5 pAzZ/qC1e9AuQ8Gh23G6V9rmpGVuyOjKiuF9SPqsMgJyV2mY8fXBC1V2pTX5A09U LcOW5nYrXg/9fe0T1xR6OFd43GMHJNZOB33RKIjyJ2azDTG6qNl380bbAWyA4omT 8c1QagsZBXxV56S6yWDn6ytDzkz8bq2B2L05N+e+t2lIW0P/hJkzb7SrTn2T+1FS h81hKzfTFit41LI4gh8k
=tTQY
-----END PGP SIGNATURE-----