summaryrefslogtreecommitdiff
path: root/os/pc/ether8139.c
diff options
context:
space:
mode:
authorCharles.Forsyth <devnull@localhost>2007-04-07 12:52:27 +0000
committerCharles.Forsyth <devnull@localhost>2007-04-07 12:52:27 +0000
commite1bd49a1e1823eab71c293efd1bd0c9b83c350c9 (patch)
treea9424cde16004cb9e591045225bc61beed339dd5 /os/pc/ether8139.c
parent15345f9c75c069d3e2e362af5d6f931eef7772ef (diff)
20070407-1350 more updates from plan 9 pc kernel, and a few unreachable fixes(!)
Diffstat (limited to 'os/pc/ether8139.c')
-rw-r--r--os/pc/ether8139.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/os/pc/ether8139.c b/os/pc/ether8139.c
index 12deba1b..dd3653e3 100644
--- a/os/pc/ether8139.c
+++ b/os/pc/ether8139.c
@@ -234,6 +234,12 @@ rtl8139promiscuous(void* arg, int on)
iunlock(&ctlr->ilock);
}
+static void
+rtl8139multicast(void* arg, uchar*, int)
+{
+ rtl8139promiscuous(arg, 1);
+}
+
static long
rtl8139ifstat(Ether* edev, void* a, long n, ulong offset)
{
@@ -637,8 +643,10 @@ rtl8139match(Ether* edev, int id)
}
ctlr->port = port;
- if(rtl8139reset(ctlr))
+ if(rtl8139reset(ctlr)) {
+ iofree(port);
continue;
+ }
pcisetbme(p);
ctlr->active = 1;
@@ -738,6 +746,8 @@ rtl8139pnp(Ether* edev)
edev->arg = edev;
edev->promiscuous = rtl8139promiscuous;
+ edev->multicast = rtl8139multicast;
+// edev->shutdown = rtl8139shutdown;
/*
* This should be much more dynamic but will do for now.