Skip to content

Commit

Permalink
pcnet_cs: fix mii init code for older DL10019 based cards
Browse files Browse the repository at this point in the history
Some older DL10019 based cards need to setup
the auto-negotiation-advertisement register
to advertise 100Full,100Half,10Full and 10Half.

Signed-off-by: <komurojun-mbn@nifty.com>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
  • Loading branch information
Komuro authored and Jeff Garzik committed Oct 28, 2005
1 parent 82702d3 commit d89a64b
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions drivers/net/pcmcia/pcnet_cs.c
Original file line number Diff line number Diff line change
Expand Up @@ -1020,6 +1020,12 @@ static void set_misc_reg(struct net_device *dev)
} else {
outb(full_duplex ? 4 : 0, nic_base + DLINK_DIAG);
}
} else if (info->flags & IS_DL10019) {
/* Advertise 100F, 100H, 10F, 10H */
mdio_write(nic_base + DLINK_GPIO, info->eth_phy, 4, 0x01e1);
/* Restart MII autonegotiation */
mdio_write(nic_base + DLINK_GPIO, info->eth_phy, 0, 0x0000);
mdio_write(nic_base + DLINK_GPIO, info->eth_phy, 0, 0x1200);
}
}

Expand Down

0 comments on commit d89a64b

Please sign in to comment.