From 836508b8af09e50cadcbecc3cdc92126684f99bf Mon Sep 17 00:00:00 2001 From: leonidk Date: Wed, 5 Apr 2006 10:14:49 +0000 Subject: [PATCH] [MTHCA] bugfix: CQ ring buffer size must be PAGE_SIZE aligned git-svn-id: svn://openib.tc.cornell.edu/gen1@286 ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86 --- trunk/hw/mthca/kernel/mthca_cq.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/trunk/hw/mthca/kernel/mthca_cq.c b/trunk/hw/mthca/kernel/mthca_cq.c index e3753e4e..a3805308 100644 --- a/trunk/hw/mthca/kernel/mthca_cq.c +++ b/trunk/hw/mthca/kernel/mthca_cq.c @@ -733,7 +733,7 @@ int mthca_init_cq(struct mthca_dev *dev, int nent, struct mthca_ucontext *ctx, u32 pdn, struct mthca_cq *cq) { - int size = nent * MTHCA_CQ_ENTRY_SIZE; + int size = NEXT_PAGE_ALIGN(nent * MTHCA_CQ_ENTRY_SIZE ); struct mthca_mailbox *mailbox; struct mthca_cq_context *cq_context; int err = -ENOMEM; -- 2.41.0