Patchwork [3/6] bitops: change BITS_TO_LONGS

login
register
mail settings
Submitter liguang
Date Feb. 4, 2013, 2:27 a.m.
Message ID <1359944880-6039-4-git-send-email-lig.fnst@cn.fujitsu.com>
Download mbox | patch
Permalink /patch/217815/
State New
Headers show

Comments

liguang - Feb. 4, 2013, 2:27 a.m.
Signed-off-by: liguang <lig.fnst@cn.fujitsu.com>
---
 include/qemu/bitops.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

Patch

diff --git a/include/qemu/bitops.h b/include/qemu/bitops.h
index 74e14e5..7758792 100644
--- a/include/qemu/bitops.h
+++ b/include/qemu/bitops.h
@@ -20,7 +20,7 @@ 
 #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_BYTE * sizeof(long))
+#define BITS_TO_LONGS(nr)	DIV_ROUND_UP(nr, BITS_PER_LONG)
 
 /**
  * bitops_ffs - find first bit in word.