[LTP] [PATCH 3/5] network/virt: skip setting neighbour table if tunnel doesn't have hwaddr
Alexey Kodanev
alexey.kodanev@oracle.com
Thu Oct 15 14:20:54 CEST 2020
Signed-off-by: Alexey Kodanev <alexey.kodanev@oracle.com>
---
testcases/network/virt/virt_lib.sh | 11 +++++++----
1 file changed, 7 insertions(+), 4 deletions(-)
diff --git a/testcases/network/virt/virt_lib.sh b/testcases/network/virt/virt_lib.sh
index 80b9bcc90..f62120347 100644
--- a/testcases/network/virt/virt_lib.sh
+++ b/testcases/network/virt/virt_lib.sh
@@ -229,10 +229,13 @@ virt_minimize_timeout()
local mac_loc="$(cat /sys/class/net/ltp_v0/address)"
local mac_rmt="$(tst_rhost_run -c 'cat /sys/class/net/ltp_v0/address')"
- ROD_SILENT "ip ne replace $ip_virt_remote lladdr \
- $mac_rmt nud permanent dev ltp_v0"
- tst_rhost_run -s -c "ip ne replace $ip_virt_local lladdr \
- $mac_loc nud permanent dev ltp_v0"
+ if [ "$mac_loc" ]; then
+ ROD_SILENT "ip ne replace $ip_virt_remote lladdr \
+ $mac_rmt nud permanent dev ltp_v0"
+ tst_rhost_run -s -c "ip ne replace $ip_virt_local lladdr \
+ $mac_loc nud permanent dev ltp_v0"
+ fi
+
virt_tcp_syn=$(sysctl -n net.ipv4.tcp_syn_retries)
ROD sysctl -q net.ipv4.tcp_syn_retries=1
}
--
2.20.1
More information about the ltp
mailing list