if_ti.c (167190) | if_ti.c (173839) |
---|---|
1/*- 2 * Copyright (c) 1997, 1998, 1999 3 * Bill Paul <wpaul@ctr.columbia.edu>. All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 63 unchanged lines hidden (view full) --- 72 * - Raymond Lee of Netgear, for providing a pair of Netgear 73 * GA620 Tigon 2 boards for testing 74 * - Ulf Zimmermann, for bringing the GA260 to my attention and 75 * convincing me to write this driver. 76 * - Andrew Gallatin for providing FreeBSD/Alpha support. 77 */ 78 79#include <sys/cdefs.h> | 1/*- 2 * Copyright (c) 1997, 1998, 1999 3 * Bill Paul <wpaul@ctr.columbia.edu>. All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 63 unchanged lines hidden (view full) --- 72 * - Raymond Lee of Netgear, for providing a pair of Netgear 73 * GA620 Tigon 2 boards for testing 74 * - Ulf Zimmermann, for bringing the GA260 to my attention and 75 * convincing me to write this driver. 76 * - Andrew Gallatin for providing FreeBSD/Alpha support. 77 */ 78 79#include <sys/cdefs.h> |
80__FBSDID("$FreeBSD: head/sys/dev/ti/if_ti.c 167190 2007-03-04 03:38:08Z csjp $"); | 80__FBSDID("$FreeBSD: head/sys/dev/ti/if_ti.c 173839 2007-11-22 02:45:00Z yongari $"); |
81 82#include "opt_ti.h" 83 84#include <sys/param.h> 85#include <sys/systm.h> 86#include <sys/sockio.h> 87#include <sys/mbuf.h> 88#include <sys/malloc.h> --- 101 unchanged lines hidden (view full) --- 190static void ti_start(struct ifnet *); 191static void ti_start_locked(struct ifnet *); 192static int ti_ioctl(struct ifnet *, u_long, caddr_t); 193static void ti_init(void *); 194static void ti_init_locked(void *); 195static void ti_init2(struct ti_softc *); 196static void ti_stop(struct ti_softc *); 197static void ti_watchdog(struct ifnet *); | 81 82#include "opt_ti.h" 83 84#include <sys/param.h> 85#include <sys/systm.h> 86#include <sys/sockio.h> 87#include <sys/mbuf.h> 88#include <sys/malloc.h> --- 101 unchanged lines hidden (view full) --- 190static void ti_start(struct ifnet *); 191static void ti_start_locked(struct ifnet *); 192static int ti_ioctl(struct ifnet *, u_long, caddr_t); 193static void ti_init(void *); 194static void ti_init_locked(void *); 195static void ti_init2(struct ti_softc *); 196static void ti_stop(struct ti_softc *); 197static void ti_watchdog(struct ifnet *); |
198static void ti_shutdown(device_t); | 198static int ti_shutdown(device_t); |
199static int ti_ifmedia_upd(struct ifnet *); 200static void ti_ifmedia_sts(struct ifnet *, struct ifmediareq *); 201 202static u_int32_t ti_eeprom_putbyte(struct ti_softc *, int); 203static u_int8_t ti_eeprom_getbyte(struct ti_softc *, int, u_int8_t *); 204static int ti_read_eeprom(struct ti_softc *, caddr_t, int, int); 205 206static void ti_add_mcast(struct ti_softc *, struct ether_addr *); --- 3662 unchanged lines hidden (view full) --- 3869 3870 ifp->if_drv_flags &= ~(IFF_DRV_RUNNING | IFF_DRV_OACTIVE); 3871} 3872 3873/* 3874 * Stop all chip I/O so that the kernel's probe routines don't 3875 * get confused by errant DMAs when rebooting. 3876 */ | 199static int ti_ifmedia_upd(struct ifnet *); 200static void ti_ifmedia_sts(struct ifnet *, struct ifmediareq *); 201 202static u_int32_t ti_eeprom_putbyte(struct ti_softc *, int); 203static u_int8_t ti_eeprom_getbyte(struct ti_softc *, int, u_int8_t *); 204static int ti_read_eeprom(struct ti_softc *, caddr_t, int, int); 205 206static void ti_add_mcast(struct ti_softc *, struct ether_addr *); --- 3662 unchanged lines hidden (view full) --- 3869 3870 ifp->if_drv_flags &= ~(IFF_DRV_RUNNING | IFF_DRV_OACTIVE); 3871} 3872 3873/* 3874 * Stop all chip I/O so that the kernel's probe routines don't 3875 * get confused by errant DMAs when rebooting. 3876 */ |
3877static void | 3877static int |
3878ti_shutdown(dev) 3879 device_t dev; 3880{ 3881 struct ti_softc *sc; 3882 3883 sc = device_get_softc(dev); 3884 TI_LOCK(sc); 3885 ti_chipinit(sc); 3886 TI_UNLOCK(sc); | 3878ti_shutdown(dev) 3879 device_t dev; 3880{ 3881 struct ti_softc *sc; 3882 3883 sc = device_get_softc(dev); 3884 TI_LOCK(sc); 3885 ti_chipinit(sc); 3886 TI_UNLOCK(sc); |
3887 3888 return (0); |
|
3887} | 3889} |