summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorAndy Fleming <afleming@freescale.com>2011-05-18 13:44:19 +0000
committerWolfgang Denk <wd@denx.de>2011-07-27 23:21:25 +0200
commitee8fa20f54c9705218a5c21e7db7d4ba1c124b98 (patch)
tree810fe1fa28cc878ce6315fbb6849d649057b8be4 /include/linux
parent09e3a67dec72b85dfc5535d2dbe695e9b2bfc4f9 (diff)
downloadu-boot-imx-ee8fa20f54c9705218a5c21e7db7d4ba1c124b98.zip
u-boot-imx-ee8fa20f54c9705218a5c21e7db7d4ba1c124b98.tar.gz
u-boot-imx-ee8fa20f54c9705218a5c21e7db7d4ba1c124b98.tar.bz2
phylib: Detect link on 10G devices correctly
gen10g_startup() had 2 bugs: 1) It had a boolean logic error in checking the MMD mask, and always checked all of them. 2) It checked devices which don't actually report link state, which meant that it would never believe the link was fully up. Fix the boolean logic, and then mask the MMD mask so only link-reporting devices are checked. Signed-off-by: Andy Fleming <afleming@freescale.com> Reported-by: Ed Swarthout <Ed.Swarthout@freescale.com>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/mdio.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/linux/mdio.h b/include/linux/mdio.h
index 022d772..be80f91 100644
--- a/include/linux/mdio.h
+++ b/include/linux/mdio.h
@@ -120,6 +120,14 @@
#define MDIO_DEVS_VEND1 MDIO_DEVS_PRESENT(MDIO_MMD_VEND1)
#define MDIO_DEVS_VEND2 MDIO_DEVS_PRESENT(MDIO_MMD_VEND2)
+#define MDIO_DEVS_LINK (MDIO_DEVS_PMAPMD | \
+ MDIO_DEVS_WIS | \
+ MDIO_DEVS_PCS | \
+ MDIO_DEVS_PHYXS | \
+ MDIO_DEVS_DTEXS | \
+ MDIO_DEVS_AN)
+
+
/* Control register 2. */
#define MDIO_PMA_CTRL2_TYPE 0x000f /* PMA/PMD type selection */