In iproute2 whose version is earlier than v2.6.34, ip command doesn't support tuntap object. This leads to the case (netns_netlink.c) failure with TFAIL status. It is not suitable, so fix this case' exit status with TCONF in the above condition.
Signed-off-by: Xing Gu <gux.f...@cn.fujitsu.com> --- testcases/kernel/containers/netns/netns_netlink.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/testcases/kernel/containers/netns/netns_netlink.c b/testcases/kernel/containers/netns/netns_netlink.c index 08caa98..d271124 100644 --- a/testcases/kernel/containers/netns/netns_netlink.c +++ b/testcases/kernel/containers/netns/netns_netlink.c @@ -47,6 +47,8 @@ #define MAX_TRIES 1000 +#define IP_TUNTAP_MIN_VER 100519 + char *TCID = "netns_netlink"; int TST_TOTAL = 1; struct tst_checkpoint checkpoint; @@ -60,6 +62,10 @@ static void cleanup(void) static void setup(void) { tst_require_root(NULL); + if (check_iproute(IP_TUNTAP_MIN_VER) == -1) { + tst_brkm(TCONF, NULL, + "ip command in iproute tools do not support tuntap object"); + } check_netns(); tst_tmpdir(); TST_CHECKPOINT_CREATE(&checkpoint); -- 1.9.3 ------------------------------------------------------------------------------ _______________________________________________ Ltp-list mailing list Ltp-list@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/ltp-list