Module Name: src
Committed By: ozaki-r
Date: Thu Nov 16 03:07:18 UTC 2017
Modified Files:
src/sys/arch/arm/sunxi: sunxi_emac.c
src/sys/dev/ic: dwc_gmac.c
src/sys/dev/pci: if_wm.c
src/sys/dev/pci/ixgbe: ixgbe.c ixv.c
src/sys/net: if.h if_bridge.c if_ethersubr.c if_gif.c if_l2tp.c
if_loop.c if_pppoe.c if_vlan.c
src/sys/netcan: if_canloop.c
src/sys/netinet: ip_carp.c
Log Message:
Unify IFEF_*_MPSAFE into IFEF_MPSAFE
There are already two flags for if_output and if_start, however, it seems such
MPSAFE flags are eventually needed for all if_XXX operations. Having discrete
flags for each operation is wasteful of if_extflags bits. So let's unify
the flags into one: IFEF_MPSAFE.
Fortunately IFEF_*_MPSAFE flags have never been included in any releases, so
we can change them without breaking backward compatibility of the releases
(though the kernel version of -current should be bumped).
Note that if an interface have both MP-safe and non-MP-safe operations at a
time, we have to set the IFEF_MPSAFE flag and let callees of non-MP-safe
opeartions take the kernel lock.
Proposed on tech-kern@ and tech-net@
To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/arm/sunxi/sunxi_emac.c
cvs rdiff -u -r1.42 -r1.43 src/sys/dev/ic/dwc_gmac.c
cvs rdiff -u -r1.542 -r1.543 src/sys/dev/pci/if_wm.c
cvs rdiff -u -r1.111 -r1.112 src/sys/dev/pci/ixgbe/ixgbe.c
cvs rdiff -u -r1.73 -r1.74 src/sys/dev/pci/ixgbe/ixv.c
cvs rdiff -u -r1.241 -r1.242 src/sys/net/if.h
cvs rdiff -u -r1.139 -r1.140 src/sys/net/if_bridge.c
cvs rdiff -u -r1.245 -r1.246 src/sys/net/if_ethersubr.c
cvs rdiff -u -r1.131 -r1.132 src/sys/net/if_gif.c
cvs rdiff -u -r1.14 -r1.15 src/sys/net/if_l2tp.c
cvs rdiff -u -r1.97 -r1.98 src/sys/net/if_loop.c
cvs rdiff -u -r1.130 -r1.131 src/sys/net/if_pppoe.c
cvs rdiff -u -r1.106 -r1.107 src/sys/net/if_vlan.c
cvs rdiff -u -r1.2 -r1.3 src/sys/netcan/if_canloop.c
cvs rdiff -u -r1.91 -r1.92 src/sys/netinet/ip_carp.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/arch/arm/sunxi/sunxi_emac.c
diff -u src/sys/arch/arm/sunxi/sunxi_emac.c:1.8 src/sys/arch/arm/sunxi/sunxi_emac.c:1.9
--- src/sys/arch/arm/sunxi/sunxi_emac.c:1.8 Sun Oct 1 15:05:09 2017
+++ src/sys/arch/arm/sunxi/sunxi_emac.c Thu Nov 16 03:07:17 2017
@@ -1,4 +1,4 @@
-/* $NetBSD: sunxi_emac.c,v 1.8 2017/10/01 15:05:09 jmcneill Exp $ */
+/* $NetBSD: sunxi_emac.c,v 1.9 2017/11/16 03:07:17 ozaki-r Exp $ */
/*-
* Copyright (c) 2016-2017 Jared McNeill <[email protected]>
@@ -33,7 +33,7 @@
#include "opt_net_mpsafe.h"
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: sunxi_emac.c,v 1.8 2017/10/01 15:05:09 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sunxi_emac.c,v 1.9 2017/11/16 03:07:17 ozaki-r Exp $");
#include <sys/param.h>
#include <sys/bus.h>
@@ -1381,7 +1381,7 @@ sunxi_emac_attach(device_t parent, devic
snprintf(ifp->if_xname, IFNAMSIZ, EMAC_IFNAME, device_unit(self));
ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST;
#ifdef EMAC_MPSAFE
- ifp->if_extflags = IFEF_START_MPSAFE;
+ ifp->if_extflags = IFEF_MPSAFE;
#endif
ifp->if_start = sunxi_emac_start;
ifp->if_ioctl = sunxi_emac_ioctl;
Index: src/sys/dev/ic/dwc_gmac.c
diff -u src/sys/dev/ic/dwc_gmac.c:1.42 src/sys/dev/ic/dwc_gmac.c:1.43
--- src/sys/dev/ic/dwc_gmac.c:1.42 Mon Oct 23 15:08:05 2017
+++ src/sys/dev/ic/dwc_gmac.c Thu Nov 16 03:07:17 2017
@@ -1,4 +1,4 @@
-/* $NetBSD: dwc_gmac.c,v 1.42 2017/10/23 15:08:05 jakllsch Exp $ */
+/* $NetBSD: dwc_gmac.c,v 1.43 2017/11/16 03:07:17 ozaki-r Exp $ */
/*-
* Copyright (c) 2013, 2014 The NetBSD Foundation, Inc.
@@ -41,7 +41,7 @@
#include <sys/cdefs.h>
-__KERNEL_RCSID(1, "$NetBSD: dwc_gmac.c,v 1.42 2017/10/23 15:08:05 jakllsch Exp $");
+__KERNEL_RCSID(1, "$NetBSD: dwc_gmac.c,v 1.43 2017/11/16 03:07:17 ozaki-r Exp $");
/* #define DWC_GMAC_DEBUG 1 */
@@ -223,7 +223,7 @@ dwc_gmac_attach(struct dwc_gmac_softc *s
ifp->if_softc = sc;
strlcpy(ifp->if_xname, device_xname(sc->sc_dev), IFNAMSIZ);
ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST;
- ifp->if_extflags = IFEF_START_MPSAFE;
+ ifp->if_extflags = IFEF_MPSAFE;
ifp->if_ioctl = dwc_gmac_ioctl;
ifp->if_start = dwc_gmac_start;
ifp->if_init = dwc_gmac_init;
@@ -836,7 +836,7 @@ static void
dwc_gmac_start(struct ifnet *ifp)
{
struct dwc_gmac_softc *sc = ifp->if_softc;
- KASSERT(ifp->if_extflags & IFEF_START_MPSAFE);
+ KASSERT(if_is_mpsafe(ifp));
mutex_enter(sc->sc_lock);
if (!sc->sc_stopping) {
Index: src/sys/dev/pci/if_wm.c
diff -u src/sys/dev/pci/if_wm.c:1.542 src/sys/dev/pci/if_wm.c:1.543
--- src/sys/dev/pci/if_wm.c:1.542 Mon Oct 23 23:29:38 2017
+++ src/sys/dev/pci/if_wm.c Thu Nov 16 03:07:18 2017
@@ -1,4 +1,4 @@
-/* $NetBSD: if_wm.c,v 1.542 2017/10/23 23:29:38 knakahara Exp $ */
+/* $NetBSD: if_wm.c,v 1.543 2017/11/16 03:07:18 ozaki-r Exp $ */
/*
* Copyright (c) 2001, 2002, 2003, 2004 Wasabi Systems, Inc.
@@ -83,7 +83,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.542 2017/10/23 23:29:38 knakahara Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.543 2017/11/16 03:07:18 ozaki-r Exp $");
#ifdef _KERNEL_OPT
#include "opt_net_mpsafe.h"
@@ -2630,7 +2630,7 @@ alloc_retry:
ifp->if_softc = sc;
ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST;
#ifdef WM_MPSAFE
- ifp->if_extflags = IFEF_START_MPSAFE;
+ ifp->if_extflags = IFEF_MPSAFE;
#endif
ifp->if_ioctl = wm_ioctl;
if ((sc->sc_flags & WM_F_NEWQUEUE) != 0) {
@@ -6990,7 +6990,7 @@ wm_start(struct ifnet *ifp)
struct wm_txqueue *txq = &sc->sc_queue[0].wmq_txq;
#ifdef WM_MPSAFE
- KASSERT(ifp->if_extflags & IFEF_START_MPSAFE);
+ KASSERT(if_is_mpsafe(ifp));
#endif
/*
* ifp->if_obytes and ifp->if_omcasts are added in if_transmit()@if.c.
@@ -7583,7 +7583,7 @@ wm_nq_start(struct ifnet *ifp)
struct wm_txqueue *txq = &sc->sc_queue[0].wmq_txq;
#ifdef WM_MPSAFE
- KASSERT(ifp->if_extflags & IFEF_START_MPSAFE);
+ KASSERT(if_is_mpsafe(ifp));
#endif
/*
* ifp->if_obytes and ifp->if_omcasts are added in if_transmit()@if.c.
Index: src/sys/dev/pci/ixgbe/ixgbe.c
diff -u src/sys/dev/pci/ixgbe/ixgbe.c:1.111 src/sys/dev/pci/ixgbe/ixgbe.c:1.112
--- src/sys/dev/pci/ixgbe/ixgbe.c:1.111 Sun Nov 12 05:11:36 2017
+++ src/sys/dev/pci/ixgbe/ixgbe.c Thu Nov 16 03:07:18 2017
@@ -1,4 +1,4 @@
-/* $NetBSD: ixgbe.c,v 1.111 2017/11/12 05:11:36 msaitoh Exp $ */
+/* $NetBSD: ixgbe.c,v 1.112 2017/11/16 03:07:18 ozaki-r Exp $ */
/******************************************************************************
@@ -1214,7 +1214,7 @@ ixgbe_setup_interface(device_t dev, stru
ifp->if_softc = adapter;
ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST;
#ifdef IXGBE_MPSAFE
- ifp->if_extflags = IFEF_START_MPSAFE;
+ ifp->if_extflags = IFEF_MPSAFE;
#endif
ifp->if_ioctl = ixgbe_ioctl;
#if __FreeBSD_version >= 1100045
Index: src/sys/dev/pci/ixgbe/ixv.c
diff -u src/sys/dev/pci/ixgbe/ixv.c:1.73 src/sys/dev/pci/ixgbe/ixv.c:1.74
--- src/sys/dev/pci/ixgbe/ixv.c:1.73 Mon Oct 23 09:31:18 2017
+++ src/sys/dev/pci/ixgbe/ixv.c Thu Nov 16 03:07:18 2017
@@ -1,4 +1,4 @@
-/*$NetBSD: ixv.c,v 1.73 2017/10/23 09:31:18 msaitoh Exp $*/
+/*$NetBSD: ixv.c,v 1.74 2017/11/16 03:07:18 ozaki-r Exp $*/
/******************************************************************************
@@ -1391,7 +1391,7 @@ ixv_setup_interface(device_t dev, struct
ifp->if_softc = adapter;
ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST;
#ifdef IXGBE_MPSAFE
- ifp->if_extflags = IFEF_START_MPSAFE;
+ ifp->if_extflags = IFEF_MPSAFE;
#endif
ifp->if_ioctl = ixv_ioctl;
if (adapter->feat_en & IXGBE_FEATURE_LEGACY_TX) {
Index: src/sys/net/if.h
diff -u src/sys/net/if.h:1.241 src/sys/net/if.h:1.242
--- src/sys/net/if.h:1.241 Mon Oct 23 09:21:20 2017
+++ src/sys/net/if.h Thu Nov 16 03:07:18 2017
@@ -1,4 +1,4 @@
-/* $NetBSD: if.h,v 1.241 2017/10/23 09:21:20 msaitoh Exp $ */
+/* $NetBSD: if.h,v 1.242 2017/11/16 03:07:18 ozaki-r Exp $ */
/*-
* Copyright (c) 1999, 2000, 2001 The NetBSD Foundation, Inc.
@@ -387,16 +387,21 @@ typedef struct ifnet {
#define IFF_LINK2 0x4000 /* per link layer defined bit */
#define IFF_MULTICAST 0x8000 /* supports multicast */
-#define IFEF_OUTPUT_MPSAFE __BIT(0) /* if_output() can run parallel */
-#define IFEF_START_MPSAFE __BIT(1) /* if_start() can run parallel */
-#define IFEF_NO_LINK_STATE_CHANGE __BIT(2) /* doesn't use link state interrupts */
+#define IFEF_MPSAFE __BIT(0) /* handlers can run in parallel (see below) */
+#define IFEF_NO_LINK_STATE_CHANGE __BIT(1) /* doesn't use link state interrupts */
+
+/*
+ * if_XXX() handlers that IFEF_MPSAFE suppresses KERNEL_LOCK:
+ * - if_start
+ * - if_output
+ */
#ifdef _KERNEL
static inline bool
-if_output_is_mpsafe(struct ifnet *ifp)
+if_is_mpsafe(struct ifnet *ifp)
{
- return ((ifp->if_extflags & IFEF_OUTPUT_MPSAFE) != 0);
+ return ((ifp->if_extflags & IFEF_MPSAFE) != 0);
}
static inline int
@@ -404,7 +409,7 @@ if_output_lock(struct ifnet *cifp, struc
const struct sockaddr *dst, const struct rtentry *rt)
{
- if (if_output_is_mpsafe(cifp)) {
+ if (if_is_mpsafe(cifp)) {
return (*cifp->if_output)(ifp, m, dst, rt);
} else {
int ret;
@@ -416,18 +421,11 @@ if_output_lock(struct ifnet *cifp, struc
}
}
-static inline bool
-if_start_is_mpsafe(struct ifnet *ifp)
-{
-
- return ((ifp->if_extflags & IFEF_START_MPSAFE) != 0);
-}
-
static inline void
if_start_lock(struct ifnet *ifp)
{
- if (if_start_is_mpsafe(ifp)) {
+ if (if_is_mpsafe(ifp)) {
(*ifp->if_start)(ifp);
} else {
KERNEL_LOCK(1, NULL);
Index: src/sys/net/if_bridge.c
diff -u src/sys/net/if_bridge.c:1.139 src/sys/net/if_bridge.c:1.140
--- src/sys/net/if_bridge.c:1.139 Wed Nov 15 06:17:40 2017
+++ src/sys/net/if_bridge.c Thu Nov 16 03:07:18 2017
@@ -1,4 +1,4 @@
-/* $NetBSD: if_bridge.c,v 1.139 2017/11/15 06:17:40 ozaki-r Exp $ */
+/* $NetBSD: if_bridge.c,v 1.140 2017/11/16 03:07:18 ozaki-r Exp $ */
/*
* Copyright 2001 Wasabi Systems, Inc.
@@ -80,7 +80,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_bridge.c,v 1.139 2017/11/15 06:17:40 ozaki-r Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_bridge.c,v 1.140 2017/11/16 03:07:18 ozaki-r Exp $");
#ifdef _KERNEL_OPT
#include "opt_bridge_ipf.h"
@@ -424,7 +424,7 @@ bridge_clone_create(struct if_clone *ifc
if_initname(ifp, ifc->ifc_name, unit);
ifp->if_softc = sc;
- ifp->if_extflags = IFEF_OUTPUT_MPSAFE;
+ ifp->if_extflags = IFEF_MPSAFE;
ifp->if_mtu = ETHERMTU;
ifp->if_ioctl = bridge_ioctl;
ifp->if_output = bridge_output;
@@ -1440,7 +1440,7 @@ bridge_output(struct ifnet *ifp, struct
/*
* bridge_output() is called from ether_output(), furthermore
* ifp argument doesn't point to bridge(4). So, don't assert
- * IFEF_OUTPUT_MPSAFE here.
+ * IFEF_MPSAFE here.
*/
if (m->m_len < ETHER_HDR_LEN) {
Index: src/sys/net/if_ethersubr.c
diff -u src/sys/net/if_ethersubr.c:1.245 src/sys/net/if_ethersubr.c:1.246
--- src/sys/net/if_ethersubr.c:1.245 Thu Oct 26 09:41:15 2017
+++ src/sys/net/if_ethersubr.c Thu Nov 16 03:07:18 2017
@@ -1,4 +1,4 @@
-/* $NetBSD: if_ethersubr.c,v 1.245 2017/10/26 09:41:15 msaitoh Exp $ */
+/* $NetBSD: if_ethersubr.c,v 1.246 2017/11/16 03:07:18 ozaki-r Exp $ */
/*
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
@@ -61,7 +61,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_ethersubr.c,v 1.245 2017/10/26 09:41:15 msaitoh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_ethersubr.c,v 1.246 2017/11/16 03:07:18 ozaki-r Exp $");
#ifdef _KERNEL_OPT
#include "opt_inet.h"
@@ -204,13 +204,6 @@ ether_output(struct ifnet * const ifp0,
struct at_ifaddr *aa;
#endif /* NETATALK */
- /*
- * some paths such as carp_output() call ethr_output() with "ifp"
- * argument as other than ether ifnet.
- */
- KASSERT(ifp->if_output != ether_output
- || ifp->if_extflags & IFEF_OUTPUT_MPSAFE);
-
#ifdef MBUFTRACE
m_claimm(m, ifp->if_mowner);
#endif
@@ -951,7 +944,6 @@ ether_ifattach(struct ifnet *ifp, const
{
struct ethercom *ec = (struct ethercom *)ifp;
- ifp->if_extflags |= IFEF_OUTPUT_MPSAFE;
ifp->if_type = IFT_ETHER;
ifp->if_hdrlen = ETHER_HDR_LEN;
ifp->if_dlt = DLT_EN10MB;
Index: src/sys/net/if_gif.c
diff -u src/sys/net/if_gif.c:1.131 src/sys/net/if_gif.c:1.132
--- src/sys/net/if_gif.c:1.131 Mon Oct 23 09:31:18 2017
+++ src/sys/net/if_gif.c Thu Nov 16 03:07:18 2017
@@ -1,4 +1,4 @@
-/* $NetBSD: if_gif.c,v 1.131 2017/10/23 09:31:18 msaitoh Exp $ */
+/* $NetBSD: if_gif.c,v 1.132 2017/11/16 03:07:18 ozaki-r Exp $ */
/* $KAME: if_gif.c,v 1.76 2001/08/20 02:01:02 kjc Exp $ */
/*
@@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_gif.c,v 1.131 2017/10/23 09:31:18 msaitoh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_gif.c,v 1.132 2017/11/16 03:07:18 ozaki-r Exp $");
#ifdef _KERNEL_OPT
#include "opt_inet.h"
@@ -275,7 +275,7 @@ gifattach0(struct gif_softc *sc)
sc->gif_if.if_flags = IFF_POINTOPOINT | IFF_MULTICAST;
sc->gif_if.if_extflags = IFEF_NO_LINK_STATE_CHANGE;
#ifdef GIF_MPSAFE
- sc->gif_if.if_extflags |= IFEF_OUTPUT_MPSAFE;
+ sc->gif_if.if_extflags |= IFEF_MPSAFE;
#endif
sc->gif_if.if_ioctl = gif_ioctl;
sc->gif_if.if_output = gif_output;
Index: src/sys/net/if_l2tp.c
diff -u src/sys/net/if_l2tp.c:1.14 src/sys/net/if_l2tp.c:1.15
--- src/sys/net/if_l2tp.c:1.14 Mon Oct 30 16:01:19 2017
+++ src/sys/net/if_l2tp.c Thu Nov 16 03:07:18 2017
@@ -1,4 +1,4 @@
-/* $NetBSD: if_l2tp.c,v 1.14 2017/10/30 16:01:19 ozaki-r Exp $ */
+/* $NetBSD: if_l2tp.c,v 1.15 2017/11/16 03:07:18 ozaki-r Exp $ */
/*
* Copyright (c) 2017 Internet Initiative Japan Inc.
@@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_l2tp.c,v 1.14 2017/10/30 16:01:19 ozaki-r Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_l2tp.c,v 1.15 2017/11/16 03:07:18 ozaki-r Exp $");
#ifdef _KERNEL_OPT
#include "opt_inet.h"
@@ -265,8 +265,7 @@ l2tpattach0(struct l2tp_softc *sc)
sc->l2tp_ec.ec_if.if_addrlen = 0;
sc->l2tp_ec.ec_if.if_mtu = L2TP_MTU;
sc->l2tp_ec.ec_if.if_flags = IFF_POINTOPOINT|IFF_MULTICAST|IFF_SIMPLEX;
- sc->l2tp_ec.ec_if.if_extflags = IFEF_OUTPUT_MPSAFE |
- IFEF_START_MPSAFE | IFEF_NO_LINK_STATE_CHANGE;
+ sc->l2tp_ec.ec_if.if_extflags = IFEF_MPSAFE | IFEF_NO_LINK_STATE_CHANGE;
sc->l2tp_ec.ec_if.if_ioctl = l2tp_ioctl;
sc->l2tp_ec.ec_if.if_output = l2tp_output;
sc->l2tp_ec.ec_if.if_type = IFT_L2TP;
Index: src/sys/net/if_loop.c
diff -u src/sys/net/if_loop.c:1.97 src/sys/net/if_loop.c:1.98
--- src/sys/net/if_loop.c:1.97 Wed Nov 15 04:08:02 2017
+++ src/sys/net/if_loop.c Thu Nov 16 03:07:18 2017
@@ -1,4 +1,4 @@
-/* $NetBSD: if_loop.c,v 1.97 2017/11/15 04:08:02 ozaki-r Exp $ */
+/* $NetBSD: if_loop.c,v 1.98 2017/11/16 03:07:18 ozaki-r Exp $ */
/*
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
@@ -65,7 +65,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_loop.c,v 1.97 2017/11/15 04:08:02 ozaki-r Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_loop.c,v 1.98 2017/11/16 03:07:18 ozaki-r Exp $");
#ifdef _KERNEL_OPT
#include "opt_inet.h"
@@ -183,7 +183,7 @@ loop_clone_create(struct if_clone *ifc,
ifp->if_mtu = LOMTU;
ifp->if_flags = IFF_LOOPBACK | IFF_MULTICAST | IFF_RUNNING;
- ifp->if_extflags = IFEF_OUTPUT_MPSAFE;
+ ifp->if_extflags = IFEF_MPSAFE;
ifp->if_ioctl = loioctl;
ifp->if_output = looutput;
#ifdef ALTQ
Index: src/sys/net/if_pppoe.c
diff -u src/sys/net/if_pppoe.c:1.130 src/sys/net/if_pppoe.c:1.131
--- src/sys/net/if_pppoe.c:1.130 Wed Nov 15 07:52:58 2017
+++ src/sys/net/if_pppoe.c Thu Nov 16 03:07:18 2017
@@ -1,4 +1,4 @@
-/* $NetBSD: if_pppoe.c,v 1.130 2017/11/15 07:52:58 knakahara Exp $ */
+/* $NetBSD: if_pppoe.c,v 1.131 2017/11/16 03:07:18 ozaki-r Exp $ */
/*-
* Copyright (c) 2002, 2008 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_pppoe.c,v 1.130 2017/11/15 07:52:58 knakahara Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_pppoe.c,v 1.131 2017/11/16 03:07:18 ozaki-r Exp $");
#ifdef _KERNEL_OPT
#include "pppoe.h"
@@ -303,7 +303,7 @@ pppoe_clone_create(struct if_clone *ifc,
sc->sc_sppp.pp_if.if_mtu = PPPOE_MAXMTU;
sc->sc_sppp.pp_if.if_flags = IFF_SIMPLEX|IFF_POINTOPOINT|IFF_MULTICAST;
#ifdef PPPOE_MPSAFE
- sc->sc_sppp.pp_if.if_extflags = IFEF_OUTPUT_MPSAFE;
+ sc->sc_sppp.pp_if.if_extflags = IFEF_MPSAFE;
#endif
sc->sc_sppp.pp_if.if_type = IFT_PPP;
sc->sc_sppp.pp_if.if_hdrlen = sizeof(struct ether_header) + PPPOE_HEADERLEN;
Index: src/sys/net/if_vlan.c
diff -u src/sys/net/if_vlan.c:1.106 src/sys/net/if_vlan.c:1.107
--- src/sys/net/if_vlan.c:1.106 Mon Oct 30 16:01:19 2017
+++ src/sys/net/if_vlan.c Thu Nov 16 03:07:18 2017
@@ -1,4 +1,4 @@
-/* $NetBSD: if_vlan.c,v 1.106 2017/10/30 16:01:19 ozaki-r Exp $ */
+/* $NetBSD: if_vlan.c,v 1.107 2017/11/16 03:07:18 ozaki-r Exp $ */
/*-
* Copyright (c) 2000, 2001 The NetBSD Foundation, Inc.
@@ -78,7 +78,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_vlan.c,v 1.106 2017/10/30 16:01:19 ozaki-r Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_vlan.c,v 1.107 2017/11/16 03:07:18 ozaki-r Exp $");
#ifdef _KERNEL_OPT
#include "opt_inet.h"
@@ -338,7 +338,7 @@ vlan_clone_create(struct if_clone *ifc,
if_initname(ifp, ifc->ifc_name, unit);
ifp->if_softc = ifv;
ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST;
- ifp->if_extflags = IFEF_START_MPSAFE | IFEF_NO_LINK_STATE_CHANGE;
+ ifp->if_extflags = IFEF_MPSAFE | IFEF_NO_LINK_STATE_CHANGE;
ifp->if_start = vlan_start;
ifp->if_transmit = vlan_transmit;
ifp->if_ioctl = vlan_ioctl;
Index: src/sys/netcan/if_canloop.c
diff -u src/sys/netcan/if_canloop.c:1.2 src/sys/netcan/if_canloop.c:1.3
--- src/sys/netcan/if_canloop.c:1.2 Sat May 27 21:02:56 2017
+++ src/sys/netcan/if_canloop.c Thu Nov 16 03:07:18 2017
@@ -1,4 +1,4 @@
-/* $NetBSD: if_canloop.c,v 1.2 2017/05/27 21:02:56 bouyer Exp $ */
+/* $NetBSD: if_canloop.c,v 1.3 2017/11/16 03:07:18 ozaki-r Exp $ */
/*-
* Copyright (c) 2017 The NetBSD Foundation, Inc.
@@ -35,7 +35,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_canloop.c,v 1.2 2017/05/27 21:02:56 bouyer Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_canloop.c,v 1.3 2017/11/16 03:07:18 ozaki-r Exp $");
#ifdef _KERNEL_OPT
#include "opt_can.h"
@@ -112,7 +112,7 @@ canloop_clone_create(struct if_clone *if
if_initname(ifp, ifc->ifc_name, unit);
ifp->if_flags = IFF_LOOPBACK | IFF_RUNNING;
- ifp->if_extflags = IFEF_OUTPUT_MPSAFE;
+ ifp->if_extflags = IFEF_MPSAFE;
ifp->if_ioctl = canloop_ioctl;
ifp->if_start = canloop_ifstart;
can_ifattach(ifp);
Index: src/sys/netinet/ip_carp.c
diff -u src/sys/netinet/ip_carp.c:1.91 src/sys/netinet/ip_carp.c:1.92
--- src/sys/netinet/ip_carp.c:1.91 Mon Oct 23 09:31:18 2017
+++ src/sys/netinet/ip_carp.c Thu Nov 16 03:07:18 2017
@@ -1,4 +1,4 @@
-/* $NetBSD: ip_carp.c,v 1.91 2017/10/23 09:31:18 msaitoh Exp $ */
+/* $NetBSD: ip_carp.c,v 1.92 2017/11/16 03:07:18 ozaki-r Exp $ */
/* $OpenBSD: ip_carp.c,v 1.113 2005/11/04 08:11:54 mcbride Exp $ */
/*
@@ -33,7 +33,7 @@
#endif
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ip_carp.c,v 1.91 2017/10/23 09:31:18 msaitoh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ip_carp.c,v 1.92 2017/11/16 03:07:18 ozaki-r Exp $");
/*
* TODO:
@@ -880,7 +880,6 @@ carp_clone_create(struct if_clone *ifc,
/* Overwrite ethernet defaults */
ifp->if_type = IFT_CARP;
ifp->if_output = carp_output;
- ifp->if_extflags &= ~IFEF_OUTPUT_MPSAFE;
if_register(ifp);
return (0);