Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 14477
b: refs/heads/master
c: 48fd0d1
h: refs/heads/master
i:
  14475: cbd2aa7
v: v3
  • Loading branch information
Michael S. Tsirkin authored and Roland Dreier committed Nov 18, 2005
1 parent b5538b4 commit 2ae8a99
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 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: cbc5b2bb9e226c2b2b981836d2289912e2ef3c1c
refs/heads/master: 48fd0d1fdd357caa2de8cb4ce6af810df7535f43
10 changes: 6 additions & 4 deletions trunk/drivers/infiniband/hw/mthca/mthca_qp.c
Original file line number Diff line number Diff line change
Expand Up @@ -918,10 +918,12 @@ static void mthca_adjust_qp_caps(struct mthca_dev *dev,
else
qp->max_inline_data = max_data_size - MTHCA_INLINE_HEADER_SIZE;

qp->sq.max_gs = max_data_size / sizeof (struct mthca_data_seg);
qp->rq.max_gs = (min(dev->limits.max_desc_sz, 1 << qp->rq.wqe_shift) -
sizeof (struct mthca_next_seg)) /
sizeof (struct mthca_data_seg);
qp->sq.max_gs = min_t(int, dev->limits.max_sg,
max_data_size / sizeof (struct mthca_data_seg));
qp->rq.max_gs = min_t(int, dev->limits.max_sg,
(min(dev->limits.max_desc_sz, 1 << qp->rq.wqe_shift) -
sizeof (struct mthca_next_seg)) /
sizeof (struct mthca_data_seg));
}

/*
Expand Down

0 comments on commit 2ae8a99

Please sign in to comment.