diff options
author | Zhu Yanjun <yanjun.zhu@oracle.com> | 2017-03-13 06:43:46 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-03-14 07:20:05 +0100 |
commit | ea69c883644a5c574ab518ae86ca3ce58e101072 (patch) | |
tree | 68aba325db8e934e059c42055f57b24bfff8dba9 | |
parent | rds: ib: drop unnecessary rdma_reject (diff) | |
download | linux-ea69c883644a5c574ab518ae86ca3ce58e101072.tar.xz 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>
-rw-r--r-- | net/rds/ib_fmr.c | 7 |
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); } |