[PATCH] staging/hv/osd: don't reimplement ALIGN macro

From: Uwe Kleine-KÃnig
Date: Tue Jan 18 2011 - 10:39:30 EST


Signed-off-by: Uwe Kleine-KÃnig <u.kleine-koenig@xxxxxxxxxxxxxx>
---
drivers/staging/hv/osd.h | 5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/staging/hv/osd.h b/drivers/staging/hv/osd.h
index ce064e8..61ae54c 100644
--- a/drivers/staging/hv/osd.h
+++ b/drivers/staging/hv/osd.h
@@ -28,10 +28,9 @@
#include <linux/workqueue.h>

/* Defines */
-#define ALIGN_UP(value, align) (((value) & (align-1)) ? \
- (((value) + (align-1)) & ~(align-1)) : \
- (value))
+#define ALIGN_UP(value, align) ALIGN((value), (align))
#define ALIGN_DOWN(value, align) ((value) & ~(align-1))
+
#define NUM_PAGES_SPANNED(addr, len) ((ALIGN_UP(addr+len, PAGE_SIZE) - \
ALIGN_DOWN(addr, PAGE_SIZE)) >> \
PAGE_SHIFT)
--
1.7.2.3

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/