Commit dabbd6ab authored by Zhang Changzhong's avatar Zhang Changzhong Committed by Jason Gunthorpe

IB/hfi1: Fix error return code in hfi1_init_dd()

Fix to return a negative error code from the error handling case instead
of 0, as done elsewhere in this function.

Fixes: 4730f4a6 ("IB/hfi1: Activate the dummy netdev")
Link: https://lore.kernel.org/r/1605249747-17942-1-git-send-email-zhangchangzhong@huawei.comReported-by: default avatarHulk Robot <hulkci@huawei.com>
Signed-off-by: default avatarZhang Changzhong <zhangchangzhong@huawei.com>
Acked-by: default avatarMike Marciniszyn <mike.marciniszyn@cornelisnetworks.com>
Signed-off-by: default avatarJason Gunthorpe <jgg@nvidia.com>
parent b1e678bf
...@@ -15245,7 +15245,8 @@ int hfi1_init_dd(struct hfi1_devdata *dd) ...@@ -15245,7 +15245,8 @@ int hfi1_init_dd(struct hfi1_devdata *dd)
& CCE_REVISION_SW_MASK); & CCE_REVISION_SW_MASK);
/* alloc netdev data */ /* alloc netdev data */
if (hfi1_netdev_alloc(dd)) ret = hfi1_netdev_alloc(dd);
if (ret)
goto bail_cleanup; goto bail_cleanup;
ret = set_up_context_variables(dd); ret = set_up_context_variables(dd);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment