if_fe.c (37097) | if_fe.c (40565) |
---|---|
1/* 2 * All Rights Reserved, Copyright (C) Fujitsu Limited 1995 3 * 4 * This software may be used, modified, copied, distributed, and sold, in 5 * both source and binary form provided that the above copyright, these 6 * terms and the following disclaimer are retained. The name of the author 7 * and/or the contributor may not be used to endorse or promote products 8 * derived from this software without specific prior written permission. --- 7 unchanged lines hidden (view full) --- 16 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION. 17 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 18 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 19 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 20 * SUCH DAMAGE. 21 */ 22 23/* | 1/* 2 * All Rights Reserved, Copyright (C) Fujitsu Limited 1995 3 * 4 * This software may be used, modified, copied, distributed, and sold, in 5 * both source and binary form provided that the above copyright, these 6 * terms and the following disclaimer are retained. The name of the author 7 * and/or the contributor may not be used to endorse or promote products 8 * derived from this software without specific prior written permission. --- 7 unchanged lines hidden (view full) --- 16 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION. 17 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 18 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 19 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 20 * SUCH DAMAGE. 21 */ 22 23/* |
24 * $Id: if_fe.c,v 1.41 1998/06/07 17:10:31 dfr Exp $ | 24 * $Id: if_fe.c,v 1.42 1998/06/21 16:51:06 bde Exp $ |
25 * 26 * Device driver for Fujitsu MB86960A/MB86965A based Ethernet cards. 27 * To be used with FreeBSD 2.x 28 * Contributed by M. Sekiguchi. <seki@sysrap.cs.fujitsu.co.jp> 29 * 30 * This version is intended to be a generic template for various 31 * MB86960A/MB86965A based Ethernet cards. It currently supports 32 * Fujitsu FMV-180 series for ISA and Allied-Telesis AT1700/RE2000 --- 198 unchanged lines hidden (view full) --- 231#define sc_if arpcom.ac_if 232#define sc_unit arpcom.ac_if.if_unit 233#define sc_enaddr arpcom.ac_enaddr 234 235/* Standard driver entry points. These can be static. */ 236static int fe_probe ( struct isa_device * ); 237static int fe_attach ( struct isa_device * ); 238static void fe_init ( int ); | 25 * 26 * Device driver for Fujitsu MB86960A/MB86965A based Ethernet cards. 27 * To be used with FreeBSD 2.x 28 * Contributed by M. Sekiguchi. <seki@sysrap.cs.fujitsu.co.jp> 29 * 30 * This version is intended to be a generic template for various 31 * MB86960A/MB86965A based Ethernet cards. It currently supports 32 * Fujitsu FMV-180 series for ISA and Allied-Telesis AT1700/RE2000 --- 198 unchanged lines hidden (view full) --- 231#define sc_if arpcom.ac_if 232#define sc_unit arpcom.ac_if.if_unit 233#define sc_enaddr arpcom.ac_enaddr 234 235/* Standard driver entry points. These can be static. */ 236static int fe_probe ( struct isa_device * ); 237static int fe_attach ( struct isa_device * ); 238static void fe_init ( int ); |
239static ointhand2_t feintr; |
|
239static int fe_ioctl ( struct ifnet *, u_long, caddr_t ); 240static void fe_start ( struct ifnet * ); 241static void fe_reset ( int ); 242static void fe_watchdog ( struct ifnet * ); 243 244/* Local functions. Order of declaration is confused. FIXME. */ 245static int fe_probe_fmv ( DEVICE *, struct fe_softc * ); 246static int fe_probe_ati ( DEVICE *, struct fe_softc * ); --- 1195 unchanged lines hidden (view full) --- 1442static int 1443fe_attach ( DEVICE * dev ) 1444{ 1445#if NCARD > 0 1446 static int already_ifattach[NFE]; 1447#endif 1448 struct fe_softc *sc = &fe_softc[dev->id_unit]; 1449 | 240static int fe_ioctl ( struct ifnet *, u_long, caddr_t ); 241static void fe_start ( struct ifnet * ); 242static void fe_reset ( int ); 243static void fe_watchdog ( struct ifnet * ); 244 245/* Local functions. Order of declaration is confused. FIXME. */ 246static int fe_probe_fmv ( DEVICE *, struct fe_softc * ); 247static int fe_probe_ati ( DEVICE *, struct fe_softc * ); --- 1195 unchanged lines hidden (view full) --- 1443static int 1444fe_attach ( DEVICE * dev ) 1445{ 1446#if NCARD > 0 1447 static int already_ifattach[NFE]; 1448#endif 1449 struct fe_softc *sc = &fe_softc[dev->id_unit]; 1450 |
1451 dev->id_ointr = feintr; 1452 |
|
1450 /* 1451 * Initialize ifnet structure 1452 */ 1453 sc->sc_if.if_softc = sc; 1454 sc->sc_if.if_unit = sc->sc_unit; 1455 sc->sc_if.if_name = "fe"; 1456 sc->sc_if.if_output = ether_output; 1457 sc->sc_if.if_start = fe_start; --- 902 unchanged lines hidden (view full) --- 2360 /* Successfully received a packet. Update stat. */ 2361 sc->sc_if.if_ipackets++; 2362 } 2363} 2364 2365/* 2366 * Ethernet interface interrupt processor 2367 */ | 1453 /* 1454 * Initialize ifnet structure 1455 */ 1456 sc->sc_if.if_softc = sc; 1457 sc->sc_if.if_unit = sc->sc_unit; 1458 sc->sc_if.if_name = "fe"; 1459 sc->sc_if.if_output = ether_output; 1460 sc->sc_if.if_start = fe_start; --- 902 unchanged lines hidden (view full) --- 2363 /* Successfully received a packet. Update stat. */ 2364 sc->sc_if.if_ipackets++; 2365 } 2366} 2367 2368/* 2369 * Ethernet interface interrupt processor 2370 */ |
2368void | 2371static void |
2369feintr ( int unit ) 2370{ 2371 struct fe_softc *sc = &fe_softc[unit]; 2372 u_char tstat, rstat; 2373 2374 /* 2375 * Loop until there are no more new interrupt conditions. 2376 */ --- 769 unchanged lines hidden --- | 2372feintr ( int unit ) 2373{ 2374 struct fe_softc *sc = &fe_softc[unit]; 2375 u_char tstat, rstat; 2376 2377 /* 2378 * Loop until there are no more new interrupt conditions. 2379 */ --- 769 unchanged lines hidden --- |