summaryrefslogtreecommitdiff
path: root/drivers/infiniband/hw/qib/qib_file_ops.c
diff options
context:
space:
mode:
authorHariprasad Kelam <hariprasad.kelam@gmail.com>2019-07-16 22:59:25 +0530
committerJason Gunthorpe <jgg@mellanox.com>2019-07-25 13:53:45 -0300
commit4cc315c53f959c5d71b96111a7d317f40771558e (patch)
treec9c982fce4c90367bc3466c498b70d0487b22bfc /drivers/infiniband/hw/qib/qib_file_ops.c
parent33db6f94847c33ebdeb2e73ef5cd8fd04fb58e86 (diff)
RDMA/qib: Unneeded variable ret
Fix the below warning reported by coccicheck: drivers/infiniband/hw/qib/qib_file_ops.c:1792:5-8: Unneeded variable: "ret". Return "0" on line 1876 Link: https://lore.kernel.org/r/20190716172924.GA12241@hari-Inspiron-1545 Signed-off-by: Hariprasad Kelam <hariprasad.kelam@gmail.com> Reviewed-by: Jason Gunthorpe <jgg@mellanox.com> Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
Diffstat (limited to 'drivers/infiniband/hw/qib/qib_file_ops.c')
-rw-r--r--drivers/infiniband/hw/qib/qib_file_ops.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/infiniband/hw/qib/qib_file_ops.c b/drivers/infiniband/hw/qib/qib_file_ops.c
index 27b6e664e59d..b0144229cf3b 100644
--- a/drivers/infiniband/hw/qib/qib_file_ops.c
+++ b/drivers/infiniband/hw/qib/qib_file_ops.c
@@ -1789,7 +1789,6 @@ static void unlock_expected_tids(struct qib_ctxtdata *rcd)
static int qib_close(struct inode *in, struct file *fp)
{
- int ret = 0;
struct qib_filedata *fd;
struct qib_ctxtdata *rcd;
struct qib_devdata *dd;
@@ -1873,7 +1872,7 @@ static int qib_close(struct inode *in, struct file *fp)
bail:
kfree(fd);
- return ret;
+ return 0;
}
static int qib_ctxt_info(struct file *fp, struct qib_ctxt_info __user *uinfo)