aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorIshai Rabinovitz <ishai@mellanox.co.il>2006-01-12 18:24:51 -0500
committerRoland Dreier <rolandd@cisco.com>2006-01-12 18:24:51 -0500
commit59f174faffd5dfee709fa0ead320cc6daf827e93 (patch)
treea0d6503074dd97e808cb98fc4779c40e3cbf6fef /drivers
parent988bd50300ef2e2d5cb8563e2ac99453dd9acd86 (diff)
IB/mthca: Fix memory leak of multicast group structures
Convert "/ (1 << lg)" to ">> lg" for a slight code size reduction. add/remove: 0/0 grow/shrink: 0/1 up/down: 0/-24 (-24) function old new delta mthca_map_cmd 613 589 -24 Signed-off-by: Ishai Rabinovitz <ishai@mellanox.co.il> Signed-off-by: Michael S. Tsirkin <mst@mellanox.co.il> Signed-off-by: Roland Dreier <rolandd@cisco.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/infiniband/hw/mthca/mthca_cmd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/infiniband/hw/mthca/mthca_cmd.c b/drivers/infiniband/hw/mthca/mthca_cmd.c
index 22ac72bc20c3..f69e4896eff0 100644
--- a/drivers/infiniband/hw/mthca/mthca_cmd.c
+++ b/drivers/infiniband/hw/mthca/mthca_cmd.c
@@ -606,7 +606,7 @@ static int mthca_map_cmd(struct mthca_dev *dev, u16 op, struct mthca_icm *icm,
606 err = -EINVAL; 606 err = -EINVAL;
607 goto out; 607 goto out;
608 } 608 }
609 for (i = 0; i < mthca_icm_size(&iter) / (1 << lg); ++i) { 609 for (i = 0; i < mthca_icm_size(&iter) >> lg; ++i) {
610 if (virt != -1) { 610 if (virt != -1) {
611 pages[nent * 2] = cpu_to_be64(virt); 611 pages[nent * 2] = cpu_to_be64(virt);
612 virt += 1 << lg; 612 virt += 1 << lg;