bitops operate on unsigned long

Message ID Pine.GSO.4.21.0207021303460.25055-100000@vervain.sonytel.be
State New, archived
Headers show
Series
  • bitops operate on unsigned long
Related show

Commit Message

Geert Uytterhoeven July 2, 2002, 11:05 a.m. UTC
Bitops must operate on unsigned long.


Gr{oetje,eeting}s,

						Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
							    -- Linus Torvalds

-
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/

Comments

Sam Ravnborg July 17, 2002, 7:18 p.m. UTC | #1
On Tue, Jul 02, 2002 at 01:05:01PM +0200, Geert Uytterhoeven wrote:
> 
> Bitops must operate on unsigned long.
> -u32 zorro_unused_z2ram[4] = { 0, 0, 0, 0 };
> +unsigned long zorro_unused_z2ram[128/BITS_PER_LONG];

Consider using bitmap_member from linux/types.h

	Sam
-
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/

Patch

--- linux-2.5.24/drivers/zorro/zorro.c	Mon May 13 10:55:35 2002
+++ linux-m68k-2.5.24/drivers/zorro/zorro.c	Tue Jul  2 12:59:34 2002
@@ -80,7 +80,7 @@ 
      *  FIXME: use the normal resource management
      */
 
-u32 zorro_unused_z2ram[4] = { 0, 0, 0, 0 };
+unsigned long zorro_unused_z2ram[128/BITS_PER_LONG];
 
 
 static void __init mark_region(unsigned long start, unsigned long end,
--- linux-2.5.24/include/linux/generic_serial.h	Mon Feb 11 13:14:29 2002
+++ linux-m68k-2.5.24/include/linux/generic_serial.h	Tue Jun 25 20:50:38 2002
@@ -45,7 +45,7 @@ 
   int                     count;
   int                     blocked_open;
   struct tty_struct       *tty;
-  int                     event;
+  unsigned long           event;
   unsigned short          closing_wait;
   int                     close_delay;
   struct real_driver      *rd;
--- linux-2.5.24/include/linux/serial167.h	Sun May 16 00:05:37 1999
+++ linux-m68k-2.5.24/include/linux/serial167.h	Tue Jun 25 20:50:38 2002
@@ -37,7 +37,7 @@ 
 	int			ignore_status_mask;
 	int			close_delay;
 	int			IER; 	/* Interrupt Enable Register */
-	int			event;
+	unsigned long		event;
 	unsigned long		last_active;
 	int			count;	/* # of fd on device */
 	int                     x_char; /* to be pushed out ASAP */
--- linux-2.5.24/include/linux/zorro.h	Mon May 13 10:55:40 2002
+++ linux-m68k-2.5.24/include/linux/zorro.h	Tue Jul  2 12:59:34 2002
@@ -199,7 +199,7 @@ 
      *  the corresponding bits.
      */
 
-extern __u32 zorro_unused_z2ram[4];
+extern unsigned long zorro_unused_z2ram[128/BITS_PER_LONG];
 
 #define Z2RAM_START		(0x00200000)
 #define Z2RAM_END		(0x00a00000)