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: <BD79186B4FD85F4B8E60E381CAEE1909015F8D05@mi8nycmail19.Mi8.com>
Date:	Wed, 15 Apr 2009 15:28:14 -0400
From:	"H Hartley Sweeten" <hartleys@...ionengravers.com>
To:	<linux-kernel@...r.kernel.org>
Subject: [PATCH] lib/crc32.c: fix sparse warnings

Fix four sparse warnings in lib/crc32.c.

	warning: symbol 'p' shadows an earlier one

Signed-off-by: H Hartley Sweeten <hsweeten@...ionengravers.com>

---

diff --git a/lib/crc32.c b/lib/crc32.c
index 49d1c9e..14a2e5a 100644
--- a/lib/crc32.c
+++ b/lib/crc32.c
@@ -85,9 +85,9 @@ u32 __pure crc32_le(u32 crc, unsigned char const *p,
size_t len)
 	/* Align it */
 	if(unlikely(((long)b)&3 && len)){
 		do {
-			u8 *p = (u8 *)b;
-			DO_CRC(*p++);
-			b = (void *)p;
+			u8 *_p = (u8 *)b;
+			DO_CRC(*_p++);
+			b = (void *)_p;
 		} while ((--len) && ((long)b)&3 );
 	}
 	if(likely(len >= 4)){
@@ -108,9 +108,9 @@ u32 __pure crc32_le(u32 crc, unsigned char const *p,
size_t len)
 	/* And the last few bytes */
 	if(len){
 		do {
-			u8 *p = (u8 *)b;
-			DO_CRC(*p++);
-			b = (void *)p;
+			u8 *_p = (u8 *)b;
+			DO_CRC(*_p++);
+			b = (void *)_p;
 		} while (--len);
 	}
 
@@ -183,9 +183,9 @@ u32 __pure crc32_be(u32 crc, unsigned char const *p,
size_t len)
 	/* Align it */
 	if(unlikely(((long)b)&3 && len)){
 		do {
-			u8 *p = (u8 *)b;
-			DO_CRC(*p++);
-			b = (u32 *)p;
+			u8 *_p = (u8 *)b;
+			DO_CRC(*_p++);
+			b = (u32 *)_p;
 		} while ((--len) && ((long)b)&3 );
 	}
 	if(likely(len >= 4)){
@@ -206,9 +206,9 @@ u32 __pure crc32_be(u32 crc, unsigned char const *p,
size_t len)
 	/* And the last few bytes */
 	if(len){
 		do {
-			u8 *p = (u8 *)b;
-			DO_CRC(*p++);
-			b = (void *)p;
+			u8 *_p = (u8 *)b;
+			DO_CRC(*_p++);
+			b = (void *)_p;
 		} while (--len);
 	}
 	return __be32_to_cpu(crc);
@@ -346,7 +346,7 @@ EXPORT_SYMBOL(crc32_be);
  * in the correct multiple to subtract, we can shift a byte at a time.
  * This produces a 40-bit (rather than a 33-bit) intermediate
remainder,
  * but again the multiple of the polynomial to subtract depends only on
- * the high bits, the high 8 bits in this case.  
+ * the high bits, the high 8 bits in this case.
  *
  * The multiple we need in that case is the low 32 bits of a 40-bit
  * value whose high 8 bits are given, and which is a multiple of the 
--
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