Skip to content

Commit c6092ea

Browse files
zhengchaoshaokuba-moo
authored andcommitted
cxgb4vf: shut down the adapter when t4vf_update_port_info() failed in cxgb4vf_open()
When t4vf_update_port_info() failed in cxgb4vf_open(), resources applied during adapter goes up are not cleared. Fix it. Only be compiled, not be tested. Fixes: 18d79f7 ("cxgb4vf: Update port information in cxgb4vf_open()") Signed-off-by: Zhengchao Shao <shaozhengchao@huawei.com> Link: https://lore.kernel.org/r/20221109012100.99132-1-shaozhengchao@huawei.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
1 parent d407205 commit c6092ea

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/net/ethernet/chelsio/cxgb4vf/cxgb4vf_main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -858,7 +858,7 @@ static int cxgb4vf_open(struct net_device *dev)
858858
*/
859859
err = t4vf_update_port_info(pi);
860860
if (err < 0)
861-
return err;
861+
goto err_unwind;
862862

863863
/*
864864
* Note that this interface is up and start everything up ...

0 commit comments

Comments
 (0)