projects
/
openwrt
/
staging
/
adrian.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cf99009
)
generic: ar8216: mdiodev: add qca,phy4-mii-enable option
author
Chuanhong Guo
<gch981213@gmail.com>
Thu, 10 Jan 2019 15:31:35 +0000
(23:31 +0800)
committer
Petr Štetiar
<ynezz@true.cz>
Sun, 24 Mar 2019 00:44:26 +0000
(
01:44
+0100)
This option allows setting phy4 as a phy connected directly to CPU.
Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
target/linux/generic/files/drivers/net/phy/ar8216.c
patch
|
blob
|
history
diff --git
a/target/linux/generic/files/drivers/net/phy/ar8216.c
b/target/linux/generic/files/drivers/net/phy/ar8216.c
index c6e3a05299017136241baa0c470122eb543ec732..f3cafc79a572ffd9b88c2724c7547221b35ace7a 100644
(file)
--- a/
target/linux/generic/files/drivers/net/phy/ar8216.c
+++ b/
target/linux/generic/files/drivers/net/phy/ar8216.c
@@
-2574,6
+2574,12
@@
ar8xxx_mdiodev_probe(struct mdio_device *mdiodev)
swdev = &priv->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);
if (ret)
goto free_priv;