aboutsummaryrefslogtreecommitdiff
path: root/sys/pci/if_rl.c
diff options
context:
space:
mode:
authorMike Smith <msmith@FreeBSD.org>1999-08-21 06:24:40 +0000
committerMike Smith <msmith@FreeBSD.org>1999-08-21 06:24:40 +0000
commitfcb893a801d281f10818fb4c88ed31215283a94e (patch)
treef4575d58021ad3c4d19c4d403050bb3dad3543da /sys/pci/if_rl.c
parent2a67fa4383b91146ae25b36cde91d05ffd7d5597 (diff)
downloadsrc-fcb893a801d281f10818fb4c88ed31215283a94e.tar.gz
src-fcb893a801d281f10818fb4c88ed31215283a94e.zip
Implement a new generic mechanism for attaching handler functions to
events, in order to pave the way for removing a number of the ad-hoc implementations currently in use. Retire the at_shutdown family of functions and replace them with new event handler lists. Rework kern_shutdown.c to take greater advantage of the use of event handlers. Reviewed by: green
Notes
Notes: svn path=/head/; revision=50107
Diffstat (limited to 'sys/pci/if_rl.c')
-rw-r--r--sys/pci/if_rl.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/sys/pci/if_rl.c b/sys/pci/if_rl.c
index c7935ffe4b3f..8fc7fbe2523e 100644
--- a/sys/pci/if_rl.c
+++ b/sys/pci/if_rl.c
@@ -29,7 +29,7 @@
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
* THE POSSIBILITY OF SUCH DAMAGE.
*
- * $Id: if_rl.c,v 1.19 1999/07/06 19:23:28 des Exp $
+ * $Id: if_rl.c,v 1.20 1999/07/22 20:56:49 wpaul Exp $
*/
/*
@@ -127,7 +127,7 @@
#ifndef lint
static const char rcsid[] =
- "$Id: if_rl.c,v 1.19 1999/07/06 19:23:28 des Exp $";
+ "$Id: if_rl.c,v 1.20 1999/07/22 20:56:49 wpaul Exp $";
#endif
/*
@@ -177,7 +177,7 @@ static int rl_ioctl __P((struct ifnet *, u_long, caddr_t));
static void rl_init __P((void *));
static void rl_stop __P((struct rl_softc *));
static void rl_watchdog __P((struct ifnet *));
-static void rl_shutdown __P((int, void *));
+static void rl_shutdown __P((void *, int));
static int rl_ifmedia_upd __P((struct ifnet *));
static void rl_ifmedia_sts __P((struct ifnet *, struct ifmediareq *));
@@ -1234,7 +1234,8 @@ rl_attach(config_id, unit)
#if NBPF > 0
bpfattach(ifp, DLT_EN10MB, sizeof(struct ether_header));
#endif
- at_shutdown(rl_shutdown, sc, SHUTDOWN_POST_SYNC);
+ EVENTHANDLER_REGISTER(shutdown_post_sync, rl_shutdown, sc,
+ SHUTDOWN_PRI_DEFAULT);
fail:
splx(s);
@@ -1925,9 +1926,9 @@ static void rl_stop(sc)
* Stop all chip I/O so that the kernel's probe routines don't
* get confused by errant DMAs when rebooting.
*/
-static void rl_shutdown(howto, arg)
- int howto;
+static void rl_shutdown(arg, howto)
void *arg;
+ int howto;
{
struct rl_softc *sc = (struct rl_softc *)arg;