diff options
author | James Bottomley <jejb@mulgrave.il.steeleye.com> | 2006-03-21 20:05:45 +0100 |
---|---|---|
committer | James Bottomley <jejb@mulgrave.il.steeleye.com> | 2006-03-21 20:05:45 +0100 |
commit | d04cdb64212eb5ae6a98026a97dda626e40e8e9a (patch) | |
tree | b6a7dbb21ccfceb915844e9a330b3d3dfcaf3c5b /drivers/infiniband/hw/mthca/mthca_memfree.h | |
parent | [SCSI] eliminate rphy allocation in favour of expander/end device allocation (diff) | |
parent | Merge master.kernel.org:/pub/scm/linux/kernel/git/herbert/crypto-2.6 (diff) | |
download | linux-d04cdb64212eb5ae6a98026a97dda626e40e8e9a.tar.xz linux-d04cdb64212eb5ae6a98026a97dda626e40e8e9a.zip |
Merge ../linux-2.6
Diffstat (limited to 'drivers/infiniband/hw/mthca/mthca_memfree.h')
-rw-r--r-- | drivers/infiniband/hw/mthca/mthca_memfree.h | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/drivers/infiniband/hw/mthca/mthca_memfree.h b/drivers/infiniband/hw/mthca/mthca_memfree.h index 36f1141a08aa..6d42947e1dc4 100644 --- a/drivers/infiniband/hw/mthca/mthca_memfree.h +++ b/drivers/infiniband/hw/mthca/mthca_memfree.h @@ -45,6 +45,12 @@ ((256 - sizeof (struct list_head) - 2 * sizeof (int)) / \ (sizeof (struct scatterlist))) +enum { + MTHCA_ICM_PAGE_SHIFT = 12, + MTHCA_ICM_PAGE_SIZE = 1 << MTHCA_ICM_PAGE_SHIFT, + MTHCA_DB_REC_PER_PAGE = MTHCA_ICM_PAGE_SIZE / 8 +}; + struct mthca_icm_chunk { struct list_head list; int npages; @@ -131,10 +137,6 @@ static inline unsigned long mthca_icm_size(struct mthca_icm_iter *iter) return sg_dma_len(&iter->chunk->mem[iter->page_idx]); } -enum { - MTHCA_DB_REC_PER_PAGE = 4096 / 8 -}; - struct mthca_db_page { DECLARE_BITMAP(used, MTHCA_DB_REC_PER_PAGE); __be64 *db_rec; |