mirror of
git://git.openwrt.org/openwrt/openwrt.git
synced 2025-01-24 15:43:09 +00:00
fix MII register ioremap on when high cpmac is available, patch from Wipster
SVN-Revision: 25730
This commit is contained in:
parent
c3f3c60730
commit
f198979add
@ -190,7 +190,7 @@
|
|||||||
|
|
||||||
cpmac_mii->reset(cpmac_mii);
|
cpmac_mii->reset(cpmac_mii);
|
||||||
|
|
||||||
@@ -1269,10 +1256,20 @@ int __devinit cpmac_init(void)
|
@@ -1269,10 +1256,22 @@ int __devinit cpmac_init(void)
|
||||||
msleep(10);
|
msleep(10);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -199,6 +199,7 @@
|
|||||||
if (mask & (mask - 1)) {
|
if (mask & (mask - 1)) {
|
||||||
- external_switch = 1;
|
- external_switch = 1;
|
||||||
- mask = 0;
|
- mask = 0;
|
||||||
|
+ if (!ar7_has_high_cpmac()) {
|
||||||
+ if (ar7_is_titan()) {
|
+ if (ar7_is_titan()) {
|
||||||
+ ar7_device_disable(AR7_RESET_BIT_EPHY);
|
+ ar7_device_disable(AR7_RESET_BIT_EPHY);
|
||||||
+ ar7_device_disable(TITAN_RESET_BIT_EPHY1);
|
+ ar7_device_disable(TITAN_RESET_BIT_EPHY1);
|
||||||
@ -210,6 +211,7 @@
|
|||||||
+ if (mii_reg) {
|
+ if (mii_reg) {
|
||||||
+ writel(readl(mii_reg) | 1, mii_reg);
|
+ writel(readl(mii_reg) | 1, mii_reg);
|
||||||
+ iounmap(mii_reg);
|
+ iounmap(mii_reg);
|
||||||
|
+ }
|
||||||
+ }
|
+ }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user