Skip to content

Commit 0c754d9

Browse files
Dan Carpenterkuba-moo
authored andcommitted
net: bcmasp: Fix error code in probe()
Return an error code if bcmasp_interface_create() fails. Don't return success. Fixes: 490cb41 ("net: bcmasp: Add support for ASP2.0 Ethernet controller") Signed-off-by: Dan Carpenter <[email protected]> Reviewed-by: Michal Kubiak <[email protected]> Reviewed-by: Justin Chen <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
1 parent 0005b2d commit 0c754d9

File tree

1 file changed

+1
-0
lines changed
  • drivers/net/ethernet/broadcom/asp2

1 file changed

+1
-0
lines changed

drivers/net/ethernet/broadcom/asp2/bcmasp.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1380,6 +1380,7 @@ static int bcmasp_probe(struct platform_device *pdev)
13801380
dev_err(dev, "Cannot create eth interface %d\n", i);
13811381
bcmasp_remove_intfs(priv);
13821382
of_node_put(intf_node);
1383+
ret = -ENOMEM;
13831384
goto of_put_exit;
13841385
}
13851386
list_add_tail(&intf->list, &priv->intfs);

0 commit comments

Comments
 (0)