aboutsummaryrefslogtreecommitdiff
path: root/drivers/net
diff options
context:
space:
mode:
authorRadu Pirea2019-06-07 14:18:36 +0300
committerJoe Hershberger2019-07-15 13:32:26 -0500
commit0dc97fc3d8cd8c4154f63c9ea74f5e73ee48fa6c (patch)
treecfaa2ad79b45f6c54a7ad4873722a232c41af661 /drivers/net
parent1b0c9914cc75d1570359181ebd493cd5746cb0ed (diff)
net: macb: Add support for 1000-baseX
Macb can be used with Xilinx PCS/PMA PHY in fpga which is a 1000-baseX phy(lpa 0x41e0). This patch adds checks for LPA_1000XFULL and LPA_1000XHALF bits. Signed-off-by: Radu Pirea <radu_nicolae.pirea@upb.ro> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/macb.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/net/macb.c b/drivers/net/macb.c
index ab831f40ee6..a7eddd647d0 100644
--- a/drivers/net/macb.c
+++ b/drivers/net/macb.c
@@ -615,8 +615,10 @@ static int macb_phy_init(struct macb_device *macb, const char *name)
if (gem_is_gigabit_capable(macb)) {
lpa = macb_mdio_read(macb, MII_LPA);
- if (lpa & (LPA_1000FULL | LPA_1000HALF)) {
- duplex = ((lpa & LPA_1000FULL) ? 1 : 0);
+ if (lpa & (LPA_1000FULL | LPA_1000HALF | LPA_1000XFULL |
+ LPA_1000XHALF)) {
+ duplex = ((lpa & (LPA_1000FULL | LPA_1000XFULL)) ?
+ 1 : 0);
printf("%s: link up, 1000Mbps %s-duplex (lpa: 0x%04x)\n",
name,