]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - include/linux/bitops.h
ipg: fix Tx completion irq request
[linux-2.6-omap-h63xx.git] / include / linux / bitops.h
index b9fb8ee3308bd6b2b4699194d47e2a6ecfeb7144..69c1edb9fe54a345f061cf983fe8311805c83154 100644 (file)
@@ -2,6 +2,14 @@
 #define _LINUX_BITOPS_H
 #include <asm/types.h>
 
+#ifdef __KERNEL__
+#define BIT(nr)                        (1UL << (nr))
+#define BIT_MASK(nr)           (1UL << ((nr) % BITS_PER_LONG))
+#define BIT_WORD(nr)           ((nr) / BITS_PER_LONG)
+#define BITS_TO_LONGS(nr)      DIV_ROUND_UP(nr, BITS_PER_LONG)
+#define BITS_PER_BYTE          8
+#endif
+
 /*
  * Include this here because some architectures need generic_ffs/fls in
  * scope