summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArtur Grabowski <art@cvs.openbsd.org>2007-05-04 12:12:54 +0000
committerArtur Grabowski <art@cvs.openbsd.org>2007-05-04 12:12:54 +0000
commitaf385469be71a145b510fe319974932c29c7de8c (patch)
treed328210f41b716fecf4242aaacc06f1aac96ccef
parent00f1e713de2e81f9f9a5d9d606594c848407dfae (diff)
Initialize the sis_timeout early in attach instead of sis_init.
Sometimes we can can call timeout_del on it before we call sis_init. From mickey. art@ ok.
-rw-r--r--sys/dev/pci/if_sis.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/dev/pci/if_sis.c b/sys/dev/pci/if_sis.c
index 5d88b3bf566..99230029dc9 100644
--- a/sys/dev/pci/if_sis.c
+++ b/sys/dev/pci/if_sis.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_sis.c,v 1.76 2006/12/03 16:23:41 grange Exp $ */
+/* $OpenBSD: if_sis.c,v 1.77 2007/05/04 12:12:53 art Exp $ */
/*
* Copyright (c) 1997, 1998, 1999
* Bill Paul <wpaul@ctr.columbia.edu>. All rights reserved.
@@ -1132,6 +1132,8 @@ sis_attach(struct device *parent, struct device *self, void *aux)
goto fail_2;
}
+ timeout_set(&sc->sis_timeout, sis_tick, sc);
+
ifp = &sc->arpcom.ac_if;
ifp->if_softc = sc;
ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST;
@@ -1841,7 +1843,6 @@ sis_init(void *xsc)
splx(s);
- timeout_set(&sc->sis_timeout, sis_tick, sc);
timeout_add(&sc->sis_timeout, hz);
}