diff options
author | Thomas Miletich <thomas.miletich@gmail.com> | 2009-09-05 11:23:55 +0200 |
---|---|---|
committer | Marty Connor <mdc@etherboot.org> | 2009-10-15 13:06:01 -0400 |
commit | 584e3782417051321d2537d71ac97aa29287cf1e (patch) | |
tree | 06dcd80b855eed568efc9329c090794799a17284 | |
parent | 1bb420448c9b3a96143b4600d8eb51fae80d143c (diff) | |
download | ipxe-584e3782417051321d2537d71ac97aa29287cf1e.tar.gz |
[3c90x] Fix a3c90x_close() and a3c90x_remove() methods.
Both methods disabled packet tx and rx just to have it enabled again
by calling a3c90x_reset().
Fixed by disabling tx and rx after the call to a3c90x_reset().
Tested by booting Ubuntu intrepid(8.10) directly from gPXE and pxelinux.
Tested on 3c905, 3c905B, 3c905C.
Signed-off-by: Marty Connor <mdc@etherboot.org>
-rw-r--r-- | src/drivers/net/3c90x.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/drivers/net/3c90x.c b/src/drivers/net/3c90x.c index aeed6332a..9c1879bb3 100644 --- a/src/drivers/net/3c90x.c +++ b/src/drivers/net/3c90x.c @@ -619,13 +619,13 @@ static void a3c90x_remove(struct pci_device *pci) DBGP("a3c90x_remove\n"); - unregister_netdev(netdev); + a3c90x_reset(inf_3c90x); /* Disable the receiver and transmitter. */ outw(cmdRxDisable, inf_3c90x->IOAddr + regCommandIntStatus_w); outw(cmdTxDisable, inf_3c90x->IOAddr + regCommandIntStatus_w); - a3c90x_reset(inf_3c90x); + unregister_netdev(netdev); netdev_nullify(netdev); netdev_put(netdev); } @@ -845,9 +845,9 @@ static void a3c90x_close(struct net_device *netdev) DBGP("a3c90x_close\n"); + a3c90x_reset(inf_3c90x); outw(cmdRxDisable, inf_3c90x->IOAddr + regCommandIntStatus_w); outw(cmdTxDisable, inf_3c90x->IOAddr + regCommandIntStatus_w); - a3c90x_reset(inf_3c90x); a3c90x_free_resources(inf_3c90x); } |