From cf5433c6fb6fd2e1411f6645de143bf7de30085a Mon Sep 17 00:00:00 2001 From: bol-van Date: Tue, 1 Nov 2022 12:30:00 +0300 Subject: [PATCH] nft hw offload optimize --- common/nft.sh | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/common/nft.sh b/common/nft.sh index 9cde7b5..aa7c8ab 100644 --- a/common/nft.sh +++ b/common/nft.sh @@ -343,13 +343,10 @@ flush set inet $ZAPRET_NFT_TABLE lanif" # bridge members must be added instead of the bridge itself # some members may not support hw offload. example : lan1 lan2 lan3 support, wlan0 wlan1 - not devs=$(resolve_lower_devices $i) - [ -n "$devs" ] && { - # select devices that support offload - devs=$(nft_hw_offload_find_supported $devs) - for j in $devs; do - nft_create_or_update_flowtable 'offload' $j - done - } + for j in $devs; do + # do not display error if addition failed + nft_create_or_update_flowtable 'offload' $j 2>/dev/null + done fi done ;;