From 54bbdca913a5e92ee8f25b948db1c2e97cea0070 Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Wed, 3 Jun 2015 19:47:10 -0600 Subject: [PATCH] LC17 Ethernet: Ignore 4-bit versin number when checking for PHY ID match --- arch/arm/src/lpc17xx/lpc17_ethernet.c | 8 +++++++- configs/lincoln60/netnsh/defconfig | 2 +- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/arch/arm/src/lpc17xx/lpc17_ethernet.c b/arch/arm/src/lpc17xx/lpc17_ethernet.c index 90a0e134889..3fa7028a788 100644 --- a/arch/arm/src/lpc17xx/lpc17_ethernet.c +++ b/arch/arm/src/lpc17xx/lpc17_ethernet.c @@ -2688,12 +2688,18 @@ static inline int lpc17_phyinit(struct lpc17_driver_s *priv) phyreg = (unsigned int)lpc17_phyread(phyaddr, MII_PHYID1); nvdbg("Addr: %d PHY ID1: %04x\n", phyaddr, phyreg); + /* Compare OUI bits 3-18 */ + if (phyreg == LPC17_PHYID1) { phyreg = lpc17_phyread(phyaddr, MII_PHYID2); nvdbg("Addr: %d PHY ID2: %04x\n", phyaddr, phyreg); - if (phyreg == LPC17_PHYID2) + /* Compare OUI bits 19-24 and the 6-bit model number (ignoring the + * 4-bit revision number). + */ + + if ((phyreg & 0xfff0) == LPC17_PHYID2) { break; } diff --git a/configs/lincoln60/netnsh/defconfig b/configs/lincoln60/netnsh/defconfig index 72e0ae482e9..a1d513cb9ff 100644 --- a/configs/lincoln60/netnsh/defconfig +++ b/configs/lincoln60/netnsh/defconfig @@ -255,7 +255,7 @@ CONFIG_BOARD_LOOPSPERMSEC=7982 # Interrupt options # CONFIG_ARCH_HAVE_INTERRUPTSTACK=y -CONFIG_ARCH_INTERRUPTSTACK=0 +CONFIG_ARCH_INTERRUPTSTACK=1536 CONFIG_ARCH_HAVE_HIPRI_INTERRUPT=y # CONFIG_ARCH_HIPRI_INTERRUPT is not set