aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband
diff options
context:
space:
mode:
authorDotan Barak <dotanb@dev.mellanox.co.il>2007-08-01 06:33:56 -0400
committerRoland Dreier <rolandd@cisco.com>2007-08-03 13:45:18 -0400
commit92ddc447ce7382e36b72a240697c00bf4beb8d75 (patch)
tree0368be72cdeed0d9d90e35d1a77bea50fb3208f0 /drivers/infiniband
parentbfb3ea125174813cdf87b1120caf0c9bd580283e (diff)
IB: Move the macro IB_UMEM_MAX_PAGE_CHUNK() to umem.c
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>
Diffstat (limited to 'drivers/infiniband')
-rw-r--r--drivers/infiniband/core/umem.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/infiniband/core/umem.c b/drivers/infiniband/core/umem.c
index 26d0470eef6e..664d2faa9e74 100644
--- a/drivers/infiniband/core/umem.c
+++ b/drivers/infiniband/core/umem.c
@@ -40,6 +40,11 @@
40 40
41#include "uverbs.h" 41#include "uverbs.h"
42 42
43#define IB_UMEM_MAX_PAGE_CHUNK \
44 ((PAGE_SIZE - offsetof(struct ib_umem_chunk, page_list)) / \
45 ((void *) &((struct ib_umem_chunk *) 0)->page_list[1] - \
46 (void *) &((struct ib_umem_chunk *) 0)->page_list[0]))
47
43static void __ib_umem_release(struct ib_device *dev, struct ib_umem *umem, int dirty) 48static void __ib_umem_release(struct ib_device *dev, struct ib_umem *umem, int dirty)
44{ 49{
45 struct ib_umem_chunk *chunk, *tmp; 50 struct ib_umem_chunk *chunk, *tmp;