• Geliang Tang's avatar
    selftests: mptcp: sockopt: print every test result · fd959262
    Geliang Tang authored
    Only total test results are printed out in mptcp_sockopt.sh:
    
    PASS: all packets had packet mark set
    PASS: SOL_MPTCP getsockopt has expected information
    PASS: TCP_INQ cmsg/ioctl -t tcp
    PASS: TCP_INQ cmsg/ioctl -6 -t tcp
    PASS: TCP_INQ cmsg/ioctl -r tcp
    PASS: TCP_INQ cmsg/ioctl -6 -r tcp
    PASS: TCP_INQ cmsg/ioctl -r tcp -t tcp
    
    They mismatch with the test results:
    
    ok 1 - mptcp_sockopt: mark ipv4
    ok 2 - mptcp_sockopt: transfer ipv4
    ok 3 - mptcp_sockopt: mark ipv6
    ok 4 - mptcp_sockopt: transfer ipv6
    ok 5 - mptcp_sockopt: sockopt v4
    ok 6 - mptcp_sockopt: sockopt v6
    ok 7 - mptcp_sockopt: TCP_INQ: -t tcp
    ok 8 - mptcp_sockopt: TCP_INQ: -6 -t tcp
    ok 9 - mptcp_sockopt: TCP_INQ: -r tcp
    ok 10 - mptcp_sockopt: TCP_INQ: -6 -r tcp
    ok 11 - mptcp_sockopt: TCP_INQ: -r tcp -t tcp
    
    'mptcp_sockopt.sh' now display more detailed results + why (what you had
    in a former patch from v6, merged here). It no longer displays 'PASS:',
    because it is duplicated info now that the detailed are displayed:
    
    Transfer v4                                       [ OK ]
    Mark v4                                           [ OK ]
    Transfer v6                                       [ OK ]
    Mark v6                                           [ OK ]
    SOL_MPTCP sockopt v4                              [ OK ]
    SOL_MPTCP sockopt v6                              [ OK ]
    TCP_INQ cmsg/ioctl -t tcp                         [ OK ]
    TCP_INQ cmsg/ioctl -6 -t tcp                      [ OK ]
    TCP_INQ cmsg/ioctl -r tcp                         [ OK ]
    TCP_INQ cmsg/ioctl -6 -r tcp                      [ OK ]
    TCP_INQ cmsg/ioctl -r tcp -t tcp                  [ OK ]
    
    Also fix the TAP output:
    
    ok 1 - mptcp_sockopt: transfer ipv4
    ok 2 - mptcp_sockopt: mark ipv4
    ok 3 - mptcp_sockopt: transfer ipv6
    ok 4 - mptcp_sockopt: mark ipv6
    ok 5 - mptcp_sockopt: sockopt v4
    ok 6 - mptcp_sockopt: sockopt v6
    ok 7 - mptcp_sockopt: TCP_INQ: -t tcp
    ok 8 - mptcp_sockopt: TCP_INQ: -6 -t tcp
    ok 9 - mptcp_sockopt: TCP_INQ: -r tcp
    ok 10 - mptcp_sockopt: TCP_INQ: -6 -r tcp
    ok 11 - mptcp_sockopt: TCP_INQ: -r tcp -t tcp
    Signed-off-by: default avatarGeliang Tang <tanggeliang@kylinos.cn>
    Reviewed-by: default avatarMatthieu Baerts (NGI0) <matttbe@kernel.org>
    Signed-off-by: default avatarMatthieu Baerts (NGI0) <matttbe@kernel.org>
    Link: https://lore.kernel.org/r/20240308-upstream-net-next-20240308-selftests-mptcp-unification-v1-4-4f42c347b653@kernel.orgSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
    fd959262
mptcp_sockopt.sh 6.63 KB