From: oulijun Date: Fri, 4 May 2018 02:57:07 +0000 (+0800) Subject: RDMA/hns: Add return operation when configured global param fail X-Git-Tag: Ubuntu-4.15.0-24.26~129 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=3930418bc5b641886d03b492623456c48dfdc9cb;p=mirror_ubuntu-bionic-kernel.git RDMA/hns: Add return operation when configured global param fail BugLink: https://bugs.launchpad.net/bugs/1770974 When configure global param function run fail, it should directly return and the initial flow will stop. Signed-off-by: Lijun Ou Signed-off-by: Doug Ledford (cherry picked from commit 2349fdd483ea933b223f3eca53ed42835383d316) Signed-off-by: dann frazier Acked-by: Kleber Sacilotto de Souza Acked-by: Stefan Bader Signed-off-by: Khalid Elmously --- diff --git a/drivers/infiniband/hw/hns/hns_roce_hw_v2.c b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c index c604fb29bd64..82afc5b47a2a 100644 --- a/drivers/infiniband/hw/hns/hns_roce_hw_v2.c +++ b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c @@ -1085,6 +1085,7 @@ static int hns_roce_v2_profile(struct hns_roce_dev *hr_dev) if (ret) { dev_err(hr_dev->dev, "Configure global param fail, ret = %d.\n", ret); + return ret; } /* Get pf resource owned by every pf */