If supported by kernel and iproute, VxLAN header will include the mark with group policy context. The test performs with and without gbp option.
Signed-off-by: Alexey Kodanev <alexey.koda...@oracle.com> --- testcases/network/virt/vxlan03.sh | 41 ++++++++++++++++++++++++------------ 1 files changed, 27 insertions(+), 14 deletions(-) diff --git a/testcases/network/virt/vxlan03.sh b/testcases/network/virt/vxlan03.sh index 033d801..14524d4 100755 --- a/testcases/network/virt/vxlan03.sh +++ b/testcases/network/virt/vxlan03.sh @@ -60,24 +60,37 @@ if [ -z $ip_local -o -z $ip_remote ]; then tst_brkm TBROK "you must specify IP address" fi -tst_resm TINFO "networks with the same VNI must work" -# VNI is 24 bits long, so max value, which is not reserved, is 0xFFFFFE -res="TPASS" +opts="dstport 0,dstport 0 gbp" -if [ "$vxlan_dst_addr" != 'uni' -a $vxlan_dst_addr != 'multi' ]; then - tst_brkm TBROK "wrong destination address, can be 'uni' or 'multi'" -fi +for n in $(seq 1 2); do + params="$(echo $opts | cut -d',' -f$n)" + + virt_add ltp_v0 id 0 $params > /dev/null 2>&1 + if [ $? -ne 0 ]; then + tst_resm TCONF "iproute or kernel doesn't support '$params'" + continue + fi + ROD_SILENT "ip li delete ltp_v0" + + tst_resm TINFO "networks with the same VNI must work" + # VNI is 24 bits long, so max value, which is not reserved, is 0xFFFFFE + res="TPASS" + + if [ "$vxlan_dst_addr" != 'uni' -a $vxlan_dst_addr != 'multi' ]; then + tst_brkm TBROK "wrong dst address, can be 'uni' or 'multi'" + fi -vxlan_setup_subnet_$vxlan_dst_addr "0xFFFFFE" "0xFFFFFE" -vxlan_compare_netperf || res="TFAIL" + vxlan_setup_subnet_$vxlan_dst_addr "0xFFFFFE" "0xFFFFFE" + vxlan_compare_netperf || res="TFAIL" -tst_resm $res "done" + tst_resm $res "done" -tst_resm TINFO "different VNI shall not work together" -res="TPASS" -vxlan_setup_subnet_$vxlan_dst_addr "0xFFFFFE" "0xFFFFFD" -vxlan_compare_netperf && res="TFAIL" + tst_resm TINFO "different VNI shall not work together" + res="TPASS" + vxlan_setup_subnet_$vxlan_dst_addr "0xFFFFFE" "0xFFFFFD" + vxlan_compare_netperf && res="TFAIL" -tst_resm $res "done" + tst_resm $res "done" +done tst_exit -- 1.7.1 ------------------------------------------------------------------------------ Don't Limit Your Business. Reach for the Cloud. GigeNET's Cloud Solutions provide you with the tools and support that you need to offload your IT needs and focus on growing your business. Configured For All Businesses. Start Your Cloud Today. https://www.gigenetcloud.com/ _______________________________________________ Ltp-list mailing list Ltp-list@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/ltp-list