From 28727e997212e809c1499e31fcbad527bcf44586 Mon Sep 17 00:00:00 2001 From: Trekkie Coder Date: Mon, 1 Apr 2024 13:22:07 +0900 Subject: [PATCH] gh-613 Fixed certain misleading logs --- loxilb-ebpf | 2 +- loxinet/dpebpf_linux.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/loxilb-ebpf b/loxilb-ebpf index 1d59b191..69f670d1 160000 --- a/loxilb-ebpf +++ b/loxilb-ebpf @@ -1 +1 @@ -Subproject commit 1d59b191356414990c82ab35e25c52e4def19a4a +Subproject commit 69f670d14f900a72cc0024c530fed974dcfb78ed diff --git a/loxinet/dpebpf_linux.go b/loxinet/dpebpf_linux.go index 6641961b..5bf92d25 100644 --- a/loxinet/dpebpf_linux.go +++ b/loxinet/dpebpf_linux.go @@ -357,12 +357,12 @@ func (e *DpEbpfH) DpEbpfUnInit() { tk.LogIt(tk.LogInfo, "ebpf unload - %s\n", intf.Name) ifStr := C.CString(intf.Name) section := C.CString(string(C.TC_LL_SEC_DEFAULT)) - if e.RssEn { + C.llb_dp_link_attach(ifStr, section, C.LL_BPF_MOUNT_TC, 1) + if e.RssEn || intf.Name == "llb0" { xSection := C.CString(string(C.XDP_LL_SEC_DEFAULT)) C.llb_dp_link_attach(ifStr, xSection, C.LL_BPF_MOUNT_XDP, 1) C.free(unsafe.Pointer(xSection)) } - C.llb_dp_link_attach(ifStr, section, C.LL_BPF_MOUNT_TC, 1) C.free(unsafe.Pointer(ifStr)) C.free(unsafe.Pointer(section)) }