summaryrefslogtreecommitdiff
path: root/sys/dev/pci/if_vic.c
diff options
context:
space:
mode:
authorReyk Floeter <reyk@cvs.openbsd.org>2007-05-04 01:52:52 +0000
committerReyk Floeter <reyk@cvs.openbsd.org>2007-05-04 01:52:52 +0000
commitaf9c38d3cda06154a0cbd5dbfa54d94871c5bd39 (patch)
tree1255ad50ac1cc513693e4d84e342099bc094ccfc /sys/dev/pci/if_vic.c
parent6b47695f7b189530c458e64259f5d45043c309e8 (diff)
do not call vic_init() on ENETRESET in the ioctl handler, use
vic_iff() instead. vic_init() calls vic_init_data() which sets up the rings and allocates the dma maps. it could happen that vic_init() was called for multiple times without releasing them first by calling vic_uninit_data(). ouch! this may have caused some problems related to dmamap corruption but we'll do further investigation. ok dlg@
Diffstat (limited to 'sys/dev/pci/if_vic.c')
-rw-r--r--sys/dev/pci/if_vic.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/pci/if_vic.c b/sys/dev/pci/if_vic.c
index 80ae8f05634..99bfd7660df 100644
--- a/sys/dev/pci/if_vic.c
+++ b/sys/dev/pci/if_vic.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_vic.c,v 1.45 2007/04/22 13:17:55 dlg Exp $ */
+/* $OpenBSD: if_vic.c,v 1.46 2007/05/04 01:52:51 reyk Exp $ */
/*
* Copyright (c) 2006 Reyk Floeter <reyk@openbsd.org>
@@ -1184,7 +1184,7 @@ vic_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
if (error == ENETRESET) {
if ((ifp->if_flags & (IFF_UP | IFF_RUNNING)) ==
(IFF_UP | IFF_RUNNING))
- vic_init(ifp);
+ vic_iff(ifp);
error = 0;
}