IB: Move the macro IB_UMEM_MAX_PAGE_CHUNK() to umem.c
authorDotan Barak <dotanb@dev.mellanox.co.il>
Wed, 1 Aug 2007 10:33:56 +0000 (13:33 +0300)
committerRoland Dreier <rolandd@cisco.com>
Fri, 3 Aug 2007 17:45:18 +0000 (10:45 -0700)
After moving the definition of struct ib_umem_chunk from ib_verbs.h to
ib_umem.h there isn't any reason for the macro IB_UMEM_MAX_PAGE_CHUNK
to stay in ib_verbs.h.  Move the macro to umem.c, the only place where
it is used.

Signed-off-by: Dotan Barak <dotanb@dev.mellanox.co.il>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
drivers/infiniband/core/umem.c
include/rdma/ib_verbs.h

index 26d0470eef6ec2c2a3abb706c821cc23437e26c1..664d2faa9e744b48aa6ce11e4c195ad18d2d66eb 100644 (file)
 
 #include "uverbs.h"
 
+#define IB_UMEM_MAX_PAGE_CHUNK                                         \
+       ((PAGE_SIZE - offsetof(struct ib_umem_chunk, page_list)) /      \
+        ((void *) &((struct ib_umem_chunk *) 0)->page_list[1] -        \
+         (void *) &((struct ib_umem_chunk *) 0)->page_list[0]))
+
 static void __ib_umem_release(struct ib_device *dev, struct ib_umem *umem, int dirty)
 {
        struct ib_umem_chunk *chunk, *tmp;
index 7a99f1125d24dbbcea811d9baa3c0906eb1d66da..4bea182d7116c4aa80e863ed2d5a59fed24967e0 100644 (file)
@@ -733,11 +733,6 @@ struct ib_udata {
        size_t       outlen;
 };
 
-#define IB_UMEM_MAX_PAGE_CHUNK                                         \
-       ((PAGE_SIZE - offsetof(struct ib_umem_chunk, page_list)) /      \
-        ((void *) &((struct ib_umem_chunk *) 0)->page_list[1] -        \
-         (void *) &((struct ib_umem_chunk *) 0)->page_list[0]))
-
 struct ib_pd {
        struct ib_device       *device;
        struct ib_uobject      *uobject;