mirror of
https://github.com/torvalds/linux.git
synced 2026-11-07 06:17:02 +01:00
Merge branch 'net-broadcom-couple-of-minor-changes'
Florian Fainelli says: ==================== net: broadcom: Couple of minor changes The first change makes sure there is proper reference counting handling in case of error/removal for the bcmsysport driver. The second change removes duplicates definitions in the ASP2 driver. ==================== Link: https://patch.msgid.link/20260922222525.3992167-1-florian.fainelli@broadcom.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
commit
5fe4271d62
|
|
@ -80,11 +80,6 @@
|
|||
#define ASP_RX_FILTER_MDA_PAT_L(sel) (((sel) * 0x14) + 0x108)
|
||||
#define ASP_RX_FILTER_MDA_MSK_H(sel) (((sel) * 0x14) + 0x10c)
|
||||
#define ASP_RX_FILTER_MDA_MSK_L(sel) (((sel) * 0x14) + 0x110)
|
||||
#define ASP_RX_FILTER_MDA_CFG(sel) (((sel) * 0x14) + 0x100)
|
||||
#define ASP_RX_FILTER_MDA_PAT_H(sel) (((sel) * 0x14) + 0x104)
|
||||
#define ASP_RX_FILTER_MDA_PAT_L(sel) (((sel) * 0x14) + 0x108)
|
||||
#define ASP_RX_FILTER_MDA_MSK_H(sel) (((sel) * 0x14) + 0x10c)
|
||||
#define ASP_RX_FILTER_MDA_MSK_L(sel) (((sel) * 0x14) + 0x110)
|
||||
#define ASP_RX_FILTER_NET_CFG(sel) (((sel) * 0xa04) + 0x400)
|
||||
#define ASP_RX_FILTER_NET_CFG_CH(sel) ((sel) << 0)
|
||||
#define ASP_RX_FILTER_NET_CFG_EN BIT(9)
|
||||
|
|
|
|||
|
|
@ -2522,17 +2522,19 @@ static int bcm_sysport_probe(struct platform_device *pdev)
|
|||
if (ret)
|
||||
priv->phy_interface = PHY_INTERFACE_MODE_GMII;
|
||||
|
||||
priv->phy_dn = of_parse_phandle(dn, "phy-handle", 0);
|
||||
|
||||
/* In the case of a fixed PHY, the DT node associated
|
||||
* to the PHY is the Ethernet MAC DT node.
|
||||
*/
|
||||
if (of_phy_is_fixed_link(dn)) {
|
||||
if (!priv->phy_dn && of_phy_is_fixed_link(dn)) {
|
||||
ret = of_phy_register_fixed_link(dn);
|
||||
if (ret) {
|
||||
dev_err(&pdev->dev, "failed to register fixed PHY\n");
|
||||
goto err_free_netdev;
|
||||
}
|
||||
|
||||
priv->phy_dn = dn;
|
||||
priv->phy_dn = of_node_get(dn);
|
||||
}
|
||||
|
||||
/* Initialize netdevice members */
|
||||
|
|
@ -2617,6 +2619,7 @@ static int bcm_sysport_probe(struct platform_device *pdev)
|
|||
err_deregister_fixed_link:
|
||||
if (of_phy_is_fixed_link(dn))
|
||||
of_phy_deregister_fixed_link(dn);
|
||||
of_node_put(priv->phy_dn);
|
||||
err_free_netdev:
|
||||
free_netdev(dev);
|
||||
return ret;
|
||||
|
|
@ -2635,6 +2638,7 @@ static void bcm_sysport_remove(struct platform_device *pdev)
|
|||
unregister_netdev(dev);
|
||||
if (of_phy_is_fixed_link(dn))
|
||||
of_phy_deregister_fixed_link(dn);
|
||||
of_node_put(priv->phy_dn);
|
||||
free_netdev(dev);
|
||||
dev_set_drvdata(&pdev->dev, NULL);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user