Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 73469
b: refs/heads/master
c: a6baf3a
h: refs/heads/master
i:
  73467: abe5c8c
v: v3
  • Loading branch information
Francois Romieu authored and Jeff Garzik committed Nov 10, 2007
1 parent c369b17 commit 74db5ed
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 50d84c2dc00e48ff9ba018ed0dd23276cf79e566
refs/heads/master: a6baf3af89a266a3d745117de570788b956396e7
6 changes: 3 additions & 3 deletions trunk/drivers/net/r8169.c
Original file line number Diff line number Diff line change
Expand Up @@ -470,7 +470,7 @@ static void mdio_write(void __iomem *ioaddr, int reg_addr, int value)
{
int i;

RTL_W32(PHYAR, 0x80000000 | (reg_addr & 0xFF) << 16 | value);
RTL_W32(PHYAR, 0x80000000 | (reg_addr & 0x1f) << 16 | (value & 0xffff));

for (i = 20; i > 0; i--) {
/*
Expand All @@ -487,15 +487,15 @@ static int mdio_read(void __iomem *ioaddr, int reg_addr)
{
int i, value = -1;

RTL_W32(PHYAR, 0x0 | (reg_addr & 0xFF) << 16);
RTL_W32(PHYAR, 0x0 | (reg_addr & 0x1f) << 16);

for (i = 20; i > 0; i--) {
/*
* Check if the RTL8169 has completed retrieving data from
* the specified MII register.
*/
if (RTL_R32(PHYAR) & 0x80000000) {
value = (int) (RTL_R32(PHYAR) & 0xFFFF);
value = RTL_R32(PHYAR) & 0xffff;
break;
}
udelay(25);
Expand Down

0 comments on commit 74db5ed

Please sign in to comment.