OSDN Git Service

RDMA/core: Remove the redundant return statements
authorWenpeng Liang <liangwenpeng@huawei.com>
Wed, 7 Apr 2021 08:15:48 +0000 (16:15 +0800)
committerJason Gunthorpe <jgg@nvidia.com>
Mon, 12 Apr 2021 17:52:22 +0000 (14:52 -0300)
The return statements at the end of a void function is meaningless.

Link: https://lore.kernel.org/r/1617783353-48249-3-git-send-email-liweihang@huawei.com
Signed-off-by: Wenpeng Liang <liangwenpeng@huawei.com>
Signed-off-by: Weihang Li <liweihang@huawei.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
drivers/infiniband/core/mad.c
drivers/infiniband/core/sysfs.c

index ce0397f..16ecb81 100644 (file)
@@ -1860,8 +1860,6 @@ static void ib_mad_complete_recv(struct ib_mad_agent_private *mad_agent_priv,
                                                   mad_recv_wc);
                deref_mad_agent(mad_agent_priv);
        }
-
-       return;
 }
 
 static enum smi_action handle_ib_smi(const struct ib_mad_port_private *port_priv,
index 91a53b2..dcff5e7 100644 (file)
@@ -1049,7 +1049,6 @@ err_free_hsag:
        kfree(hsag);
 err_free_stats:
        kfree(stats);
-       return;
 }
 
 static int add_port(struct ib_core_device *coredev, int port_num)