summaryrefslogtreecommitdiffstats
path: root/net/rds
diff options
context:
space:
mode:
authorZhu Yanjun <yanjun.zhu@oracle.com>2017-03-13 01:43:46 -0400
committerDavid S. Miller <davem@davemloft.net>2017-03-13 23:20:05 -0700
commitea69c883644a5c574ab518ae86ca3ce58e101072 (patch)
tree68aba325db8e934e059c42055f57b24bfff8dba9 /net/rds
parentb418c5276a41c821c25410542df83d283bbc0b2a (diff)
downloadlinux-ea69c883644a5c574ab518ae86ca3ce58e101072.tar.gz
linux-ea69c883644a5c574ab518ae86ca3ce58e101072.tar.bz2
linux-ea69c883644a5c574ab518ae86ca3ce58e101072.zip
rds: ib: remove redundant ib_dealloc_fmr
The function ib_dealloc_fmr will never be called. As such, it should be removed. Cc: Joe Jin <joe.jin@oracle.com> Cc: Junxiao Bi <junxiao.bi@oracle.com> Reviewed-by: Yuval Shaia <yuval.shaia@oracle.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Acked-by: Santosh Shilimkar <santosh.shilimkar@oracle.com> Signed-off-by: Zhu Yanjun <yanjun.zhu@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/rds')
-rw-r--r--net/rds/ib_fmr.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/net/rds/ib_fmr.c b/net/rds/ib_fmr.c
index 4fe8f4fec4ee..249ae1c783cb 100644
--- a/net/rds/ib_fmr.c
+++ b/net/rds/ib_fmr.c
@@ -78,12 +78,9 @@ struct rds_ib_mr *rds_ib_alloc_fmr(struct rds_ib_device *rds_ibdev, int npages)
return ibmr;
out_no_cigar:
- if (ibmr) {
- if (fmr->fmr)
- ib_dealloc_fmr(fmr->fmr);
- kfree(ibmr);
- }
+ kfree(ibmr);
atomic_dec(&pool->item_count);
+
return ERR_PTR(err);
}