Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 88491
b: refs/heads/master
c: c263ff6
h: refs/heads/master
i:
  88489: f1ca7f2
  88487: bc28ba5
v: v3
  • Loading branch information
Roland Dreier committed Apr 17, 2008
1 parent ffdc953 commit 87a5b9c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 19773539d6369c54fbb0c870de0c75417b0020d1
refs/heads/master: c263ff65d5936113cfcbb8139d34122361e2306e
4 changes: 3 additions & 1 deletion trunk/drivers/infiniband/hw/mthca/mthca_memfree.c
Original file line number Diff line number Diff line change
Expand Up @@ -359,12 +359,14 @@ struct mthca_icm_table *mthca_alloc_icm_table(struct mthca_dev *dev,
int use_lowmem, int use_coherent)
{
struct mthca_icm_table *table;
int obj_per_chunk;
int num_icm;
unsigned chunk_size;
int i;
u8 status;

num_icm = (obj_size * nobj + MTHCA_TABLE_CHUNK_SIZE - 1) / MTHCA_TABLE_CHUNK_SIZE;
obj_per_chunk = MTHCA_TABLE_CHUNK_SIZE / obj_size;
num_icm = DIV_ROUND_UP(nobj, obj_per_chunk);

table = kmalloc(sizeof *table + num_icm * sizeof *table->icm, GFP_KERNEL);
if (!table)
Expand Down

0 comments on commit 87a5b9c

Please sign in to comment.