-/* $OpenBSD: if_athn_usb.c,v 1.36 2015/07/09 16:33:42 stsp Exp $ */
+/* $OpenBSD: if_athn_usb.c,v 1.37 2015/10/25 12:11:56 mpi Exp $ */
/*-
* Copyright (c) 2011 Damien Bergamini <damien.bergamini@free.fr>
struct athn_softc *sc = ifp->if_softc;
struct athn_usb_softc *usc = (struct athn_usb_softc *)sc;
struct ieee80211com *ic = &sc->sc_ic;
- struct ifaddr *ifa;
struct ifreq *ifr;
int s, error = 0;
switch (cmd) {
case SIOCSIFADDR:
- ifa = (struct ifaddr *)data;
ifp->if_flags |= IFF_UP;
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&ic->ic_ac, ifa);
/* FALLTHROUGH */
case SIOCSIFFLAGS:
if (ifp->if_flags & IFF_UP) {
-/* $OpenBSD: if_atu.c,v 1.112 2015/06/24 09:40:54 mpi Exp $ */
+/* $OpenBSD: if_atu.c,v 1.113 2015/10/25 12:11:56 mpi Exp $ */
/*
* Copyright (c) 2003, 2004
* Daan Vreeken <Danovitsch@Vitsch.net>. All rights reserved.
atu_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
{
struct atu_softc *sc = ifp->if_softc;
- struct ifaddr *ifa;
int err = 0, s;
s = splnet();
case SIOCSIFADDR:
DPRINTFN(15, ("%s: SIOCSIFADDR\n", sc->atu_dev.dv_xname));
- ifa = (struct ifaddr *)data;
ifp->if_flags |= IFF_UP;
atu_init(ifp);
-
- switch (ifa->ifa_addr->sa_family) {
- case AF_INET:
- arp_ifinit(&sc->sc_ic.ic_ac, ifa);
- break;
- }
break;
case SIOCSIFFLAGS:
-/* $OpenBSD: if_aue.c,v 1.100 2015/06/24 09:40:54 mpi Exp $ */
+/* $OpenBSD: if_aue.c,v 1.101 2015/10/25 12:11:56 mpi Exp $ */
/* $NetBSD: if_aue.c,v 1.82 2003/03/05 17:37:36 shiba Exp $ */
/*
* Copyright (c) 1997, 1998, 1999, 2000
aue_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
{
struct aue_softc *sc = ifp->if_softc;
- struct ifaddr *ifa = (struct ifaddr *)data;
struct ifreq *ifr = (struct ifreq *)data;
int s, error = 0;
ifp->if_flags |= IFF_UP;
if (!(ifp->if_flags & IFF_RUNNING))
aue_init(sc);
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&sc->arpcom, ifa);
break;
case SIOCSIFFLAGS:
-/* $OpenBSD: if_axe.c,v 1.132 2015/06/24 09:40:54 mpi Exp $ */
+/* $OpenBSD: if_axe.c,v 1.133 2015/10/25 12:11:56 mpi Exp $ */
/*
* Copyright (c) 2005, 2006, 2007 Jonathan Gray <jsg@openbsd.org>
{
struct axe_softc *sc = ifp->if_softc;
struct ifreq *ifr = (struct ifreq *)data;
- struct ifaddr *ifa = (struct ifaddr *)data;
int s, error = 0;
s = splnet();
ifp->if_flags |= IFF_UP;
if (!(ifp->if_flags & IFF_RUNNING))
axe_init(sc);
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&sc->arpcom, ifa);
break;
case SIOCSIFFLAGS:
-/* $OpenBSD: if_axen.c,v 1.16 2015/07/16 00:35:06 yuo Exp $ */
+/* $OpenBSD: if_axen.c,v 1.17 2015/10/25 12:11:56 mpi Exp $ */
/*
* Copyright (c) 2013 Yojiro UO <yuo@openbsd.org>
{
struct axen_softc *sc = ifp->if_softc;
struct ifreq *ifr = (struct ifreq *)data;
- struct ifaddr *ifa = (struct ifaddr *)data;
int s;
int error = 0;
ifp->if_flags |= IFF_UP;
if (!(ifp->if_flags & IFF_RUNNING))
axen_init(sc);
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&sc->arpcom, ifa);
break;
case SIOCSIFFLAGS:
-/* $OpenBSD: if_cdce.c,v 1.65 2015/06/24 09:40:54 mpi Exp $ */
+/* $OpenBSD: if_cdce.c,v 1.66 2015/10/25 12:11:56 mpi Exp $ */
/*
* Copyright (c) 1997, 1998, 1999, 2000-2003 Bill Paul <wpaul@windriver.com>
cdce_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
{
struct cdce_softc *sc = ifp->if_softc;
- struct ifaddr *ifa = (struct ifaddr *)data;
int s, error = 0;
if (usbd_is_dying(sc->cdce_udev))
ifp->if_flags |= IFF_UP;
if (!(ifp->if_flags & IFF_RUNNING))
cdce_init(sc);
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&sc->cdce_arpcom, ifa);
break;
case SIOCSIFFLAGS:
-/* $OpenBSD: if_cdcef.c,v 1.37 2015/06/24 09:40:54 mpi Exp $ */
+/* $OpenBSD: if_cdcef.c,v 1.38 2015/10/25 12:11:56 mpi Exp $ */
/*
* Copyright (c) 2007 Dale Rahn <drahn@openbsd.org>
cdcef_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
{
struct cdcef_softc *sc = ifp->if_softc;
- struct ifaddr *ifa = (struct ifaddr *)data;
int s, error = 0;
s = splnet();
ifp->if_flags |= IFF_UP;
if (!(ifp->if_flags & IFF_RUNNING))
cdcef_init(sc);
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&sc->sc_arpcom, ifa);
break;
case SIOCSIFFLAGS:
-/* $OpenBSD: if_cue.c,v 1.71 2015/06/24 09:40:54 mpi Exp $ */
+/* $OpenBSD: if_cue.c,v 1.72 2015/10/25 12:11:56 mpi Exp $ */
/* $NetBSD: if_cue.c,v 1.40 2002/07/11 21:14:26 augustss Exp $ */
/*
* Copyright (c) 1997, 1998, 1999, 2000
cue_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
{
struct cue_softc *sc = ifp->if_softc;
- struct ifaddr *ifa = (struct ifaddr *)data;
int s, error = 0;
if (usbd_is_dying(sc->cue_udev))
case SIOCSIFADDR:
ifp->if_flags |= IFF_UP;
cue_init(sc);
-
- switch (ifa->ifa_addr->sa_family) {
- case AF_INET:
- arp_ifinit(&sc->arpcom, ifa);
- break;
- }
break;
case SIOCSIFFLAGS:
-/* $OpenBSD: if_kue.c,v 1.80 2015/06/24 09:40:54 mpi Exp $ */
+/* $OpenBSD: if_kue.c,v 1.81 2015/10/25 12:11:56 mpi Exp $ */
/* $NetBSD: if_kue.c,v 1.50 2002/07/16 22:00:31 augustss Exp $ */
/*
* Copyright (c) 1997, 1998, 1999, 2000
kue_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
{
struct kue_softc *sc = ifp->if_softc;
- struct ifaddr *ifa = (struct ifaddr *)data;
int s, error = 0;
DPRINTFN(5,("%s: %s: enter\n", sc->kue_dev.dv_xname,__func__));
case SIOCSIFADDR:
ifp->if_flags |= IFF_UP;
kue_init(sc);
-
- switch (ifa->ifa_addr->sa_family) {
- case AF_INET:
- arp_ifinit(&sc->arpcom, ifa);
- break;
- }
break;
case SIOCSIFFLAGS:
-/* $OpenBSD: if_mos.c,v 1.31 2015/06/24 09:40:54 mpi Exp $ */
+/* $OpenBSD: if_mos.c,v 1.32 2015/10/25 12:11:56 mpi Exp $ */
/*
* Copyright (c) 2008 Johann Christian Rode <jcrode@gmx.net>
{
struct mos_softc *sc = ifp->if_softc;
struct ifreq *ifr = (struct ifreq *)data;
- struct ifaddr *ifa = (struct ifaddr *)data;
int s, error = 0;
s = splnet();
ifp->if_flags |= IFF_UP;
if (!(ifp->if_flags & IFF_RUNNING))
mos_init(sc);
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&sc->arpcom, ifa);
break;
case SIOCSIFFLAGS:
-/* $OpenBSD: if_otus.c,v 1.46 2015/03/14 03:38:49 jsg Exp $ */
+/* $OpenBSD: if_otus.c,v 1.47 2015/10/25 12:11:56 mpi Exp $ */
/*-
* Copyright (c) 2009 Damien Bergamini <damien.bergamini@free.fr>
{
struct otus_softc *sc = ifp->if_softc;
struct ieee80211com *ic = &sc->sc_ic;
- struct ifaddr *ifa;
struct ifreq *ifr;
int s, error = 0;
switch (cmd) {
case SIOCSIFADDR:
- ifa = (struct ifaddr *)data;
ifp->if_flags |= IFF_UP;
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&ic->ic_ac, ifa);
/* FALLTHROUGH */
case SIOCSIFFLAGS:
if (ifp->if_flags & IFF_UP) {
-/* $OpenBSD: if_ral.c,v 1.132 2015/03/14 03:38:49 jsg Exp $ */
+/* $OpenBSD: if_ral.c,v 1.133 2015/10/25 12:11:56 mpi Exp $ */
/*-
* Copyright (c) 2005, 2006
{
struct ural_softc *sc = ifp->if_softc;
struct ieee80211com *ic = &sc->sc_ic;
- struct ifaddr *ifa;
struct ifreq *ifr;
int s, error = 0;
switch (cmd) {
case SIOCSIFADDR:
- ifa = (struct ifaddr *)data;
ifp->if_flags |= IFF_UP;
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&ic->ic_ac, ifa);
/* FALLTHROUGH */
case SIOCSIFFLAGS:
if (ifp->if_flags & IFF_UP) {
-/* $OpenBSD: if_rsu.c,v 1.27 2015/06/12 15:47:31 mpi Exp $ */
+/* $OpenBSD: if_rsu.c,v 1.28 2015/10/25 12:11:56 mpi Exp $ */
/*-
* Copyright (c) 2010 Damien Bergamini <damien.bergamini@free.fr>
{
struct rsu_softc *sc = ifp->if_softc;
struct ieee80211com *ic = &sc->sc_ic;
- struct ifaddr *ifa;
struct ifreq *ifr;
int s, error = 0;
switch (cmd) {
case SIOCSIFADDR:
- ifa = (struct ifaddr *)data;
ifp->if_flags |= IFF_UP;
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&ic->ic_ac, ifa);
/* FALLTHROUGH */
case SIOCSIFFLAGS:
if (ifp->if_flags & IFF_UP) {
-/* $OpenBSD: if_rum.c,v 1.111 2015/06/12 15:47:31 mpi Exp $ */
+/* $OpenBSD: if_rum.c,v 1.112 2015/10/25 12:11:56 mpi Exp $ */
/*-
* Copyright (c) 2005-2007 Damien Bergamini <damien.bergamini@free.fr>
{
struct rum_softc *sc = ifp->if_softc;
struct ieee80211com *ic = &sc->sc_ic;
- struct ifaddr *ifa;
struct ifreq *ifr;
int s, error = 0;
switch (cmd) {
case SIOCSIFADDR:
- ifa = (struct ifaddr *)data;
ifp->if_flags |= IFF_UP;
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&ic->ic_ac, ifa);
/* FALLTHROUGH */
case SIOCSIFFLAGS:
if (ifp->if_flags & IFF_UP) {
-/* $OpenBSD: if_run.c,v 1.110 2015/08/28 15:37:04 reyk Exp $ */
+/* $OpenBSD: if_run.c,v 1.111 2015/10/25 12:11:56 mpi Exp $ */
/*-
* Copyright (c) 2008-2010 Damien Bergamini <damien.bergamini@free.fr>
{
struct run_softc *sc = ifp->if_softc;
struct ieee80211com *ic = &sc->sc_ic;
- struct ifaddr *ifa;
struct ifreq *ifr;
int s, error = 0;
switch (cmd) {
case SIOCSIFADDR:
- ifa = (struct ifaddr *)data;
ifp->if_flags |= IFF_UP;
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&ic->ic_ac, ifa);
/* FALLTHROUGH */
case SIOCSIFFLAGS:
if (ifp->if_flags & IFF_UP) {
-/* $OpenBSD: if_smsc.c,v 1.20 2015/06/24 09:40:54 mpi Exp $ */
+/* $OpenBSD: if_smsc.c,v 1.21 2015/10/25 12:11:56 mpi Exp $ */
/* $FreeBSD: src/sys/dev/usb/net/if_smsc.c,v 1.1 2012/08/15 04:03:55 gonzo Exp $ */
/*-
* Copyright (c) 2012
{
struct smsc_softc *sc = ifp->if_softc;
struct ifreq *ifr = (struct ifreq *)data;
- struct ifaddr *ifa = (struct ifaddr *)data;
int s, error = 0;
s = splnet();
ifp->if_flags |= IFF_UP;
if (!(ifp->if_flags & IFF_RUNNING))
smsc_init(sc);
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&sc->sc_ac, ifa);
break;
case SIOCSIFFLAGS:
-/* $OpenBSD: if_uath.c,v 1.69 2015/07/15 13:27:41 mpi Exp $ */
+/* $OpenBSD: if_uath.c,v 1.70 2015/10/25 12:11:56 mpi Exp $ */
/*-
* Copyright (c) 2006
{
struct uath_softc *sc = ifp->if_softc;
struct ieee80211com *ic = &sc->sc_ic;
- struct ifaddr *ifa;
struct ifreq *ifr;
int s, error = 0;
switch (cmd) {
case SIOCSIFADDR:
- ifa = (struct ifaddr *)data;
ifp->if_flags |= IFF_UP;
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&ic->ic_ac, ifa);
/* FALLTHROUGH */
case SIOCSIFFLAGS:
if (ifp->if_flags & IFF_UP) {
-/* $OpenBSD: if_udav.c,v 1.72 2015/06/24 09:40:54 mpi Exp $ */
+/* $OpenBSD: if_udav.c,v 1.73 2015/10/25 12:11:56 mpi Exp $ */
/* $NetBSD: if_udav.c,v 1.3 2004/04/23 17:25:25 itojun Exp $ */
/* $nabe: if_udav.c,v 1.3 2003/08/21 16:57:19 nabe Exp $ */
/*
udav_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
{
struct udav_softc *sc = ifp->if_softc;
- struct ifaddr *ifa = (struct ifaddr *)data;
struct ifreq *ifr = (struct ifreq *)data;
int s, error = 0;
ifp->if_flags |= IFF_UP;
if (!(ifp->if_flags & IFF_RUNNING))
udav_init(ifp);
-
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&sc->sc_ac, ifa);
break;
case SIOCSIFFLAGS:
-/* $OpenBSD: if_ugl.c,v 1.13 2015/06/24 09:40:54 mpi Exp $ */
+/* $OpenBSD: if_ugl.c,v 1.14 2015/10/25 12:11:56 mpi Exp $ */
/* $NetBSD: if_upl.c,v 1.19 2002/07/11 21:14:26 augustss Exp $ */
/*
* Copyright (c) 2013 SASANO Takayoshi <uaa@uaa.org.uk>
ugl_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
{
struct ugl_softc *sc = ifp->if_softc;
- struct ifaddr *ifa = (struct ifaddr *)data;
int s, error = 0;
if (usbd_is_dying(sc->sc_udev))
ifp->if_flags |= IFF_UP;
if (!(ifp->if_flags & IFF_RUNNING))
ugl_init(sc);
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&sc->sc_arpcom, ifa);
break;
case SIOCSIFFLAGS:
-/* $OpenBSD: if_upgt.c,v 1.69 2015/05/02 10:44:29 jsg Exp $ */
+/* $OpenBSD: if_upgt.c,v 1.70 2015/10/25 12:11:56 mpi Exp $ */
/*
* Copyright (c) 2007 Marcus Glocker <mglocker@openbsd.org>
{
struct upgt_softc *sc = ifp->if_softc;
struct ieee80211com *ic = &sc->sc_ic;
- struct ifaddr *ifa;
struct ifreq *ifr;
int s, error = 0;
uint8_t chan;
switch (cmd) {
case SIOCSIFADDR:
- ifa = (struct ifaddr *)data;
ifp->if_flags |= IFF_UP;
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&ic->ic_ac, ifa);
/* FALLTHROUGH */
case SIOCSIFFLAGS:
if (ifp->if_flags & IFF_UP) {
-/* $OpenBSD: if_url.c,v 1.75 2015/06/24 09:40:54 mpi Exp $ */
+/* $OpenBSD: if_url.c,v 1.76 2015/10/25 12:11:56 mpi Exp $ */
/* $NetBSD: if_url.c,v 1.6 2002/09/29 10:19:21 martin Exp $ */
/*
* Copyright (c) 2001, 2002
url_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
{
struct url_softc *sc = ifp->if_softc;
- struct ifaddr *ifa = (struct ifaddr *)data;
struct ifreq *ifr = (struct ifreq *)data;
int s, error = 0;
ifp->if_flags |= IFF_UP;
if (!(ifp->if_flags & IFF_RUNNING))
url_init(ifp);
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&sc->sc_ac, ifa);
break;
case SIOCSIFFLAGS:
-/* $OpenBSD: if_urndis.c,v 1.55 2015/06/24 09:40:54 mpi Exp $ */
+/* $OpenBSD: if_urndis.c,v 1.56 2015/10/25 12:11:56 mpi Exp $ */
/*
* Copyright (c) 2010 Jonathan Armani <armani@openbsd.org>
urndis_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
{
struct urndis_softc *sc = ifp->if_softc;
- struct ifaddr *ifa = (struct ifaddr *)data;
int s, error = 0;
if (usbd_is_dying(sc->sc_udev))
ifp->if_flags |= IFF_UP;
if (!(ifp->if_flags & IFF_RUNNING))
urndis_init(sc);
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&sc->sc_arpcom, ifa);
break;
case SIOCSIFFLAGS:
-/* $OpenBSD: if_urtw.c,v 1.54 2015/07/15 17:52:08 stsp Exp $ */
+/* $OpenBSD: if_urtw.c,v 1.55 2015/10/25 12:11:56 mpi Exp $ */
/*-
* Copyright (c) 2009 Martynas Venckus <martynas@openbsd.org>
{
struct urtw_softc *sc = ifp->if_softc;
struct ieee80211com *ic = &sc->sc_ic;
- struct ifaddr *ifa;
struct ifreq *ifr;
int s, error = 0;
switch (cmd) {
case SIOCSIFADDR:
- ifa = (struct ifaddr *)data;
ifp->if_flags |= IFF_UP;
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&ic->ic_ac, ifa);
/* FALLTHROUGH */
case SIOCSIFFLAGS:
if (ifp->if_flags & IFF_UP) {
-/* $OpenBSD: if_urtwn.c,v 1.52 2015/09/18 11:24:15 mpi Exp $ */
+/* $OpenBSD: if_urtwn.c,v 1.53 2015/10/25 12:11:56 mpi Exp $ */
/*-
* Copyright (c) 2010 Damien Bergamini <damien.bergamini@free.fr>
{
struct urtwn_softc *sc = ifp->if_softc;
struct ieee80211com *ic = &sc->sc_ic;
- struct ifaddr *ifa;
struct ifreq *ifr;
int s, error = 0;
switch (cmd) {
case SIOCSIFADDR:
- ifa = (struct ifaddr *)data;
ifp->if_flags |= IFF_UP;
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&ic->ic_ac, ifa);
/* FALLTHROUGH */
case SIOCSIFFLAGS:
if (ifp->if_flags & IFF_UP) {
-/* $OpenBSD: if_zyd.c,v 1.108 2015/03/14 03:38:49 jsg Exp $ */
+/* $OpenBSD: if_zyd.c,v 1.109 2015/10/25 12:11:56 mpi Exp $ */
/*-
* Copyright (c) 2006 by Damien Bergamini <damien.bergamini@free.fr>
{
struct zyd_softc *sc = ifp->if_softc;
struct ieee80211com *ic = &sc->sc_ic;
- struct ifaddr *ifa;
struct ifreq *ifr;
int s, error = 0;
switch (cmd) {
case SIOCSIFADDR:
- ifa = (struct ifaddr *)data;
ifp->if_flags |= IFF_UP;
- if (ifa->ifa_addr->sa_family == AF_INET)
- arp_ifinit(&ic->ic_ac, ifa);
/* FALLTHROUGH */
case SIOCSIFFLAGS:
if (ifp->if_flags & IFF_UP) {