aboutsummaryrefslogtreecommitdiffstats
path: root/target
diff options
context:
space:
mode:
authorHauke Mehrtens <hauke@openwrt.org>2013-01-07 22:51:39 +0000
committerHauke Mehrtens <hauke@openwrt.org>2013-01-07 22:51:39 +0000
commit3720f45e3cf20e62fb57ac3f838d7b28a3e56db5 (patch)
tree63b150216c3b7109991a3f83ac3330fb8bc7fe20 /target
parentd9f9ef4ef9dbfd72f20ffa25fcd00956a1e8683a (diff)
downloadupstream-3720f45e3cf20e62fb57ac3f838d7b28a3e56db5.tar.gz
upstream-3720f45e3cf20e62fb57ac3f838d7b28a3e56db5.tar.bz2
upstream-3720f45e3cf20e62fb57ac3f838d7b28a3e56db5.zip
brcm47xx: BGMAC Driver corrections
1) Fix what appears to be a logic error in bgmac_phy_advertise. 2) Fix bgmac_ioctl to use passed phy_id; needed for switch-robo interface w/ the driver to work correctly. I still have the issue with the interface always being HD when the speed/duplex is set manually (e.g., echo "100FD" > /proc/switch/eth0/port/N/media). Signed-off-by: Nathan Hintz <nlhintz@hotmail.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@35052 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target')
-rw-r--r--target/linux/brcm47xx/patches-3.6/750-bgmac.patch6
1 files changed, 3 insertions, 3 deletions
diff --git a/target/linux/brcm47xx/patches-3.6/750-bgmac.patch b/target/linux/brcm47xx/patches-3.6/750-bgmac.patch
index 13698dbf74..7668ad38b7 100644
--- a/target/linux/brcm47xx/patches-3.6/750-bgmac.patch
+++ b/target/linux/brcm47xx/patches-3.6/750-bgmac.patch
@@ -608,7 +608,7 @@
+ if (bgmac->phyaddr == BGMAC_PHY_NOREGS)
+ return;
+
-+ if (bgmac->autoneg)
++ if (!bgmac->autoneg)
+ return;
+
+ /* Adv selected 10/100 speeds */
@@ -1097,13 +1097,13 @@
+ case SIOCGMIIREG:
+ if (!netif_running(net_dev))
+ return -EAGAIN;
-+ data->val_out = bgmac_phy_read(bgmac, bgmac->phyaddr,
++ data->val_out = bgmac_phy_read(bgmac, data->phy_id,
+ data->reg_num & 0x1f);
+ return 0;
+ case SIOCSMIIREG:
+ if (!netif_running(net_dev))
+ return -EAGAIN;
-+ bgmac_phy_write(bgmac, bgmac->phyaddr, data->reg_num & 0x1f,
++ bgmac_phy_write(bgmac, data->phy_id, data->reg_num & 0x1f,
+ data->val_in);
+ return 0;
+ default: