diff options
author | Michael Shalayeff <mickey@cvs.openbsd.org> | 1996-05-05 13:39:51 +0000 |
---|---|---|
committer | Michael Shalayeff <mickey@cvs.openbsd.org> | 1996-05-05 13:39:51 +0000 |
commit | 69eb3008fd7c3ef1de34f9de181036c0e4610954 (patch) | |
tree | f1d1e3152a6b2bf3967a9f5726672e4fb083f6c3 /sys/arch/mvme68k | |
parent | b98401c6946ce4b2b6909f688f4739738d87ffe0 (diff) |
add general ether_ioctl call in net/if_ethersubr.c,
NS,IPX,X.25 special processing is now handled in there.
reflect this amazing addition in all the ether ifaces.
ppl, pls check the stuff.
Diffstat (limited to 'sys/arch/mvme68k')
-rw-r--r-- | sys/arch/mvme68k/dev/if_ie.c | 30 | ||||
-rw-r--r-- | sys/arch/mvme68k/dev/if_le.c | 37 |
2 files changed, 12 insertions, 55 deletions
diff --git a/sys/arch/mvme68k/dev/if_ie.c b/sys/arch/mvme68k/dev/if_ie.c index f4c4ecddaa6..2370698fc14 100644 --- a/sys/arch/mvme68k/dev/if_ie.c +++ b/sys/arch/mvme68k/dev/if_ie.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_ie.c,v 1.4 1996/04/28 11:06:04 deraadt Exp $ */ +/* $OpenBSD: if_ie.c,v 1.5 1996/05/05 13:37:27 mickey Exp $ */ /*- * Copyright (c) 1995 Theo de Raadt @@ -127,11 +127,6 @@ Mode of operation: #include <netinet/if_ether.h> #endif -#ifdef NS -#include <netns/ns.h> -#include <netns/ns_if.h> -#endif - #include <vm/vm.h> /* @@ -1831,6 +1826,11 @@ ieioctl(ifp, cmd, data) s = splnet(); + if ((error = ether_ioctl(ifp, &sc->sc_arpcom, cmd, data)) > 0) { + splx(s); + return error; + } + switch(cmd) { case SIOCSIFADDR: @@ -1843,24 +1843,6 @@ ieioctl(ifp, cmd, data) arp_ifinit(&sc->sc_arpcom, ifa); break; #endif -#ifdef NS - /* XXX - This code is probably wrong. */ - case AF_NS: - { - struct ns_addr *ina = &IA_SNS(ifa)->sns_addr; - - if (ns_nullhost(*ina)) - ina->x_host = - *(union ns_host *)(sc->sc_arpcom.ac_enaddr); - else - bcopy(ina->x_host.c_host, - sc->sc_arpcom.ac_enaddr, - sizeof(sc->sc_arpcom.ac_enaddr)); - /* Set new address. */ - ieinit(sc); - break; - } -#endif /* NS */ default: ieinit(sc); break; diff --git a/sys/arch/mvme68k/dev/if_le.c b/sys/arch/mvme68k/dev/if_le.c index 89dfcfce69a..d98d976ceee 100644 --- a/sys/arch/mvme68k/dev/if_le.c +++ b/sys/arch/mvme68k/dev/if_le.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_le.c,v 1.4 1996/04/28 11:06:05 deraadt Exp $ */ +/* $OpenBSD: if_le.c,v 1.5 1996/05/05 13:37:32 mickey Exp $ */ /*- * Copyright (c) 1982, 1992, 1993 @@ -71,15 +71,6 @@ #include <netinet/if_ether.h> #endif -#ifdef NS -#include <netns/ns.h> -#include <netns/ns_if.h> -#endif - -#ifdef APPLETALK -#include <netddp/atalk.h> -#endif - #include <machine/cpu.h> #include <machine/autoconf.h> #include <machine/pmap.h> @@ -827,6 +818,11 @@ leioctl(ifp, cmd, data) register struct lereg1 *ler1; int s = splnet(), error = 0; + if ((error = ether_ioctl(ifp, &sc->sc_arpcom, cmd, data)) > 0) { + splx(s); + retun error; + } + switch (cmd) { case SIOCSIFADDR: @@ -839,27 +835,6 @@ leioctl(ifp, cmd, data) arp_ifinit(&sc->sc_ac, ifa); break; #endif -#ifdef NS - case AF_NS: - { - register struct ns_addr *ina = &(IA_SNS(ifa)->sns_addr); - - if (ns_nullhost(*ina)) - ina->x_host = *(union ns_host *)(sc->sc_addr); - else { - /* - * The manual says we can't change the address - * while the receiver is armed, - * so reset everything - */ - ifp->if_flags &= ~IFF_RUNNING; - bcopy((caddr_t)ina->x_host.c_host, - (caddr_t)sc->sc_addr, sizeof(sc->sc_addr)); - } - (void)leinit(ifp->if_unit); /* does le_setaddr() */ - break; - } -#endif default: (void)leinit(ifp->if_unit); break; |