@@ -2785,23 +2785,16 @@ backup_tests()
2785
2785
fi
2786
2786
}
2787
2787
2788
- SUB_ESTABLISHED=10 # MPTCP_EVENT_SUB_ESTABLISHED
2789
- LISTENER_CREATED=15 # MPTCP_EVENT_LISTENER_CREATED
2790
- LISTENER_CLOSED=16 # MPTCP_EVENT_LISTENER_CLOSED
2791
-
2792
- AF_INET=2
2793
- AF_INET6=10
2794
-
2795
2788
verify_listener_events ()
2796
2789
{
2797
2790
local e_type=$2
2798
2791
local e_saddr=$4
2799
2792
local e_sport=$5
2800
2793
local name
2801
2794
2802
- if [ $e_type = $LISTENER_CREATED ]; then
2795
+ if [ $e_type = $MPTCP_LIB_EVENT_LISTENER_CREATED ]; then
2803
2796
name=" LISTENER_CREATED"
2804
- elif [ $e_type = $LISTENER_CLOSED ]; then
2797
+ elif [ $e_type = $MPTCP_LIB_EVENT_LISTENER_CLOSED ]; then
2805
2798
name=" LISTENER_CLOSED "
2806
2799
else
2807
2800
name=" $e_type "
@@ -2856,8 +2849,10 @@ add_addr_ports_tests()
2856
2849
chk_add_nr 1 1 1
2857
2850
chk_rm_nr 1 1 invert
2858
2851
2859
- verify_listener_events $evts_ns1 $LISTENER_CREATED $AF_INET 10.0.2.1 10100
2860
- verify_listener_events $evts_ns1 $LISTENER_CLOSED $AF_INET 10.0.2.1 10100
2852
+ verify_listener_events $evts_ns1 $MPTCP_LIB_EVENT_LISTENER_CREATED \
2853
+ $MPTCP_LIB_AF_INET 10.0.2.1 10100
2854
+ verify_listener_events $evts_ns1 $MPTCP_LIB_EVENT_LISTENER_CLOSED \
2855
+ $MPTCP_LIB_AF_INET 10.0.2.1 10100
2861
2856
kill_events_pids
2862
2857
fi
2863
2858
@@ -3463,11 +3458,11 @@ userspace_tests()
3463
3458
userspace_pm_chk_get_addr " ${ns1} " " 10" " id 10 flags signal 10.0.2.1"
3464
3459
userspace_pm_chk_get_addr " ${ns1} " " 20" " id 20 flags signal 10.0.3.1"
3465
3460
userspace_pm_rm_addr $ns1 10
3466
- userspace_pm_rm_sf $ns1 " ::ffff:10.0.2.1" $SUB_ESTABLISHED
3461
+ userspace_pm_rm_sf $ns1 " ::ffff:10.0.2.1" $MPTCP_LIB_EVENT_SUB_ESTABLISHED
3467
3462
userspace_pm_chk_dump_addr " ${ns1} " \
3468
3463
" id 20 flags signal 10.0.3.1" " after rm_addr 10"
3469
3464
userspace_pm_rm_addr $ns1 20
3470
- userspace_pm_rm_sf $ns1 10.0.3.1 $SUB_ESTABLISHED
3465
+ userspace_pm_rm_sf $ns1 10.0.3.1 $MPTCP_LIB_EVENT_SUB_ESTABLISHED
3471
3466
userspace_pm_chk_dump_addr " ${ns1} " " " " after rm_addr 20"
3472
3467
chk_rm_nr 2 2 invert
3473
3468
chk_mptcp_info subflows 0 subflows 0
@@ -3494,7 +3489,7 @@ userspace_tests()
3494
3489
" subflow"
3495
3490
userspace_pm_chk_get_addr " ${ns2} " " 20" " id 20 flags subflow 10.0.3.2"
3496
3491
userspace_pm_rm_addr $ns2 20
3497
- userspace_pm_rm_sf $ns2 10.0.3.2 $SUB_ESTABLISHED
3492
+ userspace_pm_rm_sf $ns2 10.0.3.2 $MPTCP_LIB_EVENT_SUB_ESTABLISHED
3498
3493
userspace_pm_chk_dump_addr " ${ns2} " \
3499
3494
" " \
3500
3495
" after rm_addr 20"
0 commit comments