generic: ar8216: mdiodev: add qca,phy4-mii-enable option
This option allows setting phy4 as a phy connected directly to CPU. Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
This commit is contained in:
parent
cf9900978a
commit
ad8db1fa2e
@ -2574,6 +2574,12 @@ ar8xxx_mdiodev_probe(struct mdio_device *mdiodev)
|
|||||||
|
|
||||||
swdev = &priv->dev;
|
swdev = &priv->dev;
|
||||||
swdev->alias = dev_name(&mdiodev->dev);
|
swdev->alias = dev_name(&mdiodev->dev);
|
||||||
|
|
||||||
|
if (of_property_read_bool(priv->pdev->of_node, "qca,phy4-mii-enable")) {
|
||||||
|
priv->port4_phy = true;
|
||||||
|
swdev->ports--;
|
||||||
|
}
|
||||||
|
|
||||||
ret = register_switch(swdev, NULL);
|
ret = register_switch(swdev, NULL);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto free_priv;
|
goto free_priv;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user