Skip to content

Commit abd3c48

Browse files
committed
Cosmetic / low-impact changes in dummy kernel interface feature
1: When VLAN is configured we only add the VF MAC to the final interface, and not for the underlay 2: Proper sysctl settings are now manually applied on the underlay dummy as well (i.e. IPv6 ON/OFF)
1 parent 024d480 commit abd3c48

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

Diff for: pkg/danmep/ep.go

+5-1
Original file line numberDiff line numberDiff line change
@@ -302,11 +302,15 @@ func createDummyInterface(ep *danmtypes.DanmEp, dnet *danmtypes.DanmNet) error {
302302
return errors.New("cannot add PCI ID alias to dummy interface for DPDK because:" + err.Error())
303303
}
304304
} else {
305-
//To convey VLAN ID assigment we create a VLAN on top of the dummy, and tag that with the desired final iface name
305+
//To convey VLAN ID assigment we create a VLAN on top of the dummy, and tag that with the desired final iface name
306306
err = netlink.LinkSetUp(dummy)
307307
if err != nil {
308308
return errors.New("cannot set dummy link UP because:" + err.Error())
309309
}
310+
//Sysctl setting during post-process phase are only applied on the VLAN interface in this case, so need to call this manually for the underlying dummy
311+
dummyEp := ep.DeepCopy()
312+
dummyEp.Spec.Iface.Name = ep.ObjectMeta.Name[0:14]
313+
err = setDanmEpSysctls(dummyEp)
310314
iface, err := netlink.LinkByName(origDummyName)
311315
if err != nil {
312316
return errors.New("cannot find freshly created dummy interface because:" + err.Error())

0 commit comments

Comments
 (0)