FreeBSD Bugzilla – Attachment 257869 Details for
Bug 243712
vxlan setup mtu according parent interface when cloning
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch for that feature
if_vxlan_clone.patch (text/plain), 1.01 KB, created by
Mark Linimon
on 2025-02-25 04:49:37 UTC
(
hide
)
Description:
Patch for that feature
Filename:
MIME Type:
Creator:
Mark Linimon
Created:
2025-02-25 04:49:37 UTC
Size:
1.01 KB
patch
obsolete
>--- sys/net/if_vxlan.c 2019-11-19 13:57:56.046105000 +0200 >+++ sys/net/if_vxlan.c 2019-11-19 14:02:21.057692000 +0200 >@@ -2725,8 +2725,9 @@ > vxlan_clone_create(struct if_clone *ifc, int unit, caddr_t params) > { > struct vxlan_softc *sc; >- struct ifnet *ifp; >+ struct ifnet *ifp, *ifpp; > struct ifvxlanparam vxlp; >+ const short r4hdrs = 100; /* Reasonable standard offset for MTU from vxlandev iface */ > int error; > > sc = malloc(sizeof(struct vxlan_softc), M_VXLAN, M_WAITOK | M_ZERO); >@@ -2776,6 +2777,22 @@ > > ifp->if_baudrate = 0; > ifp->if_hdrlen = 0; >+ >+ if (vxlp.vxlp_with & VXLAN_PARAM_WITH_MULTICAST_IF) { >+ ifpp = ifunit_ref(sc->vxl_mc_ifname); >+ if (ifpp == NULL) { >+ if_printf(sc->vxl_ifp, "multicast interface %s does " >+ "not exist\n", sc->vxl_mc_ifname); >+ goto fail; >+ } >+ if (ifpp->if_mtu <= r4hdrs) { >+ if_printf(sc->vxl_ifp, "multicast interface %s does " >+ "not have sufficient MTU\n", sc->vxl_mc_ifname); >+ goto fail; >+ } >+ >+ ifp->if_mtu = ifpp->if_mtu - r4hdrs; >+ } > > return (0); >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 243712
:
211174
| 257869