qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH v1 50/59] rdma/rdma_backend.c: remove unneeded label in rdma_back


From: Daniel Henrique Barboza
Subject: [PATCH v1 50/59] rdma/rdma_backend.c: remove unneeded label in rdma_backend_init()
Date: Mon, 6 Jan 2020 15:24:16 -0300

'out' label can be replaced by 'return -EIO' in the single
goto jump.

CC: Yuval Shaia <address@hidden>
CC: Marcel Apfelbaum <address@hidden>
Signed-off-by: Daniel Henrique Barboza <address@hidden>
---
 hw/rdma/rdma_backend.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/hw/rdma/rdma_backend.c b/hw/rdma/rdma_backend.c
index c346407cd3..20c4c9fc3a 100644
--- a/hw/rdma/rdma_backend.c
+++ b/hw/rdma/rdma_backend.c
@@ -1335,8 +1335,7 @@ int rdma_backend_init(RdmaBackendDev *backend_dev, 
PCIDevice *pdev,
     if (!backend_dev->context) {
         rdma_error_report("Failed to open IB device %s",
                           ibv_get_device_name(backend_dev->ib_dev));
-        ret = -EIO;
-        goto out;
+        return -EIO;
     }
 
     backend_dev->channel = ibv_create_comp_channel(backend_dev->context);
@@ -1377,7 +1376,6 @@ out_close_device:
 out_free_dev_list:
     ibv_free_device_list(dev_list);
 
-out:
     return ret;
 }
 
-- 
2.24.1




reply via email to

[Prev in Thread] Current Thread [Next in Thread]