lkml.org 
[lkml]   [2005]   [Mar]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH] rol/ror type cleanup
On Thu, Mar 10, 2005 at 10:33:29AM +0100, Geert Uytterhoeven wrote:
> `unsigned int', while we're at it?

Minor type cleanup.

Signed-off-by: Matt Mackall <mpm@selenic.com>

Index: bk/include/linux/bitops.h
===================================================================
--- bk.orig/include/linux/bitops.h 2005-03-10 13:52:49.000000000 -0800
+++ bk/include/linux/bitops.h 2005-03-10 13:59:51.000000000 -0800
@@ -140,7 +140,7 @@ static inline unsigned long hweight_long
* @word: value to rotate
* @shift: bits to roll
*/
-static inline __u32 rol32(__u32 word, int shift)
+static inline __u32 rol32(__u32 word, unsigned int shift)
{
return (word << shift) | (word >> (32 - shift));
}
@@ -151,7 +151,7 @@ static inline __u32 rol32(__u32 word, in
* @word: value to rotate
* @shift: bits to roll
*/
-static inline __u32 ror32(__u32 word, int shift)
+static inline __u32 ror32(__u32 word, unsigned int shift)
{
return (word >> shift) | (word << (32 - shift));
}
--
Mathematics is the supreme nostalgia of our time.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 14:11    [W:0.038 / U:0.044 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site