Module Name: src
Committed By: yamaguchi
Date: Fri Nov 12 05:56:54 UTC 2021
Modified Files:
src/sys/net/lagg: if_lagg.c
Log Message:
Configure vlan to an added interface after setting ifnet::if_lagg
The configuration uses ioctl of the interface, and the ioctl
for port (lagg_port_ioctl) needs ifnet:::if_lagg setting.
To generate a diff of this commit:
cvs rdiff -u -r1.24 -r1.25 src/sys/net/lagg/if_lagg.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/net/lagg/if_lagg.c
diff -u src/sys/net/lagg/if_lagg.c:1.24 src/sys/net/lagg/if_lagg.c:1.25
--- src/sys/net/lagg/if_lagg.c:1.24 Fri Nov 12 05:48:58 2021
+++ src/sys/net/lagg/if_lagg.c Fri Nov 12 05:56:54 2021
@@ -1,4 +1,4 @@
-/* $NetBSD: if_lagg.c,v 1.24 2021/11/12 05:48:58 yamaguchi Exp $ */
+/* $NetBSD: if_lagg.c,v 1.25 2021/11/12 05:56:54 yamaguchi Exp $ */
/*
* Copyright (c) 2005, 2006 Reyk Floeter <[email protected]>
@@ -20,7 +20,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_lagg.c,v 1.24 2021/11/12 05:48:58 yamaguchi Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_lagg.c,v 1.25 2021/11/12 05:56:54 yamaguchi Exp $");
#ifdef _KERNEL_OPT
#include "opt_inet.h"
@@ -2472,13 +2472,13 @@ lagg_port_setup(struct lagg_softc *sc,
if (error != 0)
goto teardown_lladdr;
- lagg_port_syncmulti(sc, lp);
- lagg_port_syncvlan(sc, lp);
-
atomic_store_release(&ifp_port->if_lagg, (void *)lp);
SIMPLEQ_INSERT_TAIL(&sc->sc_ports, lp, lp_entry);
sc->sc_nports++;
+ lagg_port_syncmulti(sc, lp);
+ lagg_port_syncvlan(sc, lp);
+
if (stopped) {
error = ifp_port->if_init(ifp_port);
if (error != 0)