From patchwork Mon Dec 12 11:40:26 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Yang Xu \\(Fujitsu\\)" X-Patchwork-Id: 1714913 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.linux.it (client-ip=2001:1418:10:5::2; helo=picard.linux.it; envelope-from=ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=fujitsu.com header.i=@fujitsu.com header.a=rsa-sha256 header.s=170520fj header.b=bwN82JGh; dkim-atps=neutral Received: from picard.linux.it (picard.linux.it [IPv6:2001:1418:10:5::2]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NVymm27K5z240J for ; Mon, 12 Dec 2022 21:39:35 +1100 (AEDT) Received: from picard.linux.it (localhost [IPv6:::1]) by picard.linux.it (Postfix) with ESMTP id C7A9B3CBE42 for ; Mon, 12 Dec 2022 11:39:31 +0100 (CET) X-Original-To: ltp@lists.linux.it Delivered-To: ltp@picard.linux.it Received: from in-6.smtp.seeweb.it (in-6.smtp.seeweb.it [217.194.8.6]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384)) (No client certificate requested) by picard.linux.it (Postfix) with ESMTPS id 630843CB6DC for ; Mon, 12 Dec 2022 11:39:29 +0100 (CET) Received: from mail1.bemta34.messagelabs.com (mail1.bemta34.messagelabs.com [195.245.231.3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by in-6.smtp.seeweb.it (Postfix) with ESMTPS id 2595014001FB for ; Mon, 12 Dec 2022 11:39:27 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fujitsu.com; s=170520fj; t=1670841567; i=@fujitsu.com; bh=AkSgxf27TqJKUi7ACmS2IsqgYkcf7Ttx/ulEFpPxDvo=; h=From:To:CC:Subject:Date:Message-ID:MIME-Version:Content-Type; b=bwN82JGhrWxvgtK4WbH4gR/D8yD6RK2dxubiUH5srUC2DshPRd809i5awLvcX183l 5myxUPe49vXlq1ob5Kt7OQ1wm2WWy86HGCA5bn07dv2pE+Y9t40xdEw+xVOljIMFOm sor57jgRUii5zOlRuWPKzr5oBJq1dwkIWbrWjp6QLKan1Py5W47dIhtizHl+BNlDh9 mLqxkcBdku1l/1kF4lzno2bWe0c1L7WDJ3J0MndQcOuGRyklKRYlYslWPjU7ToK1WC VWp7WImQMnQCLIr3J8JntSwTGYaU9XFQqkfINsEarLsmqCv1n7F+Y4BE19PntaSRsk 5ihqUYlgN9wGA== X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFlrPIsWRWlGSWpSXmKPExsViZ8ORqHuPZXq ywd4P2hYrvu9gdGD02Pd7HWsAYxRrZl5SfkUCa8bcfbuYCy4LV6w6toSlgfGOQBcjF4eQwFlG iQmPTrFBOAeYJDpfbGOBcPYwSjz4vgwow8nBJqAp8axzATOILSIgIdHR8JYdxGYWUJdYPukXE 4gtLGArMb/pMyuIzSKgKnFt1nEWEJtXwEOi78xfsBoJAQWJKQ/fM0PEBSVOznzCAjFHQuLgix fMEDWKEpc6vjFC2BUSs2a1QfWqSVw9t4l5AiP/LCTts5C0L2BkWsVoVpxaVJZapGtoqZdUlJm eUZKbmJmjl1ilm6iXWqpbnlpcomukl1herJdaXKxXXJmbnJOil5dasokRGI4pxYrrdjBOX/ZH 7xCjJAeTkihv+p9pyUJ8SfkplRmJxRnxRaU5qcWHGGU4OJQkeAO+AOUEi1LTUyvSMnOAsQGTl uDgURLhPcY0PVmIt7ggMbc4Mx0idYpRUUqcV4gZKCEAksgozYNrg8XjJUZZKWFeRgYGBiGegt Si3MwSVPlXjOIcjErCvNtBxvNk5pXATX8FtJgJaHHUy6kgi0sSEVJSDUx2U78/33v/6bMZFwz nvq7zftR4pr/PY1+RsdeX5JuPvdzM7zLG7a/7P8Ppdn2U4swNG3Smiy3byj3jc2e92vQT1rPb NE2P+TzKKsidebZq9dwPdgJThDkmVNW1bH2TdPJVS9/buTtu/biZM9eP9ypjHW9A3lZu/9yy9 gmVQevMm6oTOPpCMnalHolzdJFry2Y99P+c6V3D6wITe2V7nnXY/f9ZNNNz7x9//YlP+db8Vt y54VP4iZW3k1q43b5OT2Zk9Eu+0j9Bg7nhlfIahr3dyjs1nmhr1khdPHXZVqZ2d3vNoUu6t1i n/zYwt3vslng46KXucqE/y4/cVHM9fmGrF59Qjs8M0SnifLolBw8osRRnJBpqMRcVJwIA3mty gUIDAAA= X-Env-Sender: xuyang2018.jy@fujitsu.com X-Msg-Ref: server-5.tower-571.messagelabs.com!1670841566!290753!1 X-Originating-IP: [62.60.8.97] X-SYMC-ESS-Client-Auth: outbound-route-from=pass X-StarScan-Received: X-StarScan-Version: 9.101.2; banners=-,-,- X-VirusChecked: Checked Received: (qmail 1427 invoked from network); 12 Dec 2022 10:39:26 -0000 Received: from unknown (HELO n03ukasimr01.n03.fujitsu.local) (62.60.8.97) by server-5.tower-571.messagelabs.com with ECDHE-RSA-AES256-GCM-SHA384 encrypted SMTP; 12 Dec 2022 10:39:26 -0000 Received: from n03ukasimr01.n03.fujitsu.local (localhost [127.0.0.1]) by n03ukasimr01.n03.fujitsu.local (Postfix) with ESMTP id 6979C100192 for ; Mon, 12 Dec 2022 10:39:26 +0000 (GMT) Received: from R01UKEXCASM126.r01.fujitsu.local (R01UKEXCASM126 [10.183.43.178]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by n03ukasimr01.n03.fujitsu.local (Postfix) with ESMTPS id 5D362100191 for ; Mon, 12 Dec 2022 10:39:26 +0000 (GMT) Received: from localhost.localdomain (10.167.220.84) by R01UKEXCASM126.r01.fujitsu.local (10.183.43.178) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Mon, 12 Dec 2022 10:39:24 +0000 From: Yang Xu To: Date: Mon, 12 Dec 2022 19:40:26 +0800 Message-ID: <1670845229-1981-1-git-send-email-xuyang2018.jy@fujitsu.com> X-Mailer: git-send-email 1.8.3.1 MIME-Version: 1.0 X-Originating-IP: [10.167.220.84] X-ClientProxiedBy: G08CNEXCHPEKD07.g08.fujitsu.local (10.167.33.80) To R01UKEXCASM126.r01.fujitsu.local (10.183.43.178) X-Virus-Scanned: clamav-milter 0.102.4 at in-6.smtp.seeweb.it X-Virus-Status: Clean X-Spam-Status: No, score=0.1 required=7.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=disabled version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on in-6.smtp.seeweb.it Subject: [LTP] [PATCH v1 1/4] lib/tst_kvercmp: Remove old distnames X-BeenThere: ltp@lists.linux.it X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux Test Project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it Sender: "ltp" Our travis-ci has dropped or never used them, they are useless. So delete. Signed-off-by: Yang Xu Acked-by: Petr Vorel Acked-by: Jan Stancek --- lib/tst_kvercmp.c | 12 ------------ testcases/kernel/syscalls/inotify/inotify04.c | 13 +++---------- .../kernel/tracing/dynamic_debug/dynamic_debug01.sh | 3 +-- 3 files changed, 4 insertions(+), 24 deletions(-) diff --git a/lib/tst_kvercmp.c b/lib/tst_kvercmp.c index dc0daa746..a01b4332b 100644 --- a/lib/tst_kvercmp.c +++ b/lib/tst_kvercmp.c @@ -134,18 +134,6 @@ const char *tst_kvcmp_distname(const char *kver) char *ret = distname; char *p = distname; - if (strstr(kver, ".el5uek")) - return "OL5UEK"; - - if (strstr(kver, ".el5")) - return "RHEL5"; - - if (strstr(kver, ".el6uek")) - return "OL6UEK"; - - if (strstr(kver, ".el6")) - return "RHEL6"; - if (strstr(kver, ".el7")) return "RHEL7"; diff --git a/testcases/kernel/syscalls/inotify/inotify04.c b/testcases/kernel/syscalls/inotify/inotify04.c index fb9f5c293..c4fce399c 100644 --- a/testcases/kernel/syscalls/inotify/inotify04.c +++ b/testcases/kernel/syscalls/inotify/inotify04.c @@ -50,11 +50,6 @@ char event_buf[EVENT_BUF_LEN]; int fd_notify, reap_wd_file, reap_wd_dir, wd_dir, wd_file; -static struct tst_kern_exv kvers[] = { - { "RHEL5", "2.6.18-132" }, - { NULL, NULL }, -}; - static void cleanup(void) { if (reap_wd_dir && myinotify_rm_watch(fd_notify, wd_dir) == -1) @@ -110,11 +105,9 @@ void verify_inotify(void) * This isn't well documented in inotify(7), but it's intuitive if you * understand how Unix works. */ - if (tst_kvercmp2(2, 6, 25, kvers) >= 0) { - event_set[test_cnt].mask = IN_ATTRIB; - strcpy(event_set[test_cnt].name, ""); - test_cnt++; - } + event_set[test_cnt].mask = IN_ATTRIB; + strcpy(event_set[test_cnt].name, ""); + test_cnt++; event_set[test_cnt].mask = IN_DELETE_SELF; strcpy(event_set[test_cnt].name, TEST_FILE); diff --git a/testcases/kernel/tracing/dynamic_debug/dynamic_debug01.sh b/testcases/kernel/tracing/dynamic_debug/dynamic_debug01.sh index 4b159517b..ca6c840b1 100755 --- a/testcases/kernel/tracing/dynamic_debug/dynamic_debug01.sh +++ b/testcases/kernel/tracing/dynamic_debug/dynamic_debug01.sh @@ -59,8 +59,7 @@ setup() tst_brk TBROK "Unable to find $DEBUGFS_CONTROL" fi - # Both patches with changes were backported to RHEL6 kernel 2.6.32-547 - if tst_kvcmp -ge '3.4 RHEL6:2.6.32-547' ; then + if tst_kvcmp -ge 3.4 ; then NEW_INTERFACE=1 EMPTY_FLAG="=_" fi From patchwork Mon Dec 12 11:40:27 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Yang Xu \\(Fujitsu\\)" X-Patchwork-Id: 1714914 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.linux.it (client-ip=2001:1418:10:5::2; helo=picard.linux.it; envelope-from=ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=fujitsu.com header.i=@fujitsu.com header.a=rsa-sha256 header.s=170520fj header.b=WKT+jZG9; dkim-atps=neutral Received: from picard.linux.it (picard.linux.it [IPv6:2001:1418:10:5::2]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NVymy3Hhgz240J for ; Mon, 12 Dec 2022 21:39:46 +1100 (AEDT) Received: from picard.linux.it (localhost [IPv6:::1]) by picard.linux.it (Postfix) with ESMTP id 75B9D3CBE64 for ; Mon, 12 Dec 2022 11:39:42 +0100 (CET) X-Original-To: ltp@lists.linux.it Delivered-To: ltp@picard.linux.it Received: from in-5.smtp.seeweb.it (in-5.smtp.seeweb.it [IPv6:2001:4b78:1:20::5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384)) (No client certificate requested) by picard.linux.it (Postfix) with ESMTPS id 5B7643CBE65 for ; Mon, 12 Dec 2022 11:39:33 +0100 (CET) Received: from mail1.bemta32.messagelabs.com (mail1.bemta32.messagelabs.com [195.245.230.66]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by in-5.smtp.seeweb.it (Postfix) with ESMTPS id 408656005E4 for ; Mon, 12 Dec 2022 11:39:32 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fujitsu.com; s=170520fj; t=1670841571; i=@fujitsu.com; bh=GWt/OC1D9S/PdrF9iBPumnXzQlpRThgUgYsInzfOl6U=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=WKT+jZG9RBCTtgVzpUgta1Ov+T2pq3GB4m6lzW8YL9J+wKQrChGyDEt7EwvqsF7j/ /4D8/s5fRoczKJaFpx3rUZENYmj10Ir6xi9WXe92OUILN7bJFYVOhxdyrQ+3mMjPww +wPBbx3bHDaSHplqc2bx5XGs6ytrEI895ek7ChVOmPcLMU1qQdi6hf/BQmz92Xf5xw edzeS7CUcsrac7niq9T/lIk+yjT3GAahJ3TSoNiEt7hxRdFTBoJ+RcRDFqK4goI/Q0 LwA2BoogMa8+ub5+8JXl1oC9XeHId8HhkaX4J4F7bq4vclbrqXtDpNyE02oXm5vkjp G+DrKy8lmzqgQ== X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrJIsWRWlGSWpSXmKPExsViZ8MxSfcxy/R kg8OfWSxWfN/B6MDose/3OtYAxijWzLyk/IoE1oz1156zFMyZw1jR/eMTSwPjwXbGLkYuDiGB s4wSG1edYoJwDjBJ9HxYxQLh7AHKzDrL2sXIycEmoCnxrHMBM4gtIiAh0dHwlh3EZhZQl1g+6 RdQNweHsICdxMzT4iBhFgFViSvr3jKB2LwCHhLNqyBaJQQUJKY8fA9mcwp4Sny7ewlsvBBQza pZM1gg6gUlTs58wgIxXkLi4IsXUL2KEpc6vjFC2BUSs2a1MUHYahJXz21insAoOAtJ+ywk7Qs YmVYxmhanFpWlFuma6SUVZaZnlOQmZuboJVbpJuqlluqWpxaX6BrqJZYX66UWF+sVV+Ym56To 5aWWbGIEhm9KMXvBDsaZy/7oHWKU5GBSEuVN/zMtWYgvKT+lMiOxOCO+qDQntfgQowwHh5IEb 8AXoJxgUWp6akVaZg4wlmDSEhw8SiK8x5imJwvxFhck5hZnpkOkTjEac3z8c3EvM8fU2f/2Mw ux5OXnpUqJ8woxA5UKgJRmlObBDYLF+CVGWSlhXkYGBgYhnoLUotzMElT5V4ziHIxKwrzbQRb yZOaVwO17BXQKE9ApUS+ngpxSkoiQkmpgmvPo+Y5bcr0HDsis3lAdKKmnOjsk5PSM6qar3/IX GTlUbF0onHV96b9/78tCXDl5jVOtf5ZWi5d6VTbM0bKzdBT8scv29Ctd/5cnV52zWJy94UFW5 J/prllOYuUK1yds1f7ybyfD5MLiw5FvP76fUfQlsH++594NHXOvsYR6JWkb2H/6pyqudiYw4s OyzyumWdudqtBbvnzazPaS5qLPuZvtTnkaHbg49YvDAk9Bw25T1v82hiU5U/5v6HxTcnTL27P GNRHTLRbHLb5u/503N2ahDKvcQp9Dr2wDndWby6z5bYU3awc7iiZ/VZq0T4C3f4aEc1PW0cBz pzdf/7vt76IFR29+EJsiVc6VEqn8RYmlOCPRUIu5qDgRAHYB11RsAwAA X-Env-Sender: xuyang2018.jy@fujitsu.com X-Msg-Ref: server-17.tower-587.messagelabs.com!1670841570!310942!1 X-Originating-IP: [62.60.8.146] X-SYMC-ESS-Client-Auth: outbound-route-from=pass X-StarScan-Received: X-StarScan-Version: 9.101.2; banners=-,-,- X-VirusChecked: Checked Received: (qmail 24535 invoked from network); 12 Dec 2022 10:39:31 -0000 Received: from unknown (HELO n03ukasimr02.n03.fujitsu.local) (62.60.8.146) by server-17.tower-587.messagelabs.com with ECDHE-RSA-AES256-GCM-SHA384 encrypted SMTP; 12 Dec 2022 10:39:31 -0000 Received: from n03ukasimr02.n03.fujitsu.local (localhost [127.0.0.1]) by n03ukasimr02.n03.fujitsu.local (Postfix) with ESMTP id A58EC1000D7 for ; Mon, 12 Dec 2022 10:39:30 +0000 (GMT) Received: from R01UKEXCASM126.r01.fujitsu.local (R01UKEXCASM126 [10.183.43.178]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by n03ukasimr02.n03.fujitsu.local (Postfix) with ESMTPS id 982CA1000C1 for ; Mon, 12 Dec 2022 10:39:30 +0000 (GMT) Received: from localhost.localdomain (10.167.220.84) by R01UKEXCASM126.r01.fujitsu.local (10.183.43.178) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Mon, 12 Dec 2022 10:39:28 +0000 From: Yang Xu To: Date: Mon, 12 Dec 2022 19:40:27 +0800 Message-ID: <1670845229-1981-2-git-send-email-xuyang2018.jy@fujitsu.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1670845229-1981-1-git-send-email-xuyang2018.jy@fujitsu.com> References: <1670845229-1981-1-git-send-email-xuyang2018.jy@fujitsu.com> MIME-Version: 1.0 X-Originating-IP: [10.167.220.84] X-ClientProxiedBy: G08CNEXCHPEKD07.g08.fujitsu.local (10.167.33.80) To R01UKEXCASM126.r01.fujitsu.local (10.183.43.178) X-Virus-Scanned: clamav-milter 0.102.4 at in-5.smtp.seeweb.it X-Virus-Status: Clean X-Spam-Status: No, score=0.1 required=7.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=disabled version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on in-5.smtp.seeweb.it Subject: [LTP] [PATCH v1 2/4] shell: Remove old kernel version check X-BeenThere: ltp@lists.linux.it X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux Test Project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it Sender: "ltp" The oldest supported kernel version is 3.10, we don't need these checks. If people need to run these cases on old kernel, please use old release tag. Signed-off-by: Yang Xu --- doc/shell-test-api.txt | 14 +++++----- testcases/commands/mkswap/mkswap01.sh | 7 +---- .../kernel/containers/netns/netns_sysfs.sh | 4 --- .../cgroup/cgroup_regression_test.sh | 9 ------ .../kernel/controllers/cpuset/cpuset_funcs.sh | 9 ------ .../memcg/functional/memcg_limit_in_bytes.sh | 4 --- .../memcg_memsw_limit_in_bytes_test.sh | 6 +--- .../memcg/regression/memcg_regression_test.sh | 4 --- .../kernel/power_management/pm_include.sh | 24 ++++++---------- .../kernel/power_management/runpwtests01.sh | 2 +- .../kernel/power_management/runpwtests02.sh | 2 +- .../kernel/power_management/runpwtests03.sh | 2 +- .../kernel/power_management/runpwtests04.sh | 2 +- .../kernel/power_management/runpwtests05.sh | 11 ++------ .../kernel/power_management/runpwtests06.sh | 8 ++---- .../runpwtests_exclusive01.sh | 11 ++------ .../runpwtests_exclusive02.sh | 8 ++---- .../runpwtests_exclusive03.sh | 11 ++------ .../runpwtests_exclusive04.sh | 2 +- .../runpwtests_exclusive05.sh | 11 ++------ .../security/cap_bound/run_capbounds.sh | 6 ---- .../tracing/dynamic_debug/dynamic_debug01.sh | 16 +++-------- .../ftrace_test/ftrace_regression02.sh | 4 --- .../ftrace_stress/ftrace_trace_clock.sh | 28 ++++--------------- .../ftrace_stress/ftrace_trace_stat.sh | 6 ---- .../multicast/grp-operation/mcast-lib.sh | 1 - testcases/network/virt/virt_lib.sh | 8 ------ 27 files changed, 48 insertions(+), 172 deletions(-) diff --git a/doc/shell-test-api.txt b/doc/shell-test-api.txt index 73c9eff91..367894c2f 100644 --- a/doc/shell-test-api.txt +++ b/doc/shell-test-api.txt @@ -656,14 +656,14 @@ with syntax similar to the shell test command. [source,sh] ------------------------------------------------------------------------------- -# Exit the test if kernel version is older or equal to 2.6.8 -if tst_kvcmp -le 2.6.8; then - tst_brk TCONF "Kernel newer than 2.6.8 is needed" +# Exit the test if kernel version is older or equal to 5.0.0 +if tst_kvcmp -le 5.0.0; then + tst_brk TCONF "Kernel newer than 5.0.0 is needed" fi -# Exit the test if kernel is newer than 3.8 and older than 4.0.1 -if tst_kvcmp -gt 3.8 -a -lt 4.0.1; then - tst_brk TCONF "Kernel must be older than 3.8 or newer than 4.0.1" +# Exit the test if kernel is newer than 3.10 and older than 4.0.1 +if tst_kvcmp -gt 3.10 -a -lt 4.0.1; then + tst_brk TCONF "Kernel must be older than 3.10 or newer than 4.0.1" fi ------------------------------------------------------------------------------- @@ -680,7 +680,7 @@ fi | -o | Does logical or between two expressions |======================================================================= -The format for kernel version has to either be with one dot e.g. '2.6' or with +The format for kernel version has to either be with one dot e.g. '3.10' or with two dots e.g. '4.8.1'. .tst_fs_has_free diff --git a/testcases/commands/mkswap/mkswap01.sh b/testcases/commands/mkswap/mkswap01.sh index fe1695876..e03c46c31 100755 --- a/testcases/commands/mkswap/mkswap01.sh +++ b/testcases/commands/mkswap/mkswap01.sh @@ -51,12 +51,7 @@ mkswap_verify() local pagesize=$PAGE_SIZE fi - if tst_kvcmp -lt "2.6.35" && [ -n "$dev_file" ]; then - tst_res TINFO "Waiting for $dev_file to appear" - tst_sleep 100ms - else - TST_RETRY_FUNC "check_for_file $dev_file" 0 - fi + TST_RETRY_FUNC "check_for_file $dev_file" 0 swapon $swapfile 2>/dev/null diff --git a/testcases/kernel/containers/netns/netns_sysfs.sh b/testcases/kernel/containers/netns/netns_sysfs.sh index 9fc390eaf..179242721 100755 --- a/testcases/kernel/containers/netns/netns_sysfs.sh +++ b/testcases/kernel/containers/netns/netns_sysfs.sh @@ -18,10 +18,6 @@ do_setup() DUMMYDEV_HOST="dummy_test0" DUMMYDEV="dummy_test1" - if tst_kvcmp -lt "2.6.35"; then - tst_brk TCONF "sysfs is not mount namespace aware for kernels older than 2.6.35" - fi - setns_check if [ $? -eq 32 ]; then tst_brk TCONF "setns not supported" diff --git a/testcases/kernel/controllers/cgroup/cgroup_regression_test.sh b/testcases/kernel/controllers/cgroup/cgroup_regression_test.sh index bfa9097ec..d26456b2d 100755 --- a/testcases/kernel/controllers/cgroup/cgroup_regression_test.sh +++ b/testcases/kernel/controllers/cgroup/cgroup_regression_test.sh @@ -16,10 +16,6 @@ do_setup() { mkdir cgroup/ - if tst_kvcmp -lt "2.6.29"; then - tst_brk TCONF ignored "test must be run with kernel 2.6.29 or newer" - fi - if [ ! -f /proc/cgroups ]; then tst_brk TCONF ignored "Kernel does not support for control groups; skipping testcases"; fi @@ -255,11 +251,6 @@ test5() #--------------------------------------------------------------------------- test6() { - if tst_kvcmp -ge "3.0"; then - tst_res TCONF "CONFIG_CGROUP_NS is NOT supported in Kernels >= 3.0" - return - fi - if ! grep -q -w "ns" /proc/cgroups; then tst_res TCONF "CONFIG_CGROUP_NS is NOT enabled" return diff --git a/testcases/kernel/controllers/cpuset/cpuset_funcs.sh b/testcases/kernel/controllers/cpuset/cpuset_funcs.sh index 9939f13a3..87ba7da1f 100755 --- a/testcases/kernel/controllers/cpuset/cpuset_funcs.sh +++ b/testcases/kernel/controllers/cpuset/cpuset_funcs.sh @@ -79,13 +79,6 @@ cpuset_log_error() done < "$1" } -version_check() -{ - if tst_kvcmp -lt "2.6.28"; then - tst_brkm TCONF "kernel is below 2.6.28" - fi -} - ncpus_check() { if [ $NR_CPUS -lt $1 ]; then @@ -150,8 +143,6 @@ check() cpuset_check - version_check - ncpus_check ${1:-2} nnodes_check ${2:-2} diff --git a/testcases/kernel/controllers/memcg/functional/memcg_limit_in_bytes.sh b/testcases/kernel/controllers/memcg/functional/memcg_limit_in_bytes.sh index 77d293329..8ad399a97 100755 --- a/testcases/kernel/controllers/memcg/functional/memcg_limit_in_bytes.sh +++ b/testcases/kernel/controllers/memcg/functional/memcg_limit_in_bytes.sh @@ -88,11 +88,7 @@ test11() test12() { tst_res TINFO "Test invalid memory.limit_in_bytes" - if tst_kvcmp -lt "2.6.31"; then - EXPECT_FAIL echo -1 \> memory.limit_in_bytes - else EXPECT_PASS echo -1 \> memory.limit_in_bytes - fi } test13() diff --git a/testcases/kernel/controllers/memcg/functional/memcg_memsw_limit_in_bytes_test.sh b/testcases/kernel/controllers/memcg/functional/memcg_memsw_limit_in_bytes_test.sh index 96f5360a8..74748a528 100755 --- a/testcases/kernel/controllers/memcg/functional/memcg_memsw_limit_in_bytes_test.sh +++ b/testcases/kernel/controllers/memcg/functional/memcg_memsw_limit_in_bytes_test.sh @@ -56,11 +56,7 @@ test9() ROD echo 10M \> memory.limit_in_bytes - if tst_kvcmp -lt "2.6.31"; then - EXPECT_FAIL echo -1 \> memory.memsw.limit_in_bytes - else - EXPECT_PASS echo -1 \> memory.memsw.limit_in_bytes - fi + EXPECT_PASS echo -1 \> memory.memsw.limit_in_bytes } test10() diff --git a/testcases/kernel/controllers/memcg/regression/memcg_regression_test.sh b/testcases/kernel/controllers/memcg/regression/memcg_regression_test.sh index 94d4e4c00..58759263e 100755 --- a/testcases/kernel/controllers/memcg/regression/memcg_regression_test.sh +++ b/testcases/kernel/controllers/memcg/regression/memcg_regression_test.sh @@ -60,10 +60,6 @@ check_kernel_bug() setup() { - if tst_kvcmp -lt "2.6.30"; then - tst_brk TBROK "Test should be run with kernel 2.6.30 or newer" - fi - cgroup_require "memory" cgroup_version=$(cgroup_get_version "memory") mount_point=$(cgroup_get_mountpoint "memory") diff --git a/testcases/kernel/power_management/pm_include.sh b/testcases/kernel/power_management/pm_include.sh index f3e160445..ad72028c9 100755 --- a/testcases/kernel/power_management/pm_include.sh +++ b/testcases/kernel/power_management/pm_include.sh @@ -15,21 +15,15 @@ cleanup() { fi } -check_kervel_arch() { - # Checking required kernel version and architecture - if tst_kvcmp -lt "2.6.21"; then - tst_brkm TCONF "Kernel version not supported; not " \ - "running testcases" - else - case "$(uname -m)" in - i[4-6]86|x86_64) - ;; - *) - tst_brkm TCONF "Arch not supported; not running " \ - "testcases" - ;; - esac - fi +check_arch() { + case "$(uname -m)" in + i[4-6]86|x86_64) + ;; + *) + tst_brkm TCONF "Arch not supported; not running " \ + "testcases" + ;; + esac } check_config_options() { diff --git a/testcases/kernel/power_management/runpwtests01.sh b/testcases/kernel/power_management/runpwtests01.sh index d470d112e..2caf9eab5 100755 --- a/testcases/kernel/power_management/runpwtests01.sh +++ b/testcases/kernel/power_management/runpwtests01.sh @@ -47,7 +47,7 @@ test_sched_mc() { } # Checking test environment -check_kervel_arch +check_arch # Checking sched_mc sysfs interface multi_socket=$(is_multi_socket) diff --git a/testcases/kernel/power_management/runpwtests02.sh b/testcases/kernel/power_management/runpwtests02.sh index 8c7936fc4..805befb03 100755 --- a/testcases/kernel/power_management/runpwtests02.sh +++ b/testcases/kernel/power_management/runpwtests02.sh @@ -46,7 +46,7 @@ test_sched_smt() { } # Checking test environment -check_kervel_arch +check_arch # Check sched_smt_power_savings interface on HT machines hyper_threaded=$(is_hyper_threaded) diff --git a/testcases/kernel/power_management/runpwtests03.sh b/testcases/kernel/power_management/runpwtests03.sh index 3fb85d273..72ad2ad68 100755 --- a/testcases/kernel/power_management/runpwtests03.sh +++ b/testcases/kernel/power_management/runpwtests03.sh @@ -145,7 +145,7 @@ pwkm_load_unload() { } # Checking test environment -check_kervel_arch +check_arch # Checking cpufreq sysfs interface files if [ ! -d /sys/devices/system/cpu/cpu0/cpufreq ] ; then diff --git a/testcases/kernel/power_management/runpwtests04.sh b/testcases/kernel/power_management/runpwtests04.sh index 4b727a5bc..6565320d2 100755 --- a/testcases/kernel/power_management/runpwtests04.sh +++ b/testcases/kernel/power_management/runpwtests04.sh @@ -46,7 +46,7 @@ check_cpuidle_sysfs_files() { } # Checking test environment -check_kervel_arch +check_arch # Checking cpuidle sysfs interface files if check_cpuidle_sysfs_files ; then diff --git a/testcases/kernel/power_management/runpwtests05.sh b/testcases/kernel/power_management/runpwtests05.sh index 1c87d8d0c..03b6752bf 100755 --- a/testcases/kernel/power_management/runpwtests05.sh +++ b/testcases/kernel/power_management/runpwtests05.sh @@ -25,15 +25,10 @@ export TST_TOTAL=2 . pm_include.sh # Checking test environment -check_kervel_arch +check_arch -if tst_kvcmp -gt "2.6.29"; then - max_sched_mc=2 - max_sched_smt=2 -else - max_sched_mc=1 - max_sched_smt=1 -fi +max_sched_mc=2 +max_sched_smt=2 tst_require_cmds python3 diff --git a/testcases/kernel/power_management/runpwtests06.sh b/testcases/kernel/power_management/runpwtests06.sh index 1ec193ad4..16e50a670 100755 --- a/testcases/kernel/power_management/runpwtests06.sh +++ b/testcases/kernel/power_management/runpwtests06.sh @@ -45,13 +45,9 @@ test_timer_migration() { } # Checking test environment -check_kervel_arch +check_arch -if tst_kvcmp -ge "2.6.31"; then - timer_migr_support_compatible=0 -else - timer_migr_support_compatible=1 -fi +timer_migr_support_compatible=0 if [ $timer_migr_support_compatible -eq 1 ]; then tst_brkm TCONF "Kernel version does not support Timer migration" diff --git a/testcases/kernel/power_management/runpwtests_exclusive01.sh b/testcases/kernel/power_management/runpwtests_exclusive01.sh index 3a824e5eb..f309d7c19 100755 --- a/testcases/kernel/power_management/runpwtests_exclusive01.sh +++ b/testcases/kernel/power_management/runpwtests_exclusive01.sh @@ -25,15 +25,10 @@ export TST_TOTAL=2 . pm_include.sh # Checking test environment -check_kervel_arch +check_arch -if tst_kvcmp -gt "2.6.29"; then - max_sched_mc=2 - max_sched_smt=2 -else - max_sched_mc=1 - max_sched_smt=1 -fi +max_sched_mc=2 +max_sched_smt=2 tst_require_cmds python3 diff --git a/testcases/kernel/power_management/runpwtests_exclusive02.sh b/testcases/kernel/power_management/runpwtests_exclusive02.sh index fa445185e..547e88fea 100755 --- a/testcases/kernel/power_management/runpwtests_exclusive02.sh +++ b/testcases/kernel/power_management/runpwtests_exclusive02.sh @@ -25,13 +25,9 @@ export TST_TOTAL=1 . pm_include.sh # Checking test environment -check_kervel_arch +check_arch -if tst_kvcmp -gt "2.6.29"; then - max_sched_smt=2 -else - max_sched_smt=1 -fi +max_sched_smt=2 tst_require_cmds python3 diff --git a/testcases/kernel/power_management/runpwtests_exclusive03.sh b/testcases/kernel/power_management/runpwtests_exclusive03.sh index 0d5724825..67c7243e8 100755 --- a/testcases/kernel/power_management/runpwtests_exclusive03.sh +++ b/testcases/kernel/power_management/runpwtests_exclusive03.sh @@ -25,15 +25,10 @@ export TST_TOTAL=2 . pm_include.sh # Checking test environment -check_kervel_arch +check_arch -if tst_kvcmp -gt "2.6.29"; then - max_sched_mc=2 - max_sched_smt=2 -else - max_sched_mc=1 - max_sched_smt=1 -fi +max_sched_mc=2 +max_sched_smt=2 tst_require_cmds python3 diff --git a/testcases/kernel/power_management/runpwtests_exclusive04.sh b/testcases/kernel/power_management/runpwtests_exclusive04.sh index 15e031a43..46985b3be 100755 --- a/testcases/kernel/power_management/runpwtests_exclusive04.sh +++ b/testcases/kernel/power_management/runpwtests_exclusive04.sh @@ -25,7 +25,7 @@ export TST_TOTAL=2 . pm_include.sh # Checking test environment -check_kervel_arch +check_arch tst_require_cmds python3 diff --git a/testcases/kernel/power_management/runpwtests_exclusive05.sh b/testcases/kernel/power_management/runpwtests_exclusive05.sh index 9d4e01683..38450d1fd 100755 --- a/testcases/kernel/power_management/runpwtests_exclusive05.sh +++ b/testcases/kernel/power_management/runpwtests_exclusive05.sh @@ -25,15 +25,10 @@ export TST_TOTAL=2 . pm_include.sh # Checking test environment -check_kervel_arch +check_arch -if tst_kvcmp -gt "2.6.29"; then - max_sched_mc=2 - max_sched_smt=2 -else - max_sched_mc=1 - max_sched_smt=1 -fi +max_sched_mc=2 +max_sched_smt=2 tst_require_cmds python3 diff --git a/testcases/kernel/security/cap_bound/run_capbounds.sh b/testcases/kernel/security/cap_bound/run_capbounds.sh index 6164f62d6..ddf186426 100755 --- a/testcases/kernel/security/cap_bound/run_capbounds.sh +++ b/testcases/kernel/security/cap_bound/run_capbounds.sh @@ -19,12 +19,6 @@ ## ## ################################################################################ -if tst_kvcmp -lt "2.6.25"; then - tst_resm TCONF "System kernel version is less than 2.6.25" - tst_resm TCONF "Cannot execute test" - exit 32 -fi - echo "testing bounding set reading" exit_code=0 diff --git a/testcases/kernel/tracing/dynamic_debug/dynamic_debug01.sh b/testcases/kernel/tracing/dynamic_debug/dynamic_debug01.sh index ca6c840b1..33f85a665 100755 --- a/testcases/kernel/tracing/dynamic_debug/dynamic_debug01.sh +++ b/testcases/kernel/tracing/dynamic_debug/dynamic_debug01.sh @@ -46,10 +46,6 @@ mount_debugfs() setup() { - if tst_kvcmp -lt 2.6.30 ; then - tst_brk TCONF "Dynamic debug is available since version 2.6.30" - fi - mount_debugfs if [ ! -d "$DEBUGFS_PATH/dynamic_debug" ] ; then tst_brk TBROK "Unable to find $DEBUGFS_PATH/dynamic_debug" @@ -59,10 +55,8 @@ setup() tst_brk TBROK "Unable to find $DEBUGFS_CONTROL" fi - if tst_kvcmp -ge 3.4 ; then - NEW_INTERFACE=1 - EMPTY_FLAG="=_" - fi + NEW_INTERFACE=1 + EMPTY_FLAG="=_" grep -v "^#" "$DEBUGFS_CONTROL" > "$DYNDEBUG_STATEMENTS" } @@ -87,10 +81,8 @@ do_all_flags() for INPUT_LINE in $ALL_INPUTS; do do_flag "+p" "$OPTION" "$INPUT_LINE" - if tst_kvcmp -ge 3.2 || [ $NEW_INTERFACE -eq 1 ] ; then - do_flag "+flmt" "$OPTION" "$INPUT_LINE" - do_flag "-flmt" "$OPTION" "$INPUT_LINE" - fi + do_flag "+flmt" "$OPTION" "$INPUT_LINE" + do_flag "-flmt" "$OPTION" "$INPUT_LINE" do_flag "-p" "$OPTION" "$INPUT_LINE" done diff --git a/testcases/kernel/tracing/ftrace_test/ftrace_regression02.sh b/testcases/kernel/tracing/ftrace_test/ftrace_regression02.sh index 3c32f219e..d7729a6cc 100755 --- a/testcases/kernel/tracing/ftrace_test/ftrace_regression02.sh +++ b/testcases/kernel/tracing/ftrace_test/ftrace_regression02.sh @@ -54,10 +54,6 @@ ftrace_signal_test() fi } -if tst_kvcmp -lt "3.2"; then - tst_brkm TCONF "The test should be run in kernels >= 3.2.0 Skip the test..." -fi - ftrace_signal_test tst_exit diff --git a/testcases/kernel/tracing/ftrace_test/ftrace_stress/ftrace_trace_clock.sh b/testcases/kernel/tracing/ftrace_test/ftrace_stress/ftrace_trace_clock.sh index 4a3e68a72..50329c684 100755 --- a/testcases/kernel/tracing/ftrace_test/ftrace_stress/ftrace_trace_clock.sh +++ b/testcases/kernel/tracing/ftrace_test/ftrace_stress/ftrace_trace_clock.sh @@ -15,31 +15,13 @@ LOOP=400 -# In kernel which is older than 2.6.32, we set global clock -# via trace_options. -if tst_kvcmp -lt "2.6.32"; then - old_kernel=1 -else - old_kernel=0 -fi - while true; do i=0 - if [ $old_kernel -eq 1 ]; then - while [ $i -lt $LOOP ]; do - echo 1 > "$TRACING_PATH"/options/global-clock - echo 0 > "$TRACING_PATH"/options/global-clock - i=$((i + 1)) - done - else - while [ $i -lt $LOOP ]; do - echo local > "$TRACING_PATH"/trace_clock - echo global > "$TRACING_PATH"/trace_clock - i=$((i + 1)) - done - - fi - + while [ $i -lt $LOOP ]; do + echo local > "$TRACING_PATH"/trace_clock + echo global > "$TRACING_PATH"/trace_clock + i=$((i + 1)) + done sleep 1 done diff --git a/testcases/kernel/tracing/ftrace_test/ftrace_stress/ftrace_trace_stat.sh b/testcases/kernel/tracing/ftrace_test/ftrace_stress/ftrace_trace_stat.sh index 50aeef970..f7177c988 100755 --- a/testcases/kernel/tracing/ftrace_test/ftrace_stress/ftrace_trace_stat.sh +++ b/testcases/kernel/tracing/ftrace_test/ftrace_stress/ftrace_trace_stat.sh @@ -22,12 +22,6 @@ if [ ! -e "$TRACING_PATH"/function_profile_enabled ]; then should_skip=1 fi -# For kernels older than 2.6.36, this testcase can result in -# divide-by-zero kernel bug -if tst_kvcmp -lt "2.6.36"; then - should_skip=1 -fi - while true; do if [ $should_skip -eq 1 ]; then sleep 2 diff --git a/testcases/network/stress/multicast/grp-operation/mcast-lib.sh b/testcases/network/stress/multicast/grp-operation/mcast-lib.sh index f890deea9..30368b079 100644 --- a/testcases/network/stress/multicast/grp-operation/mcast-lib.sh +++ b/testcases/network/stress/multicast/grp-operation/mcast-lib.sh @@ -27,7 +27,6 @@ mcast_setup4() mcast_setup6() { local default_mld_max_msf=64 - tst_kvcmp -lt '2.6.15' && default_mld_max_msf=10 SYSCTL_ALL_FORCE_MLD_VERSION=$(sysctl -b net.ipv6.conf.all.force_mld_version) SYSCTL_FORCE_MLD_VERSION=$(sysctl -b net.ipv6.conf.$(tst_iface).force_mld_version) diff --git a/testcases/network/virt/virt_lib.sh b/testcases/network/virt/virt_lib.sh index 98a9bb6aa..e919bc3a5 100644 --- a/testcases/network/virt/virt_lib.sh +++ b/testcases/network/virt/virt_lib.sh @@ -44,10 +44,6 @@ virt_lib_setup() { case "$virt_type" in vxlan|geneve) - if tst_kvcmp -lt "3.8"; then - tst_brk TCONF "test must be run with kernel 3.8 or newer" - fi - if [ "$TST_IPV6" ] && tst_kvcmp -lt "3.12"; then tst_brk TCONF "test must be run with kernels >= 3.12" fi @@ -252,10 +248,6 @@ virt_minimize_timeout() vxlan_setup_subnet_uni() { - if tst_kvcmp -lt "3.10"; then - tst_brk TCONF "test must be run with kernel 3.10 or newer" - fi - [ "$(ip link add type $virt_type help 2>&1 | grep remote)" ] || \ tst_brk TCONF "iproute doesn't support remote unicast address" From patchwork Mon Dec 12 11:40:28 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Yang Xu \\(Fujitsu\\)" X-Patchwork-Id: 1714915 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.linux.it (client-ip=2001:1418:10:5::2; helo=picard.linux.it; envelope-from=ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=fujitsu.com header.i=@fujitsu.com header.a=rsa-sha256 header.s=170520fj header.b=mqP6VpH+; dkim-atps=neutral Received: from picard.linux.it (picard.linux.it [IPv6:2001:1418:10:5::2]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NVynC3Z45z240J for ; Mon, 12 Dec 2022 21:39:59 +1100 (AEDT) Received: from picard.linux.it (localhost [IPv6:::1]) by picard.linux.it (Postfix) with ESMTP id 987213CBE59 for ; Mon, 12 Dec 2022 11:39:57 +0100 (CET) X-Original-To: ltp@lists.linux.it Delivered-To: ltp@picard.linux.it Received: from in-3.smtp.seeweb.it (in-3.smtp.seeweb.it [IPv6:2001:4b78:1:20::3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384)) (No client certificate requested) by picard.linux.it (Postfix) with ESMTPS id B9E903CBE78 for ; Mon, 12 Dec 2022 11:39:41 +0100 (CET) Received: from mail1.bemta32.messagelabs.com (mail1.bemta32.messagelabs.com [195.245.230.65]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by in-3.smtp.seeweb.it (Postfix) with ESMTPS id F07FA1A003F2 for ; Mon, 12 Dec 2022 11:39:38 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fujitsu.com; s=170520fj; t=1670841578; i=@fujitsu.com; bh=jRTCVUt2N+ka06xI0CksyUifaUTQU1JdQDQEq8Y6mYw=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=mqP6VpH+utK6ukvHvBSHCz4PujJGHEEZuU1GpXzxV2GLpU2rhGqPx7XjSU1iVihD9 NOTYXWC5KreiA4xRxWt0Vvz7y0f8EfhDcWn1rbCq+M694eyQzxxInnWgnvmDD3ehtn TRDGyYFPReDYYCAT9IVxkWvN+2JX/1GTPQVi1QYsY6v7b8mqmWqJYFIYz+INWdaxZT APRA4yDKygIk9wJvfMZOi1MMZKJbjS7NHuBpxdjxtw198hDEzFPNDd6uvBRAZcyOts zC0AVmxVqjTcr1/q8Npg5XKUCHAbCvvq9vbFHXNKLDY29JbKNmhRKgy0uhuwcdnm6U bUxZyNZMP++bQ== X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrPIsWRWlGSWpSXmKPExsViZ8OxWfcFy/R kgxVTzCxWfN/B6MDose/3OtYAxijWzLyk/IoE1ozJt2axF2z5wVyxtGEqewPj8zXMXYxcHEIC pxgl3j6czw7h7GWSeHntJFCGE8jZwyhxeGEkiM0moCnxrHMBWFxEQEKio+EtO4jNLKAusXzSL yYQW1ggQuLyqslgNSwCqhIXf50Dq+EV8JBoPnKfBcSWEFCQmPLwPVgNp4CnxLe7l1ghdnlIrJ o1gwWiXlDi5MwnLBDzJSQOvnjBDNGrKHGp4xsjhF0hMWtWGxOErSZx9dwm5gmMgrOQtM9C0r6 AkWkVo2lxalFZapGumV5SUWZ6RkluYmaOXmKVbqJeaqlueWpxia6hXmJ5sV5qcbFecWVuck6K Xl5qySZGYPimFLMX7GCcueyP3iFGSQ4mJVHe9D/TkoX4kvJTKjMSizPii0pzUosPMcpwcChJ8 AZ8AcoJFqWmp1akZeYAYwkmLcHBoyTCe4xperIQb3FBYm5xZjpE6hSjJceXbxf3MnNcvXIFSE 6d/W8/sxBLXn5eqpQ4rxAzUIMASENGaR7cOFi8X2KUlRLmZWRgYBDiKUgtys0sQZV/xSjOwag kzLsdZC1PZl4J3NZXQAcxAR0U9XIqyEEliQgpqQYmI6dd/p/9b23Jy1yabLlupvvJ7RHr7ZZK XTHVPjpV7NOpLDsWqVLmi8Z/Yn3kCl2M+r1nurkvfPpfVNjaVrRj75ILT1fOKP5p1WKz0jCrI /TBto/ik2uNJTyKxe87eJrmFR0++vR1t7D4B7FXP45Mqp4b8y6BxSwo72K+zyzBU3OXLj7AwG HC35R0r/nEX4NH5mHeVfGBzkc5b3Jd3Hfy+JZDAeJ/Mjw3KB32PvhPPOu+styC7MJtcnanYl/ Fyrw9wFEvMVPY2TRVd+XcaGO7e1eML2471pBe+drnw6Z3zIpPRb56hwo5PL9Sc10oXc+zN7BB vPJDs+rGqZkpUc1xWsyLNtyx0pxkqRxU2q3EUpyRaKjFXFScCACXoI6CcgMAAA== X-Env-Sender: xuyang2018.jy@fujitsu.com X-Msg-Ref: server-18.tower-587.messagelabs.com!1670841576!311328!1 X-Originating-IP: [62.60.8.179] X-SYMC-ESS-Client-Auth: outbound-route-from=pass X-StarScan-Received: X-StarScan-Version: 9.101.2; banners=-,-,- X-VirusChecked: Checked Received: (qmail 2109 invoked from network); 12 Dec 2022 10:39:36 -0000 Received: from unknown (HELO n03ukasimr04.n03.fujitsu.local) (62.60.8.179) by server-18.tower-587.messagelabs.com with ECDHE-RSA-AES256-GCM-SHA384 encrypted SMTP; 12 Dec 2022 10:39:36 -0000 Received: from n03ukasimr04.n03.fujitsu.local (localhost [127.0.0.1]) by n03ukasimr04.n03.fujitsu.local (Postfix) with ESMTP id 5CC02150 for ; Mon, 12 Dec 2022 10:39:36 +0000 (GMT) Received: from R01UKEXCASM126.r01.fujitsu.local (R01UKEXCASM126 [10.183.43.178]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by n03ukasimr04.n03.fujitsu.local (Postfix) with ESMTPS id 4E9C8153 for ; Mon, 12 Dec 2022 10:39:36 +0000 (GMT) Received: from localhost.localdomain (10.167.220.84) by R01UKEXCASM126.r01.fujitsu.local (10.183.43.178) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Mon, 12 Dec 2022 10:39:34 +0000 From: Yang Xu To: Date: Mon, 12 Dec 2022 19:40:28 +0800 Message-ID: <1670845229-1981-3-git-send-email-xuyang2018.jy@fujitsu.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1670845229-1981-1-git-send-email-xuyang2018.jy@fujitsu.com> References: <1670845229-1981-1-git-send-email-xuyang2018.jy@fujitsu.com> MIME-Version: 1.0 X-Originating-IP: [10.167.220.84] X-ClientProxiedBy: G08CNEXCHPEKD07.g08.fujitsu.local (10.167.33.80) To R01UKEXCASM126.r01.fujitsu.local (10.183.43.178) X-Virus-Scanned: clamav-milter 0.102.4 at in-3.smtp.seeweb.it X-Virus-Status: Clean X-Spam-Status: No, score=0.1 required=7.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=disabled version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on in-3.smtp.seeweb.it Subject: [LTP] [PATCH v1 3/4] Remove old kernel version check in C case when using tst_kvercmp X-BeenThere: ltp@lists.linux.it X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux Test Project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it Sender: "ltp" The oldest supported kernel version is 3.10, so remove them. Signed-off-by: Yang Xu --- include/lapi/common_timers.h | 5 --- include/lapi/init_module.h | 13 ------ .../kernel/containers/mqns/mqns_helper.h | 3 -- .../kernel/containers/pidns/pidns_helper.h | 3 -- .../kernel/containers/userns/userns_helper.h | 3 -- testcases/kernel/containers/utsname/utstest.c | 3 -- .../controllers/cgroup_xattr/cgroup_xattr.c | 5 --- .../kernel/device-drivers/acpi/ltp_acpi.c | 20 --------- .../block/block_dev_user/block_dev.c | 5 --- .../device-drivers/pci/tpci_user/tpci.c | 5 --- .../device-drivers/tbio/tbio_user/tbio.c | 5 --- .../kernel/device-drivers/uaccess/uaccess.c | 5 --- .../kernel/firmware/fw_load_user/fw_load.c | 5 --- testcases/kernel/input/input_helper.c | 18 ++------ testcases/kernel/mem/vma/vma01.c | 8 +--- .../power_management/pm_get_sched_values.c | 20 +-------- .../security/prot_hsymlinks/prot_hsymlinks.c | 4 -- .../kernel/syscalls/adjtimex/adjtimex02.c | 2 +- testcases/kernel/syscalls/clone/clone08.c | 43 ------------------- testcases/kernel/syscalls/eventfd/eventfd01.c | 3 -- .../kernel/syscalls/eventfd2/eventfd2_01.c | 4 -- .../kernel/syscalls/eventfd2/eventfd2_02.c | 4 -- .../kernel/syscalls/eventfd2/eventfd2_03.c | 5 --- .../kernel/syscalls/faccessat/faccessat01.c | 4 -- .../kernel/syscalls/fallocate/fallocate04.c | 14 +----- .../kernel/syscalls/fchownat/fchownat01.c | 3 -- .../kernel/syscalls/fchownat/fchownat02.c | 3 -- testcases/kernel/syscalls/fcntl/fcntl29.c | 4 -- testcases/kernel/syscalls/fcntl/fcntl30.c | 4 -- testcases/kernel/syscalls/fcntl/fcntl31.c | 32 +++----------- .../kernel/syscalls/fgetxattr/fgetxattr02.c | 8 ---- .../syscalls/finit_module/finit_module01.c | 2 - .../syscalls/finit_module/finit_module02.c | 2 - testcases/kernel/syscalls/fstatat/fstatat01.c | 3 -- .../kernel/syscalls/futimesat/futimesat01.c | 3 -- testcases/kernel/syscalls/getcpu/getcpu01.c | 7 --- .../kernel/syscalls/getxattr/getxattr02.c | 11 +---- testcases/kernel/syscalls/inotify/inotify02.c | 15 ------- testcases/kernel/syscalls/inotify/inotify04.c | 14 ------ testcases/kernel/syscalls/ioctl/ioctl01.c | 8 ---- testcases/kernel/syscalls/ioperm/ioperm01.c | 11 +---- testcases/kernel/syscalls/ioperm/ioperm02.c | 15 +------ .../kernel/syscalls/ipc/msgrcv/msgrcv07.c | 3 +- testcases/kernel/syscalls/linkat/linkat01.c | 6 --- testcases/kernel/syscalls/linkat/linkat02.c | 3 -- testcases/kernel/syscalls/madvise/madvise02.c | 8 +--- testcases/kernel/syscalls/mbind/mbind01.c | 6 --- .../syscalls/migrate_pages/migrate_pages02.c | 3 -- testcases/kernel/syscalls/mincore/mincore01.c | 6 --- testcases/kernel/syscalls/mknodat/mknodat01.c | 3 -- testcases/kernel/syscalls/mknodat/mknodat02.c | 5 --- testcases/kernel/syscalls/mlock/mlock02.c | 31 ------------- .../kernel/syscalls/mlockall/mlockall02.c | 32 ++++++-------- .../kernel/syscalls/move_pages/move_pages09.c | 23 ++-------- .../syscalls/move_pages/move_pages_support.c | 7 ++- testcases/kernel/syscalls/munmap/munmap03.c | 7 --- testcases/kernel/syscalls/open/open12.c | 22 ---------- testcases/kernel/syscalls/open/open13.c | 5 --- testcases/kernel/syscalls/openat/openat02.c | 12 ------ testcases/kernel/syscalls/pipe2/pipe2_01.c | 4 -- .../remap_file_pages/remap_file_pages01.c | 9 ---- .../remap_file_pages/remap_file_pages02.c | 6 --- .../kernel/syscalls/renameat/renameat01.c | 6 --- .../kernel/syscalls/signalfd/signalfd01.c | 6 --- .../kernel/syscalls/signalfd4/signalfd4_01.c | 5 --- .../kernel/syscalls/signalfd4/signalfd4_02.c | 5 --- testcases/kernel/syscalls/socket/socket01.c | 20 --------- .../kernel/syscalls/socketpair/socketpair01.c | 20 --------- .../kernel/syscalls/sockioctl/sockioctl01.c | 11 +---- testcases/kernel/syscalls/splice/splice01.c | 6 --- .../kernel/syscalls/symlinkat/symlinkat01.c | 7 --- testcases/kernel/syscalls/sysctl/sysctl03.c | 12 ++---- testcases/kernel/syscalls/tee/tee01.c | 6 --- .../syscalls/timer_create/timer_create01.c | 10 ----- .../syscalls/timer_delete/timer_delete01.c | 6 --- .../syscalls/timer_settime/timer_settime01.c | 6 --- .../syscalls/timer_settime/timer_settime02.c | 6 --- testcases/kernel/syscalls/timerfd/timerfd02.c | 5 --- testcases/kernel/syscalls/timerfd/timerfd03.c | 5 --- .../syscalls/timerfd/timerfd_create01.c | 3 -- testcases/network/netstress/netstress.c | 3 -- testcases/open_posix_testsuite/Makefile | 4 -- testcases/open_posix_testsuite/Makefile.linux | 20 --------- 83 files changed, 48 insertions(+), 679 deletions(-) delete mode 100644 testcases/open_posix_testsuite/Makefile.linux diff --git a/include/lapi/common_timers.h b/include/lapi/common_timers.h index 8d88ac47a..884c997a1 100644 --- a/include/lapi/common_timers.h +++ b/include/lapi/common_timers.h @@ -63,11 +63,6 @@ static inline int possibly_unsupported(clock_t clock) } } -static inline int have_cputime_timers(void) -{ - return tst_kvercmp(2, 6, 12) >= 0; -} - #include "lapi/syscalls.h" #include diff --git a/include/lapi/init_module.h b/include/lapi/init_module.h index fe35ec3ae..650a9ddc9 100644 --- a/include/lapi/init_module.h +++ b/include/lapi/init_module.h @@ -21,17 +21,4 @@ static inline int finit_module(int fd, const char *param_values, int flags) { return tst_syscall(__NR_finit_module, fd, param_values, flags); } - -static inline void finit_module_supported_by_kernel(void) -{ - long ret; - - if ((tst_kvercmp(3, 8, 0)) < 0) { - /* Check if the syscall is backported on an older kernel */ - ret = syscall(__NR_finit_module, 0, "", 0); - if (ret == -1 && errno == ENOSYS) - tst_brk(TCONF, "Test not supported on kernel version < v3.8"); - } -} - #endif /* LAPI_INIT_MODULE_H__ */ diff --git a/testcases/kernel/containers/mqns/mqns_helper.h b/testcases/kernel/containers/mqns/mqns_helper.h index 605378d48..03f50aa36 100644 --- a/testcases/kernel/containers/mqns/mqns_helper.h +++ b/testcases/kernel/containers/mqns/mqns_helper.h @@ -36,9 +36,6 @@ static void check_mqns(void) int pid, status; mqd_t mqd; - if (tst_kvercmp(2, 6, 30) < 0) - tst_brkm(TCONF, NULL, "Kernel version is lower than expected"); - mq_unlink("/checkmqnsenabled"); mqd = mq_open("/checkmqnsenabled", O_RDWR | O_CREAT | O_EXCL, 0777, NULL); diff --git a/testcases/kernel/containers/pidns/pidns_helper.h b/testcases/kernel/containers/pidns/pidns_helper.h index dad7a6d38..3b356768f 100644 --- a/testcases/kernel/containers/pidns/pidns_helper.h +++ b/testcases/kernel/containers/pidns/pidns_helper.h @@ -25,9 +25,6 @@ static int check_newpid(void) { int pid, status; - if (tst_kvercmp(2, 6, 24) < 0) - tst_brkm(TCONF, NULL, "CLONE_NEWPID not supported"); - pid = do_clone_unshare_test(T_CLONE, CLONE_NEWPID, dummy_child, NULL); if (pid == -1) tst_brkm(TCONF | TERRNO, NULL, "CLONE_NEWPID not supported"); diff --git a/testcases/kernel/containers/userns/userns_helper.h b/testcases/kernel/containers/userns/userns_helper.h index 2759d32c2..be47690ea 100644 --- a/testcases/kernel/containers/userns/userns_helper.h +++ b/testcases/kernel/containers/userns/userns_helper.h @@ -29,9 +29,6 @@ static int check_newuser(void) { int pid, status; - if (tst_kvercmp(3, 8, 0) < 0) - tst_brkm(TCONF, NULL, "CLONE_NEWUSER not supported"); - pid = do_clone_unshare_test(T_CLONE, CLONE_NEWUSER, dummy_child, NULL); if (pid == -1) tst_brkm(TCONF | TERRNO, NULL, "CLONE_NEWUSER not supported"); diff --git a/testcases/kernel/containers/utsname/utstest.c b/testcases/kernel/containers/utsname/utstest.c index d22db79c8..9ad19b6b2 100644 --- a/testcases/kernel/containers/utsname/utstest.c +++ b/testcases/kernel/containers/utsname/utstest.c @@ -69,9 +69,6 @@ static void check_newuts(void) { int pid, status; - if (tst_kvercmp(2, 6, 19) < 0) - tst_brkm(TCONF, NULL, "CLONE_NEWUTS not supported"); - pid = do_clone_unshare_test(T_CLONE, CLONE_NEWUTS, dummy_child, NULL); if (pid == -1) tst_brkm(TCONF | TERRNO, NULL, "CLONE_NEWUTS not supported"); diff --git a/testcases/kernel/controllers/cgroup_xattr/cgroup_xattr.c b/testcases/kernel/controllers/cgroup_xattr/cgroup_xattr.c index 71a03d12c..a870118f5 100644 --- a/testcases/kernel/controllers/cgroup_xattr/cgroup_xattr.c +++ b/testcases/kernel/controllers/cgroup_xattr/cgroup_xattr.c @@ -150,11 +150,6 @@ void setup(int argc, char *argv[]) if (access("/proc/cgroups", F_OK) == -1) tst_brkm(TCONF, NULL, "Kernel doesn't support cgroups"); - if (tst_kvercmp(3, 7, 0) < 0) { - tst_brkm(TCONF, NULL, - "Test must be run with kernel 3.7 or newer"); - } - for (i = 0; i < ARRAY_SIZE(tkeys); ++i) { if (!strcmp(tkeys[i].name, "security.")) { tkeys[i].good = tst_kvercmp(3, 15, 0) < 0; diff --git a/testcases/kernel/device-drivers/acpi/ltp_acpi.c b/testcases/kernel/device-drivers/acpi/ltp_acpi.c index f2dc6a4dd..7dba04552 100644 --- a/testcases/kernel/device-drivers/acpi/ltp_acpi.c +++ b/testcases/kernel/device-drivers/acpi/ltp_acpi.c @@ -57,8 +57,6 @@ static int tc_acpi_str(void) int res, ret = 0; char descr[4096], sysfs_path[4096]; - int not_kver_3_7 = tst_kvercmp(3, 7, 0) < 0; - while (1) { SAFE_FILE_PRINTF(cleanup, dev_tcase, "%d", ACPI_TRAVERSE); @@ -86,19 +84,6 @@ static int tc_acpi_str(void) continue; } - /* - * Find device description in sysfs. - * - * New sysfs interface to export device description - * implemented since Linux 3.7 - */ - if (not_kver_3_7) { - tst_resm(TINFO, "sysfs _STR check required Linux 3.7+"); - ret = TCONF; - /* continue, we can still traverse ACPI devices */ - continue; - } - strcat(sysfs_path, "/description"); if (access(sysfs_path, R_OK)) { tst_resm(TINFO, "can't find description file '%s'", @@ -148,11 +133,6 @@ int main(int argc, char *argv[]) tst_require_root(); - if (tst_kvercmp(2, 6, 0) < 0) { - tst_brkm(TCONF, NULL, - "Test must be run with kernel 2.6 or newer"); - } - tst_sig(FORK, DEF_HANDLER, cleanup); tst_module_load(NULL, module_name, NULL); diff --git a/testcases/kernel/device-drivers/block/block_dev_user/block_dev.c b/testcases/kernel/device-drivers/block/block_dev_user/block_dev.c index 9e5e9c2c0..543c36795 100644 --- a/testcases/kernel/device-drivers/block/block_dev_user/block_dev.c +++ b/testcases/kernel/device-drivers/block/block_dev_user/block_dev.c @@ -61,11 +61,6 @@ void setup(int argc, char *argv[]) tst_require_root(); - if (tst_kvercmp(2, 6, 0) < 0) { - tst_brkm(TCONF, NULL, - "Test must be run with kernel 2.6 or newer"); - } - tst_sig(FORK, DEF_HANDLER, cleanup); } diff --git a/testcases/kernel/device-drivers/pci/tpci_user/tpci.c b/testcases/kernel/device-drivers/pci/tpci_user/tpci.c index 659c54261..96018f18c 100644 --- a/testcases/kernel/device-drivers/pci/tpci_user/tpci.c +++ b/testcases/kernel/device-drivers/pci/tpci_user/tpci.c @@ -51,11 +51,6 @@ void setup(void) { tst_require_root(); - if (tst_kvercmp(2, 6, 0) < 0) { - tst_brkm(TCONF, NULL, - "Test must be run with kernel 2.6 or newer"); - } - tst_sig(FORK, DEF_HANDLER, cleanup); } diff --git a/testcases/kernel/device-drivers/tbio/tbio_user/tbio.c b/testcases/kernel/device-drivers/tbio/tbio_user/tbio.c index be1420b98..e882dc768 100644 --- a/testcases/kernel/device-drivers/tbio/tbio_user/tbio.c +++ b/testcases/kernel/device-drivers/tbio/tbio_user/tbio.c @@ -88,11 +88,6 @@ void setup(void) tst_require_root(); - if (tst_kvercmp(2, 6, 0) < 0) { - tst_brkm(TCONF, NULL, - "Test must be run with kernel 2.6 or newer"); - } - tst_module_load(cleanup, module_name, NULL); module_loaded = 1; diff --git a/testcases/kernel/device-drivers/uaccess/uaccess.c b/testcases/kernel/device-drivers/uaccess/uaccess.c index f7537ef4c..f682ff7f6 100644 --- a/testcases/kernel/device-drivers/uaccess/uaccess.c +++ b/testcases/kernel/device-drivers/uaccess/uaccess.c @@ -96,11 +96,6 @@ int main(int argc, char *argv[]) tst_require_root(); - if (tst_kvercmp(2, 6, 0) < 0) { - tst_brkm(TCONF, NULL, - "Test must be run with kernel 2.6 or newer"); - } - tst_sig(FORK, DEF_HANDLER, cleanup); tst_module_load(NULL, module_name, NULL); diff --git a/testcases/kernel/firmware/fw_load_user/fw_load.c b/testcases/kernel/firmware/fw_load_user/fw_load.c index e81d159f6..83648b625 100644 --- a/testcases/kernel/firmware/fw_load_user/fw_load.c +++ b/testcases/kernel/firmware/fw_load_user/fw_load.c @@ -114,11 +114,6 @@ void setup(int argc, char *argv[]) tst_require_root(); - if (tst_kvercmp(3, 7, 0) < 0) { - tst_brkm(TCONF, NULL, - "Test must be run with kernel 3.7 or newer"); - } - char fw_size_param[19]; snprintf(fw_size_param, 19, "fw_size=%d", fw_size); char *const mod_params[2] = { fw_size_param, NULL }; diff --git a/testcases/kernel/input/input_helper.c b/testcases/kernel/input/input_helper.c index c4736eadd..39ab29de3 100644 --- a/testcases/kernel/input/input_helper.c +++ b/testcases/kernel/input/input_helper.c @@ -249,27 +249,17 @@ int check_sync_event(struct input_event *iev) int no_events_queued(int fd, int stray_sync_event) { struct pollfd fds = {.fd = fd, .events = POLLIN}; - int ret, res, sync_event_ignored; + int ret, res; struct input_event ev; - if (tst_kvercmp(3, 7, 0) < 0 && stray_sync_event) - sync_event_ignored = 1; - ret = poll(&fds, 1, 30); if (ret > 0) { res = read(fd, &ev, sizeof(ev)); - if (res == sizeof(ev)) { - if (sync_event_ignored && check_sync_event(&ev)) { - ret = 0; - tst_resm(TINFO, - "Ignoring stray sync event (known problem)"); - } else { - tst_resm(TINFO, - "Unexpected ev type=%i code=%i value=%i", - ev.type, ev.code, ev.value); - } + tst_resm(TINFO, + "Unexpected ev type=%i code=%i value=%i", + ev.type, ev.code, ev.value); } } diff --git a/testcases/kernel/mem/vma/vma01.c b/testcases/kernel/mem/vma/vma01.c index 31322918c..d220b636c 100644 --- a/testcases/kernel/mem/vma/vma01.c +++ b/testcases/kernel/mem/vma/vma01.c @@ -187,13 +187,7 @@ static void check_status(int status) tst_resm(TPASS, "two 3*ps VMAs found."); break; case 1: - if (tst_kvercmp(3, 0, 0) < 0) { - tst_resm(TCONF, "A single 6*ps VMA found. You may need" - " to back port kernel commit 965f55d " - "to fix this scalability issue."); - } else { - tst_resm(TFAIL, "A single 6*ps VMA found."); - } + tst_resm(TFAIL, "A single 6*ps VMA found."); break; default: tst_brkm(TBROK, cleanup, "unexpected VMA found."); diff --git a/testcases/kernel/power_management/pm_get_sched_values.c b/testcases/kernel/power_management/pm_get_sched_values.c index 32bacd789..e75c5852e 100644 --- a/testcases/kernel/power_management/pm_get_sched_values.c +++ b/testcases/kernel/power_management/pm_get_sched_values.c @@ -19,22 +19,6 @@ const char *TCID = "pm_get_sched_values"; -int get_supp_sched_mc(void) -{ - if (tst_kvercmp(2, 6, 29) < 0) - return 1; - else - return 2; -} - -int get_supp_sched_smt(void) -{ - if (tst_kvercmp(2, 6, 29) < 0) - return 1; - else - return 2; -} - int main(int argc, char **argv) { char *param; @@ -43,9 +27,9 @@ int main(int argc, char **argv) else { param = argv[1]; if (strcmp(param, "sched_mc") == 0) - return get_supp_sched_mc(); + return 2; if (strcmp(param, "sched_smt") == 0) - return get_supp_sched_smt(); + return 2; } return 1; diff --git a/testcases/kernel/security/prot_hsymlinks/prot_hsymlinks.c b/testcases/kernel/security/prot_hsymlinks/prot_hsymlinks.c index 369df2b22..20f33527c 100644 --- a/testcases/kernel/security/prot_hsymlinks/prot_hsymlinks.c +++ b/testcases/kernel/security/prot_hsymlinks/prot_hsymlinks.c @@ -193,10 +193,6 @@ static void setup(int argc, char *argv[]) tst_require_root(); - if (tst_kvercmp(3, 7, 0) < 0) - tst_brkm(TCONF, NULL, - "Test must be run with kernel 3.7 or newer"); - if (eaccess("/etc/passwd", W_OK)) { tst_brkm(TCONF, NULL, "/etc/passwd is not accessible"); diff --git a/testcases/kernel/syscalls/adjtimex/adjtimex02.c b/testcases/kernel/syscalls/adjtimex/adjtimex02.c index 747d83254..dab640ff3 100644 --- a/testcases/kernel/syscalls/adjtimex/adjtimex02.c +++ b/testcases/kernel/syscalls/adjtimex/adjtimex02.c @@ -93,7 +93,7 @@ static void verify_adjtimex(unsigned int i) if (tc[i].highlimit) buf->tick = tc[i].highlimit + tc[i].delta; } - if (tc[i].modes == ADJ_OFFSET && (tst_kvercmp(2, 6, 25) > 0)) { + if (tc[i].modes == ADJ_OFFSET) { if (tc[i].lowlimit || tc[i].highlimit) { tst_res(TCONF, "Newer kernels normalize offset value outside range"); return; diff --git a/testcases/kernel/syscalls/clone/clone08.c b/testcases/kernel/syscalls/clone/clone08.c index ad285a497..dd97f3ff1 100644 --- a/testcases/kernel/syscalls/clone/clone08.c +++ b/testcases/kernel/syscalls/clone/clone08.c @@ -28,11 +28,6 @@ static void test_clone_tid(int t); static int child_clone_child_settid(void *); static int child_clone_parent_settid(void *); -#ifdef CLONE_STOPPED -static void test_clone_stopped(int t); -static int child_clone_stopped(void *); -static int stopped_flag; -#endif static void test_clone_thread(int t); static int child_clone_thread(void *); @@ -57,10 +52,6 @@ static struct test_case { test_clone_tid, child_clone_child_settid}, {"CLONE_PARENT_SETTID", CLONE_PARENT_SETTID | CLONE_VM | SIGCHLD, test_clone_tid, child_clone_parent_settid}, -#ifdef CLONE_STOPPED - {"CLONE_STOPPED", CLONE_STOPPED | CLONE_VM | SIGCHLD, - test_clone_stopped, child_clone_stopped}, -#endif {"CLONE_THREAD", CLONE_THREAD | CLONE_SIGHAND | CLONE_VM | CLONE_CHILD_CLEARTID | SIGCHLD, test_clone_thread, child_clone_thread}, @@ -147,40 +138,6 @@ static int child_clone_parent_settid(void *arg LTP_ATTRIBUTE_UNUSED) return 0; } -#ifdef CLONE_STOPPED -static void test_clone_stopped(int t) -{ - pid_t child; - - if (tst_kvercmp(2, 6, 38) >= 0) { - tst_res(TCONF, "CLONE_STOPPED skipped for kernels >= 2.6.38"); - return; - } - - child = clone_child(&test_cases[t]); - - TST_PROCESS_STATE_WAIT(child, 'T', 0); - - stopped_flag = 0; - - SAFE_KILL(child, SIGCONT); - - tst_reap_children(); - - if (stopped_flag == 1) - tst_res(TPASS, "clone stopped and resumed as expected"); - else - tst_res(TFAIL, "clone not stopped, flag %d", stopped_flag); -} - -static int child_clone_stopped(void *arg LTP_ATTRIBUTE_UNUSED) -{ - stopped_flag = 1; - tst_syscall(__NR_exit, 0); - return 0; -} -#endif - static void test_clone_thread(int t) { pid_t child; diff --git a/testcases/kernel/syscalls/eventfd/eventfd01.c b/testcases/kernel/syscalls/eventfd/eventfd01.c index c24aa3197..9b60434a2 100644 --- a/testcases/kernel/syscalls/eventfd/eventfd01.c +++ b/testcases/kernel/syscalls/eventfd/eventfd01.c @@ -720,9 +720,6 @@ static void setup(void) tst_sig(FORK, DEF_HANDLER, cleanup); - if (tst_kvercmp(2, 6, 22) < 0) - tst_brkm(TCONF, NULL, "2.6.22 or greater kernel required"); - tst_tmpdir(); TEST_PAUSE; diff --git a/testcases/kernel/syscalls/eventfd2/eventfd2_01.c b/testcases/kernel/syscalls/eventfd2/eventfd2_01.c index c9ecdc58e..85ad86d42 100644 --- a/testcases/kernel/syscalls/eventfd2/eventfd2_01.c +++ b/testcases/kernel/syscalls/eventfd2/eventfd2_01.c @@ -85,10 +85,6 @@ int main(int argc, char *argv[]) tst_parse_opts(argc, argv, NULL, NULL); - if ((tst_kvercmp(2, 6, 27)) < 0) { - tst_brkm(TCONF, NULL, - "This test can only run on kernels that are 2.6.27 and higher"); - } setup(); fd = tst_syscall(__NR_eventfd2, 1, 0); diff --git a/testcases/kernel/syscalls/eventfd2/eventfd2_02.c b/testcases/kernel/syscalls/eventfd2/eventfd2_02.c index 2125b528e..5f3b6ee67 100644 --- a/testcases/kernel/syscalls/eventfd2/eventfd2_02.c +++ b/testcases/kernel/syscalls/eventfd2/eventfd2_02.c @@ -82,10 +82,6 @@ int main(int argc, char *argv[]) tst_parse_opts(argc, argv, NULL, NULL); - if ((tst_kvercmp(2, 6, 27)) < 0) { - tst_brkm(TCONF, NULL, - "This test can only run on kernels that are 2.6.27 and higher"); - } setup(); tst_count = 0; diff --git a/testcases/kernel/syscalls/eventfd2/eventfd2_03.c b/testcases/kernel/syscalls/eventfd2/eventfd2_03.c index e26714ddc..909004edb 100644 --- a/testcases/kernel/syscalls/eventfd2/eventfd2_03.c +++ b/testcases/kernel/syscalls/eventfd2/eventfd2_03.c @@ -119,11 +119,6 @@ int main(int argc, char **argv) return 1; } } - if ((tst_kvercmp(2, 6, 27)) < 0) { - tst_brkm(TCONF, - NULL, - "This test can only run on kernels that are 2.6.27 and higher"); - } if ((fd1 = eventfd2(0, EFD_SEMLIKE)) == -1 || (fd2 = eventfd2(0, EFD_SEMLIKE)) == -1) { perror("eventfd2"); diff --git a/testcases/kernel/syscalls/faccessat/faccessat01.c b/testcases/kernel/syscalls/faccessat/faccessat01.c index 1ab494e7a..d11e8cf12 100644 --- a/testcases/kernel/syscalls/faccessat/faccessat01.c +++ b/testcases/kernel/syscalls/faccessat/faccessat01.c @@ -72,10 +72,6 @@ int main(int ac, char **av) int lc; int i; - /* Disable test if the version of the kernel is less than 2.6.16 */ - if ((tst_kvercmp(2, 6, 16)) < 0) - tst_brkm(TCONF, NULL, "Test must be run with kernel 2.6.16+"); - tst_parse_opts(ac, av, NULL, NULL); setup(); diff --git a/testcases/kernel/syscalls/fallocate/fallocate04.c b/testcases/kernel/syscalls/fallocate/fallocate04.c index 568a9e3f1..ff372a9bf 100644 --- a/testcases/kernel/syscalls/fallocate/fallocate04.c +++ b/testcases/kernel/syscalls/fallocate/fallocate04.c @@ -103,11 +103,6 @@ static void test02(void) tst_res(TINFO, "read allocated file size '%zu'", alloc_size0); tst_res(TINFO, "make a hole with FALLOC_FL_PUNCH_HOLE"); - if (tst_kvercmp(2, 6, 38) < 0) { - tst_brk(TCONF, - "FALLOC_FL_PUNCH_HOLE needs Linux 2.6.38 or newer"); - } - if (fallocate(fd, FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE, block_size, block_size) == -1) { if (errno == EOPNOTSUPP) { @@ -126,13 +121,8 @@ static void test02(void) tst_brk(TFAIL | TERRNO, "fallocate() or lseek() failed"); } - if (tst_kvercmp(3, 1, 0) < 0) { - tst_res(TINFO, "lseek() doesn't support SEEK_HOLE, " - "this is expected for < 3.1 kernels"); - } else { - tst_brk(TBROK | TERRNO, - "lseek() doesn't support SEEK_HOLE"); - } + tst_brk(TBROK | TERRNO, + "lseek() doesn't support SEEK_HOLE"); } else { tst_res(TINFO, "found a hole at '%ld' offset", ret); } diff --git a/testcases/kernel/syscalls/fchownat/fchownat01.c b/testcases/kernel/syscalls/fchownat/fchownat01.c index a658f07db..3b29f1e75 100644 --- a/testcases/kernel/syscalls/fchownat/fchownat01.c +++ b/testcases/kernel/syscalls/fchownat/fchownat01.c @@ -86,9 +86,6 @@ int main(int ac, char **av) static void setup(void) { - if ((tst_kvercmp(2, 6, 16)) < 0) - tst_brkm(TCONF, NULL, "This test needs kernel 2.6.16 or newer"); - tst_sig(NOFORK, DEF_HANDLER, cleanup); TEST_PAUSE; diff --git a/testcases/kernel/syscalls/fchownat/fchownat02.c b/testcases/kernel/syscalls/fchownat/fchownat02.c index 701623dd7..c39b0a919 100644 --- a/testcases/kernel/syscalls/fchownat/fchownat02.c +++ b/testcases/kernel/syscalls/fchownat/fchownat02.c @@ -71,9 +71,6 @@ static void setup(void) { struct stat c_buf, l_buf; - if ((tst_kvercmp(2, 6, 16)) < 0) - tst_brkm(TCONF, NULL, "This test needs kernel 2.6.16 or newer"); - tst_require_root(); tst_sig(NOFORK, DEF_HANDLER, cleanup); diff --git a/testcases/kernel/syscalls/fcntl/fcntl29.c b/testcases/kernel/syscalls/fcntl/fcntl29.c index 587476454..c94c9e748 100644 --- a/testcases/kernel/syscalls/fcntl/fcntl29.c +++ b/testcases/kernel/syscalls/fcntl/fcntl29.c @@ -84,10 +84,6 @@ int main(int ac, char **av) static void setup(void) { - if ((tst_kvercmp(2, 6, 24)) < 0) { - tst_brkm(TCONF, NULL, "Kernels >= 2.6.24 required"); - } - tst_sig(NOFORK, DEF_HANDLER, cleanup); tst_tmpdir(); diff --git a/testcases/kernel/syscalls/fcntl/fcntl30.c b/testcases/kernel/syscalls/fcntl/fcntl30.c index 27f464389..c4c3f81f1 100644 --- a/testcases/kernel/syscalls/fcntl/fcntl30.c +++ b/testcases/kernel/syscalls/fcntl/fcntl30.c @@ -93,10 +93,6 @@ int main(int ac, char **av) static void setup(void) { - if ((tst_kvercmp(2, 6, 35)) < 0) { - tst_brkm(TCONF, NULL, "kernel >= 2.6.35 required"); - } - tst_sig(NOFORK, DEF_HANDLER, cleanup); TEST_PAUSE; diff --git a/testcases/kernel/syscalls/fcntl/fcntl31.c b/testcases/kernel/syscalls/fcntl/fcntl31.c index f6e2b01ff..f6f625e85 100644 --- a/testcases/kernel/syscalls/fcntl/fcntl31.c +++ b/testcases/kernel/syscalls/fcntl/fcntl31.c @@ -45,9 +45,6 @@ static void setown_pid_test(void); static void setown_pgrp_test(void); #if defined(HAVE_STRUCT_F_OWNER_EX) -static int ownex_enabled; -static char *ownex_tconf_msg = "F_GETOWN_EX and F_SETOWN_EX only run on " - "kernels that are 2.6.32 and higher"; static void setownex_tid_test(void); static void setownex_pid_test(void); static void setownex_pgrp_test(void); @@ -126,15 +123,11 @@ static void setup(void) tst_brkm(TBROK | TERRNO, cleanup, "getpgid() failed"); #if defined(HAVE_STRUCT_F_OWNER_EX) - if ((tst_kvercmp(2, 6, 32)) >= 0) { - ownex_enabled = 1; - - /* get original f_owner_ex info */ - TEST(fcntl(test_fd, F_GETOWN_EX, &orig_own_ex)); - if (TEST_RETURN < 0) { - tst_brkm(TFAIL | TTERRNO, cleanup, - "fcntl get original f_owner_ex info failed"); - } + /* get original f_owner_ex info */ + TEST(fcntl(test_fd, F_GETOWN_EX, &orig_own_ex)); + if (TEST_RETURN < 0) { + tst_brkm(TFAIL | TTERRNO, cleanup, + "fcntl get original f_owner_ex info failed"); } #endif @@ -204,11 +197,6 @@ static void setownex_tid_test(void) { static struct f_owner_ex tst_own_ex; - if (ownex_enabled == 0) { - tst_resm(TCONF, "%s", ownex_tconf_msg); - return; - } - tst_own_ex.type = F_OWNER_TID; tst_own_ex.pid = tst_syscall(__NR_gettid); @@ -226,11 +214,6 @@ static void setownex_pid_test(void) { static struct f_owner_ex tst_own_ex; - if (ownex_enabled == 0) { - tst_resm(TCONF, "%s", ownex_tconf_msg); - return; - } - tst_own_ex.type = F_OWNER_PID; tst_own_ex.pid = pid; @@ -249,11 +232,6 @@ static void setownex_pgrp_test(void) { static struct f_owner_ex tst_own_ex; - if (ownex_enabled == 0) { - tst_resm(TCONF, "%s", ownex_tconf_msg); - return; - } - tst_own_ex.type = F_OWNER_PGRP; tst_own_ex.pid = pgrp_pid; diff --git a/testcases/kernel/syscalls/fgetxattr/fgetxattr02.c b/testcases/kernel/syscalls/fgetxattr/fgetxattr02.c index c3cff0aab..1a9a39c9b 100644 --- a/testcases/kernel/syscalls/fgetxattr/fgetxattr02.c +++ b/testcases/kernel/syscalls/fgetxattr/fgetxattr02.c @@ -188,14 +188,6 @@ static void verify_fgetxattr(unsigned int i) fname); } - /* - * Before kernel 3.0.0, fgetxattr(2) will set errno with 'EPERM' - * when the file is not a regular file and directory, refer to - * commitid 55b23bd - */ - if (tc[i].exp_err == ENODATA && tst_kvercmp(3, 0, 0) < 0) - tc[i].exp_err = EPERM; - if (tc[i].exp_err == TST_ERR) { tst_res(TPASS | TTERRNO, "fgetxattr(2) on %s passed", fname); diff --git a/testcases/kernel/syscalls/finit_module/finit_module01.c b/testcases/kernel/syscalls/finit_module/finit_module01.c index 21c35f101..f960b2e40 100644 --- a/testcases/kernel/syscalls/finit_module/finit_module01.c +++ b/testcases/kernel/syscalls/finit_module/finit_module01.c @@ -25,8 +25,6 @@ static char *mod_path; static void setup(void) { - finit_module_supported_by_kernel(); - tst_module_exists(MODULE_NAME, &mod_path); fd = SAFE_OPEN(mod_path, O_RDONLY|O_CLOEXEC); diff --git a/testcases/kernel/syscalls/finit_module/finit_module02.c b/testcases/kernel/syscalls/finit_module/finit_module02.c index b3437b5d0..a7434de7d 100644 --- a/testcases/kernel/syscalls/finit_module/finit_module02.c +++ b/testcases/kernel/syscalls/finit_module/finit_module02.c @@ -81,8 +81,6 @@ static void setup(void) { unsigned long int i; - finit_module_supported_by_kernel(); - tst_module_exists(MODULE_NAME, &mod_path); kernel_lockdown = tst_lockdown_enabled(); diff --git a/testcases/kernel/syscalls/fstatat/fstatat01.c b/testcases/kernel/syscalls/fstatat/fstatat01.c index 28e3d472f..c18ffacf2 100644 --- a/testcases/kernel/syscalls/fstatat/fstatat01.c +++ b/testcases/kernel/syscalls/fstatat/fstatat01.c @@ -86,9 +86,6 @@ int main(int ac, char **av) static struct stat statbuf; #endif - if (tst_kvercmp(2, 6, 16) < 0) - tst_brkm(TCONF, NULL, "Test must be run with kernel 2.6.16+"); - tst_parse_opts(ac, av, NULL, NULL); setup(); diff --git a/testcases/kernel/syscalls/futimesat/futimesat01.c b/testcases/kernel/syscalls/futimesat/futimesat01.c index 9b1e75b7f..46bd57c48 100644 --- a/testcases/kernel/syscalls/futimesat/futimesat01.c +++ b/testcases/kernel/syscalls/futimesat/futimesat01.c @@ -66,9 +66,6 @@ int main(int ac, char **av) int lc, i; struct timeval times[2]; - if (tst_kvercmp(2, 6, 16) < 0) - tst_brkm(TCONF, NULL, "Test must be run with kernel 2.6.16+"); - tst_parse_opts(ac, av, NULL, NULL); setup(); diff --git a/testcases/kernel/syscalls/getcpu/getcpu01.c b/testcases/kernel/syscalls/getcpu/getcpu01.c index fcc273e29..85ab11bb4 100644 --- a/testcases/kernel/syscalls/getcpu/getcpu01.c +++ b/testcases/kernel/syscalls/getcpu/getcpu01.c @@ -156,13 +156,6 @@ static void run(void) } } -static void setup(void) -{ - if (tst_kvercmp(2, 6, 20) < 0) - tst_brk(TCONF, "kernel >= 2.6.20 required"); -} - static struct tst_test test = { .test_all = run, - .setup = setup, }; diff --git a/testcases/kernel/syscalls/getxattr/getxattr02.c b/testcases/kernel/syscalls/getxattr/getxattr02.c index dca6b13be..a42057d0a 100644 --- a/testcases/kernel/syscalls/getxattr/getxattr02.c +++ b/testcases/kernel/syscalls/getxattr/getxattr02.c @@ -91,16 +91,7 @@ int main(int argc, char *argv[]) for (lc = 0; TEST_LOOPING(lc); lc++) { tst_count = 0; - - /* - * Before kernel 3.0.0, getxattr(2) will set errno with 'EPERM' - * when the file is not a regular file and directory, refer to - * commitid 55b23bd - */ - if (tst_kvercmp(3, 0, 0) >= 0) - exp_eno = ENODATA; - else - exp_eno = EPERM; + exp_eno = ENODATA; for (i = 0; i < TST_TOTAL; i++) { TEST(getxattr(tc[0], XATTR_TEST_KEY, buf, BUFSIZ)); diff --git a/testcases/kernel/syscalls/inotify/inotify02.c b/testcases/kernel/syscalls/inotify/inotify02.c index 576ef431c..cd1cb97bd 100644 --- a/testcases/kernel/syscalls/inotify/inotify02.c +++ b/testcases/kernel/syscalls/inotify/inotify02.c @@ -133,21 +133,6 @@ void verify_inotify(void) struct inotify_event *event; event = (struct inotify_event *)&event_buf[i]; if (test_num >= test_cnt) { - if (tst_kvercmp(2, 6, 25) < 0 - && event_set[test_cnt - 1].mask == - event->mask) - tst_res(TWARN, - "This may be kernel bug. " - "Before kernel 2.6.25, a kernel bug " - "meant that the kernel code that was " - "intended to coalesce successive identical " - "events (i.e., the two most recent " - "events could potentially be coalesced " - "if the older had not yet been read) " - "instead checked if the most recent event " - "could be coalesced with the oldest " - "unread event. This has been fixed by commit" - "1c17d18e3775485bf1e0ce79575eb637a94494a2."); tst_res(TFAIL, "get unnecessary event: " "wd=%d mask=%08x cookie=%-5u len=%-2u " diff --git a/testcases/kernel/syscalls/inotify/inotify04.c b/testcases/kernel/syscalls/inotify/inotify04.c index c4fce399c..70c7fecfd 100644 --- a/testcases/kernel/syscalls/inotify/inotify04.c +++ b/testcases/kernel/syscalls/inotify/inotify04.c @@ -124,20 +124,6 @@ void verify_inotify(void) struct inotify_event *event; event = (struct inotify_event *)&event_buf[i]; if (test_num >= test_cnt) { - if (tst_kvercmp(2, 6, 25) < 0 - && event_set[test_cnt - 1].mask == event->mask) - tst_res(TWARN, - "This may be kernel bug. " - "Before kernel 2.6.25, a kernel bug " - "meant that the kernel code that was " - "intended to coalesce successive identical " - "events (i.e., the two most recent " - "events could potentially be coalesced " - "if the older had not yet been read) " - "instead checked if the most recent event " - "could be coalesced with the oldest " - "unread event. This has been fixed by commit" - "1c17d18e3775485bf1e0ce79575eb637a94494a2."); tst_res(TFAIL, "got unnecessary event: " "wd=%d mask=%04x cookie=%u len=%u " diff --git a/testcases/kernel/syscalls/ioctl/ioctl01.c b/testcases/kernel/syscalls/ioctl/ioctl01.c index 26b603ebe..2989c0e9b 100644 --- a/testcases/kernel/syscalls/ioctl/ioctl01.c +++ b/testcases/kernel/syscalls/ioctl/ioctl01.c @@ -79,14 +79,6 @@ static void setup(void) tst_brk(TBROK, "You must specify a tty device with -D option"); fd = SAFE_OPEN(device, O_RDWR, 0777); - - if (tst_kvercmp(3, 7, 0) < 0) { - for (i = 0; i < ARRAY_SIZE(tcases); i++) { - if (tcases[i].request == INVAL_IOCTL) - tcases[i].error = EINVAL; - } - } - fd_file = SAFE_OPEN("x", O_CREAT, 0777); } diff --git a/testcases/kernel/syscalls/ioperm/ioperm01.c b/testcases/kernel/syscalls/ioperm/ioperm01.c index 8f2cc684d..4bc30ff4f 100644 --- a/testcases/kernel/syscalls/ioperm/ioperm01.c +++ b/testcases/kernel/syscalls/ioperm/ioperm01.c @@ -42,16 +42,7 @@ static void verify_ioperm(void) static void setup(void) { - /* - * The value of IO_BITMAP_BITS (include/asm-i386/processor.h) changed - * from kernel 2.6.8 to permit 16-bits ioperm - * - * Ricky Ng-Adam, rngadam@yahoo.com - * */ - if (tst_kvercmp(2, 6, 8) < 0) - io_addr = IO_BITMAP_BITS - NUM_BYTES; - else - io_addr = IO_BITMAP_BITS - NUM_BYTES; + io_addr = IO_BITMAP_BITS - NUM_BYTES; } static void cleanup(void) diff --git a/testcases/kernel/syscalls/ioperm/ioperm02.c b/testcases/kernel/syscalls/ioperm/ioperm02.c index 33c501904..eab701d95 100644 --- a/testcases/kernel/syscalls/ioperm/ioperm02.c +++ b/testcases/kernel/syscalls/ioperm/ioperm02.c @@ -45,19 +45,8 @@ static struct tcase_t { static void setup(void) { - /* - * The value of IO_BITMAP_BITS (include/asm-i386/processor.h) changed - * from kernel 2.6.8 to permit 16-bits (65536) ioperm - * - * Ricky Ng-Adam, rngadam@yahoo.com - */ - if ((tst_kvercmp(2, 6, 8) < 0) || (tst_kvercmp(2, 6, 9) == 0)) { - tcases[0].from = (IO_BITMAP_BITS - NUM_BYTES) + 1; - tcases[1].from = IO_BITMAP_BITS - NUM_BYTES; - } else { - tcases[0].from = (IO_BITMAP_BITS_16 - NUM_BYTES) + 1; - tcases[1].from = IO_BITMAP_BITS_16 - NUM_BYTES; - } + tcases[0].from = (IO_BITMAP_BITS_16 - NUM_BYTES) + 1; + tcases[1].from = IO_BITMAP_BITS_16 - NUM_BYTES; struct passwd *pw; pw = SAFE_GETPWNAM("nobody"); diff --git a/testcases/kernel/syscalls/ipc/msgrcv/msgrcv07.c b/testcases/kernel/syscalls/ipc/msgrcv/msgrcv07.c index f4bca5ec8..d2d1a882a 100644 --- a/testcases/kernel/syscalls/ipc/msgrcv/msgrcv07.c +++ b/testcases/kernel/syscalls/ipc/msgrcv/msgrcv07.c @@ -247,8 +247,7 @@ static void setup(void) { msgkey = GETIPCKEY(); - if (tst_kvercmp(3, 8, 0) >= 0) - msg_copy_sup = 1; + msg_copy_sup = 1; } static void (*testfunc[])(void) = {test_msg_except, test_msg_noerror, diff --git a/testcases/kernel/syscalls/linkat/linkat01.c b/testcases/kernel/syscalls/linkat/linkat01.c index 044a275ae..57cfbcfc6 100644 --- a/testcases/kernel/syscalls/linkat/linkat01.c +++ b/testcases/kernel/syscalls/linkat/linkat01.c @@ -201,12 +201,6 @@ int main(int ac, char **av) int lc; int i; - if ((tst_kvercmp(2, 6, 16)) < 0) { - tst_resm(TWARN, "This test can only run on kernels that are "); - tst_resm(TWARN, "2.6.16 and higher"); - exit(0); - } - tst_parse_opts(ac, av, NULL, NULL); setup(); diff --git a/testcases/kernel/syscalls/linkat/linkat02.c b/testcases/kernel/syscalls/linkat/linkat02.c index 796190fef..47383acec 100644 --- a/testcases/kernel/syscalls/linkat/linkat02.c +++ b/testcases/kernel/syscalls/linkat/linkat02.c @@ -138,9 +138,6 @@ static void linkat_verify(const struct test_struct *desc) static void setup(void) { - if ((tst_kvercmp(2, 6, 16)) < 0) - tst_brkm(TCONF, NULL, "This test needs kernel 2.6.16 or newer"); - tst_require_root(); tst_sig(NOFORK, DEF_HANDLER, cleanup); diff --git a/testcases/kernel/syscalls/madvise/madvise02.c b/testcases/kernel/syscalls/madvise/madvise02.c index 29e0ace00..d6c06c344 100644 --- a/testcases/kernel/syscalls/madvise/madvise02.c +++ b/testcases/kernel/syscalls/madvise/madvise02.c @@ -97,14 +97,9 @@ static void tcases_filter(void) #endif /* if !defined(UCLINUX) */ break; case MADV_REMOVE: - if ((tst_kvercmp(2, 6, 16)) < 0) - tc->skip = 1; break; case MADV_MERGEABLE: case MADV_UNMERGEABLE: - if ((tst_kvercmp(2, 6, 32)) < 0) - tc->skip = 1; - /* kernel configured with CONFIG_KSM, * skip EINVAL test for MADV_MERGEABLE. */ if (access(KSM_SYS_DIR, F_OK) == 0) @@ -114,8 +109,7 @@ static void tcases_filter(void) /* In kernel commit 1998cc0, madvise(MADV_WILLNEED) to * anon mem doesn't return -EBADF now, as now we support * swap prefretch. */ - if ((tst_kvercmp(3, 9, 0)) > 0 && - tc->exp_errno == EBADF) + if (tc->exp_errno == EBADF) tc->skip = 1; break; case MADV_FREE: diff --git a/testcases/kernel/syscalls/mbind/mbind01.c b/testcases/kernel/syscalls/mbind/mbind01.c index 5f3c5d7c0..4b8d168cd 100644 --- a/testcases/kernel/syscalls/mbind/mbind01.c +++ b/testcases/kernel/syscalls/mbind/mbind01.c @@ -197,12 +197,6 @@ static void do_test(unsigned int i) tst_res(TINFO, "case %s", tc->desc); if (tc->policy == MPOL_LOCAL) { - if ((tst_kvercmp(3, 8, 0)) < 0) { - tst_res(TCONF, "%s is not supported", - tst_mempolicy_mode_name(tc->policy)); - return; - } - if ((tst_kvercmp(5, 14, 0)) >= 0) tc->check_policy = NULL; } diff --git a/testcases/kernel/syscalls/migrate_pages/migrate_pages02.c b/testcases/kernel/syscalls/migrate_pages/migrate_pages02.c index 4d5b2b8d5..780aae1b5 100644 --- a/testcases/kernel/syscalls/migrate_pages/migrate_pages02.c +++ b/testcases/kernel/syscalls/migrate_pages/migrate_pages02.c @@ -273,9 +273,6 @@ static void setup(void) if (num_nodes < 2) tst_brk(TCONF, "at least 2 allowed NUMA nodes" " are required"); - else if (tst_kvercmp(2, 6, 18) < 0) - tst_brk(TCONF, "2.6.18 or greater kernel required"); - /* * find 2 nodes, which can hold NODE_MIN_FREEMEM bytes * The reason is that: diff --git a/testcases/kernel/syscalls/mincore/mincore01.c b/testcases/kernel/syscalls/mincore/mincore01.c index e2dfe04cf..03ec3b4e6 100644 --- a/testcases/kernel/syscalls/mincore/mincore01.c +++ b/testcases/kernel/syscalls/mincore/mincore01.c @@ -145,12 +145,6 @@ static void setup4(struct test_case_t *tc) tc->addr = global_pointer; tc->len = as_lim.rlim_cur - (rlim_t)global_pointer + pagesize; tc->vector = global_vec; - - /* - * In linux 2.6.11 and earlier, EINVAL was returned for this condition. - */ - if (tst_kvercmp(2, 6, 11) <= 0) - tc->exp_errno = EINVAL; } static void setup(void) diff --git a/testcases/kernel/syscalls/mknodat/mknodat01.c b/testcases/kernel/syscalls/mknodat/mknodat01.c index bff2c6a4e..6500ca362 100644 --- a/testcases/kernel/syscalls/mknodat/mknodat01.c +++ b/testcases/kernel/syscalls/mknodat/mknodat01.c @@ -118,9 +118,6 @@ static void setup(void) { char *tmpdir; - if (tst_kvercmp(2, 6, 16) < 0) - tst_brkm(TCONF, NULL, "This test needs kernel 2.6.16 or newer"); - tst_sig(NOFORK, DEF_HANDLER, cleanup); TEST_PAUSE; diff --git a/testcases/kernel/syscalls/mknodat/mknodat02.c b/testcases/kernel/syscalls/mknodat/mknodat02.c index 28c5c8a4b..eda247fda 100644 --- a/testcases/kernel/syscalls/mknodat/mknodat02.c +++ b/testcases/kernel/syscalls/mknodat/mknodat02.c @@ -105,11 +105,6 @@ static void setup(void) int i; const char *fs_type; - if (tst_kvercmp(2, 6, 16) < 0) { - tst_brkm(TCONF, NULL, "This test can only run on kernels " - "that are 2.6.16 and higher"); - } - tst_require_root(); tst_sig(NOFORK, DEF_HANDLER, cleanup); diff --git a/testcases/kernel/syscalls/mlock/mlock02.c b/testcases/kernel/syscalls/mlock/mlock02.c index 1119e7ad0..50ee31d1c 100644 --- a/testcases/kernel/syscalls/mlock/mlock02.c +++ b/testcases/kernel/syscalls/mlock/mlock02.c @@ -98,24 +98,6 @@ static void test_enomem1(void) void *addr; struct rlimit rl; - /* - * RLIMIT_MEMLOCK resource limit. - * In Linux kernels before 2.6.9, this limit controlled the amount - * of memory that could be locked by a privileged process. Since - * Linux 2.6.9, no limits are placed on the amount of memory that a - * privileged process may lock, and this limit instead governs the - * amount of memory that an unprivileged process may lock. So here - * we set RLIMIT_MEMLOCK resource limit to RLIM_INFINITY when kernel - * is under 2.6.9, to make sure this ENOMEM error is indeed caused by - * that some of the specified address range does not correspond to - * mapped pages in the address space of the process. - */ - if ((tst_kvercmp(2, 6, 9)) < 0) { - rl.rlim_cur = RLIM_INFINITY; - rl.rlim_max = RLIM_INFINITY; - SAFE_SETRLIMIT(cleanup, RLIMIT_MEMLOCK, &rl); - } - addr = SAFE_MMAP(cleanup, NULL, len, PROT_READ, MAP_PRIVATE | MAP_ANONYMOUS, 0, 0); @@ -129,13 +111,6 @@ static void test_enomem2(void) void *addr; struct rlimit rl; - if ((tst_kvercmp(2, 6, 9)) < 0) { - tst_resm(TCONF, - "ENOMEM error value test for this condition needs " - "kernel 2.6.9 or higher"); - return; - } - rl.rlim_max = len - 1; rl.rlim_cur = len - 1; SAFE_SETRLIMIT(cleanup, RLIMIT_MEMLOCK, &rl); @@ -159,12 +134,6 @@ static void test_eperm(void) void *addr; struct rlimit rl; - if ((tst_kvercmp(2, 6, 9)) < 0) { - tst_resm(TCONF, - "EPERM error value test needs kernel 2.6.9 or higher"); - return; - } - rl.rlim_max = 0; rl.rlim_cur = 0; SAFE_SETRLIMIT(cleanup, RLIMIT_MEMLOCK, &rl); diff --git a/testcases/kernel/syscalls/mlockall/mlockall02.c b/testcases/kernel/syscalls/mlockall/mlockall02.c index f2eca09c0..e301bcb03 100644 --- a/testcases/kernel/syscalls/mlockall/mlockall02.c +++ b/testcases/kernel/syscalls/mlockall/mlockall02.c @@ -191,29 +191,25 @@ int setup_test(int i) "for mlockall error %s\n", TC[i].edesc); return 1; } - if (tst_kvercmp(2, 6, 9) >= 0) { - ltpuser = getpwnam(nobody_uid); - if (seteuid(ltpuser->pw_uid) == -1) { - tst_brkm(TBROK, cleanup, "seteuid() " - "failed to change euid to %d " - "errno = %d : %s", - ltpuser->pw_uid, TEST_ERRNO, - strerror(TEST_ERRNO)); + ltpuser = getpwnam(nobody_uid); + if (seteuid(ltpuser->pw_uid) == -1) { + tst_brkm(TBROK, cleanup, "seteuid() " + "failed to change euid to %d " + "errno = %d : %s", + ltpuser->pw_uid, TEST_ERRNO, + strerror(TEST_ERRNO)); return 1; - } } return 0; case 1: - if (tst_kvercmp(2, 6, 9) >= 0) { - rl.rlim_max = 0; - rl.rlim_cur = 0; - if (setrlimit(RLIMIT_MEMLOCK, &rl) != 0) { - tst_resm(TWARN, "setrlimit failed to " - "set the resource for " - "RLIMIT_MEMLOCK to check for " - "mlockall error %s\n", TC[i].edesc); + rl.rlim_max = 0; + rl.rlim_cur = 0; + if (setrlimit(RLIMIT_MEMLOCK, &rl) != 0) { + tst_resm(TWARN, "setrlimit failed to " + "set the resource for " + "RLIMIT_MEMLOCK to check for " + "mlockall error %s\n", TC[i].edesc); return 1; - } } ltpuser = getpwnam(nobody_uid); if (seteuid(ltpuser->pw_uid) == -1) { diff --git a/testcases/kernel/syscalls/move_pages/move_pages09.c b/testcases/kernel/syscalls/move_pages/move_pages09.c index 5c2d8d320..308249146 100644 --- a/testcases/kernel/syscalls/move_pages/move_pages09.c +++ b/testcases/kernel/syscalls/move_pages/move_pages09.c @@ -102,25 +102,10 @@ int main(int argc, char **argv) ret = numa_move_pages(0, TEST_PAGES, pages, nodes, status, MPOL_MF_MOVE); - /* - * commit e78bbfa8262424417a29349a8064a535053912b9 - * Author: Brice Goglin - * Date: Sat Oct 18 20:27:15 2008 -0700 - * mm: stop returning -ENOENT from sys_move_pages() if nothing got migrated - */ - if ((tst_kvercmp(2, 6, 28)) >= 0) { - if (ret >= 0) - tst_resm(TPASS, "move_pages succeeded"); - else - tst_resm(TFAIL | TERRNO, "move_pages"); - } else { - if (ret == -1 && errno == ENOENT) - tst_resm(TPASS, "move_pages failed with " - "ENOENT as expected"); - else - tst_resm(TFAIL | TERRNO, "move_pages did not " - "fail with ENOENT ret: %d", ret); - } + if (ret >= 0) + tst_resm(TPASS, "move_pages succeeded"); + else + tst_resm(TFAIL | TERRNO, "move_pages"); free_pages(pages, TEST_PAGES); } diff --git a/testcases/kernel/syscalls/move_pages/move_pages_support.c b/testcases/kernel/syscalls/move_pages/move_pages_support.c index 717321a48..1604e91f6 100644 --- a/testcases/kernel/syscalls/move_pages/move_pages_support.c +++ b/testcases/kernel/syscalls/move_pages/move_pages_support.c @@ -400,13 +400,12 @@ void check_config(unsigned int min_nodes) if (ret < 0) tst_brkm(TBROK | TERRNO, NULL, "get_allowed_nodes(): %d", ret); - if (numa_available() < 0) { + if (numa_available() < 0) tst_brkm(TCONF, NULL, "NUMA support is not available"); - } else if (num_allowed_nodes < min_nodes) { + + if (num_allowed_nodes < min_nodes) { tst_brkm(TCONF, NULL, "at least %d allowed NUMA nodes" " are required", min_nodes); - } else if (tst_kvercmp(2, 6, 18) < 0) { - tst_brkm(TCONF, NULL, "2.6.18 or greater kernel required"); } #else tst_brkm(TCONF, NULL, NUMA_ERROR_MSG); diff --git a/testcases/kernel/syscalls/munmap/munmap03.c b/testcases/kernel/syscalls/munmap/munmap03.c index 3b88b531e..23875e7b3 100644 --- a/testcases/kernel/syscalls/munmap/munmap03.c +++ b/testcases/kernel/syscalls/munmap/munmap03.c @@ -127,13 +127,6 @@ static void test_einval2(void) char *addr = global_addr; size_t map_len = 0; - if (tst_kvercmp(2, 6, 12) < 0) { - tst_resm(TCONF, - "EINVAL error value test for this condition needs " - "kernel 2.6.12 or higher"); - return; - } - TEST(munmap(addr, map_len)); check_and_print(EINVAL); diff --git a/testcases/kernel/syscalls/open/open12.c b/testcases/kernel/syscalls/open/open12.c index 02ef5b5b0..2ec53ae15 100644 --- a/testcases/kernel/syscalls/open/open12.c +++ b/testcases/kernel/syscalls/open/open12.c @@ -89,14 +89,6 @@ static void setup(void) if (tst_path_has_mnt_flags(cleanup, NULL, mount_flags)) { const char *fs_type; - if ((tst_kvercmp(2, 6, 30)) < 0) { - tst_resm(TCONF, - "MS_STRICTATIME flags for mount(2) needs kernel 2.6.30 " - "or higher"); - skip_noatime = 1; - return; - } - fs_type = tst_dev_fs_type(); device = tst_acquire_device(cleanup); @@ -144,13 +136,6 @@ static void test_noatime(void) char read_buf; struct stat old_stat, new_stat; - if ((tst_kvercmp(2, 6, 8)) < 0) { - tst_resm(TCONF, - "O_NOATIME flags test for open(2) needs kernel 2.6.8 " - "or higher"); - return; - } - if (skip_noatime) { tst_resm(TCONF, "test O_NOATIME flag for open needs filesystems which " @@ -184,13 +169,6 @@ static void test_cloexec(void) int status; char buf[20]; - if ((tst_kvercmp(2, 6, 23)) < 0) { - tst_resm(TCONF, - "O_CLOEXEC flags test for open(2) needs kernel 2.6.23 " - "or higher"); - return; - } - TEST(open(TEST_FILE, O_RDWR | O_APPEND | O_CLOEXEC, 0777)); if (TEST_RETURN == -1) { diff --git a/testcases/kernel/syscalls/open/open13.c b/testcases/kernel/syscalls/open/open13.c index 3838221e1..e777a305d 100644 --- a/testcases/kernel/syscalls/open/open13.c +++ b/testcases/kernel/syscalls/open/open13.c @@ -95,11 +95,6 @@ int main(int ac, char **av) static void setup(void) { - if ((tst_kvercmp(2, 6, 39)) < 0) { - tst_brkm(TCONF, NULL, "This test can only run on kernels " - "that are 2.6.39 or higher"); - } - tst_sig(NOFORK, DEF_HANDLER, cleanup); tst_tmpdir(); diff --git a/testcases/kernel/syscalls/openat/openat02.c b/testcases/kernel/syscalls/openat/openat02.c index b0a6ff78f..98ef61e0d 100644 --- a/testcases/kernel/syscalls/openat/openat02.c +++ b/testcases/kernel/syscalls/openat/openat02.c @@ -144,12 +144,6 @@ void testfunc_cloexec(void) int status; char buf[20]; - if ((tst_kvercmp(2, 6, 23)) < 0) { - tst_resm(TCONF, "test O_CLOEXEC flags for openat " - "needs kernel 2.6.23 or higher"); - return; - } - TEST(openat(AT_FDCWD, TEST_FILE, O_CLOEXEC | O_RDWR, 0777)); if (TEST_RETURN == -1) { @@ -223,12 +217,6 @@ void testfunc_noatime(void) const char *flags[] = {"noatime", "relatime", NULL}; int ret; - if ((tst_kvercmp(2, 6, 8)) < 0) { - tst_resm(TCONF, "test O_NOATIME flags for openat " - "needs kernel 2.6.8 or higher"); - return; - } - ret = tst_path_has_mnt_flags(cleanup, NULL, flags); if (ret > 0) { tst_resm(TCONF, "test O_NOATIME flag for openat needs " diff --git a/testcases/kernel/syscalls/pipe2/pipe2_01.c b/testcases/kernel/syscalls/pipe2/pipe2_01.c index 6597162e7..87e81a455 100644 --- a/testcases/kernel/syscalls/pipe2/pipe2_01.c +++ b/testcases/kernel/syscalls/pipe2/pipe2_01.c @@ -54,10 +54,6 @@ static void verify_pipe2(unsigned int n) int get_flag = 0, i = 0; tst_res(TINFO, "%s ", tc->message); - if ((tc->flags == O_DIRECT) && (tst_kvercmp(3, 4, 0)) < 0) { - tst_res(TCONF, "O_DIRECT needs Linux 3.4 or newer"); - return; - } SAFE_PIPE2(fds, tc->flags); for (i = 0; i < 2; i++) { diff --git a/testcases/kernel/syscalls/remap_file_pages/remap_file_pages01.c b/testcases/kernel/syscalls/remap_file_pages/remap_file_pages01.c index 631db51a7..09143a2d0 100644 --- a/testcases/kernel/syscalls/remap_file_pages/remap_file_pages01.c +++ b/testcases/kernel/syscalls/remap_file_pages/remap_file_pages01.c @@ -113,15 +113,6 @@ int main(int ac, char **av) { int lc; -#if defined (__s390__) || (__s390x__) || (__ia64__) - /* Disables the test in case the kernel version is lower than 2.6.12 and arch is s390 */ - if ((tst_kvercmp(2, 6, 12)) < 0) { - tst_resm(TWARN, - "This test can only run on kernels that are 2.6.12 and higher"); - exit(0); - } -#endif - tst_parse_opts(ac, av, NULL, NULL); setup(); diff --git a/testcases/kernel/syscalls/remap_file_pages/remap_file_pages02.c b/testcases/kernel/syscalls/remap_file_pages/remap_file_pages02.c index 1d8f620ca..d296022ce 100644 --- a/testcases/kernel/syscalls/remap_file_pages/remap_file_pages02.c +++ b/testcases/kernel/syscalls/remap_file_pages/remap_file_pages02.c @@ -121,12 +121,6 @@ static void setup(void) { unsigned int i; -#if defined (__s390__) || (__s390x__) || (__ia64__) - if ((tst_kvercmp(2, 6, 12)) < 0) - tst_brk(TCONF, - "This test can only run on kernels that are 2.6.12 and higher"); -#endif - page_sz = getpagesize(); fd = SAFE_OPEN("cache", O_RDWR | O_CREAT | O_TRUNC, S_IRWXU); diff --git a/testcases/kernel/syscalls/renameat/renameat01.c b/testcases/kernel/syscalls/renameat/renameat01.c index 9df4b7086..3de103563 100644 --- a/testcases/kernel/syscalls/renameat/renameat01.c +++ b/testcases/kernel/syscalls/renameat/renameat01.c @@ -133,12 +133,6 @@ static void setup(void) const char *fs_type; int i; - if ((tst_kvercmp(2, 6, 16)) < 0) { - tst_brkm(TCONF, NULL, - "This test can only run on kernels that are " - "2.6.16 and higher"); - } - tst_require_root(); tst_sig(NOFORK, DEF_HANDLER, cleanup); diff --git a/testcases/kernel/syscalls/signalfd/signalfd01.c b/testcases/kernel/syscalls/signalfd/signalfd01.c index 3df941785..48a17a634 100644 --- a/testcases/kernel/syscalls/signalfd/signalfd01.c +++ b/testcases/kernel/syscalls/signalfd/signalfd01.c @@ -263,12 +263,6 @@ int main(int argc, char **argv) int lc; int sfd; - if ((tst_kvercmp(2, 6, 22)) < 0) { - tst_resm(TWARN, - "This test can only run on kernels that are 2.6.22 and higher"); - exit(0); - } - tst_parse_opts(argc, argv, NULL, NULL); setup(); diff --git a/testcases/kernel/syscalls/signalfd4/signalfd4_01.c b/testcases/kernel/syscalls/signalfd4/signalfd4_01.c index 7909f587a..76f3be27f 100644 --- a/testcases/kernel/syscalls/signalfd4/signalfd4_01.c +++ b/testcases/kernel/syscalls/signalfd4/signalfd4_01.c @@ -129,11 +129,6 @@ int main(int argc, char *argv[]) int lc; tst_parse_opts(argc, argv, NULL, NULL); - if ((tst_kvercmp(2, 6, 27)) < 0) { - tst_brkm(TCONF, - NULL, - "This test can only run on kernels that are 2.6.27 and higher"); - } setup(); for (lc = 0; TEST_LOOPING(lc); ++lc) { diff --git a/testcases/kernel/syscalls/signalfd4/signalfd4_02.c b/testcases/kernel/syscalls/signalfd4/signalfd4_02.c index 4c9c2022a..18f86b4a7 100644 --- a/testcases/kernel/syscalls/signalfd4/signalfd4_02.c +++ b/testcases/kernel/syscalls/signalfd4/signalfd4_02.c @@ -125,11 +125,6 @@ int main(int argc, char *argv[]) int lc; tst_parse_opts(argc, argv, NULL, NULL); - if ((tst_kvercmp(2, 6, 27)) < 0) { - tst_brkm(TCONF, - NULL, - "This test can only run on kernels that are 2.6.27 and higher"); - } setup(); for (lc = 0; TEST_LOOPING(lc); ++lc) { diff --git a/testcases/kernel/syscalls/socket/socket01.c b/testcases/kernel/syscalls/socket/socket01.c index 467154834..4724609d1 100644 --- a/testcases/kernel/syscalls/socket/socket01.c +++ b/testcases/kernel/syscalls/socket/socket01.c @@ -66,27 +66,7 @@ static void verify_socket(unsigned int n) tst_res(TPASS, "%s successful", tc->desc); } -/* - * See: - * commit 86c8f9d158f68538a971a47206a46a22c7479bac - * ... - * [IPV4] Fix EPROTONOSUPPORT error in inet_create - */ -static void setup(void) -{ - unsigned int i; - - if (tst_kvercmp(2, 6, 16) >= 0) - return; - - for (i = 0; i < ARRAY_SIZE(tdat); i++) { - if (tdat[i].experrno == EPROTONOSUPPORT) - tdat[i].experrno = ESOCKTNOSUPPORT; - } -} - static struct tst_test test = { .tcnt = ARRAY_SIZE(tdat), - .setup = setup, .test = verify_socket }; diff --git a/testcases/kernel/syscalls/socketpair/socketpair01.c b/testcases/kernel/syscalls/socketpair/socketpair01.c index 7c301f681..675eb535d 100644 --- a/testcases/kernel/syscalls/socketpair/socketpair01.c +++ b/testcases/kernel/syscalls/socketpair/socketpair01.c @@ -70,27 +70,7 @@ static void verify_socketpair(unsigned int n) tst_res(TPASS, "%s successful", tc->desc); } -/* - * See: - * commit 86c8f9d158f68538a971a47206a46a22c7479bac - * ... - * [IPV4] Fix EPROTONOSUPPORT error in inet_create - */ -static void setup(void) -{ - unsigned int i; - - if (tst_kvercmp(2, 6, 16) >= 0) - return; - - for (i = 0; i < ARRAY_SIZE(tdat); i++) { - if (tdat[i].experrno == EPROTONOSUPPORT) - tdat[i].experrno = ESOCKTNOSUPPORT; - } -} - static struct tst_test test = { .tcnt = ARRAY_SIZE(tdat), - .setup = setup, .test = verify_socketpair }; diff --git a/testcases/kernel/syscalls/sockioctl/sockioctl01.c b/testcases/kernel/syscalls/sockioctl/sockioctl01.c index 486236af9..be09910a2 100644 --- a/testcases/kernel/syscalls/sockioctl/sockioctl01.c +++ b/testcases/kernel/syscalls/sockioctl/sockioctl01.c @@ -185,13 +185,7 @@ static void setup0(void) "errno: %s", strerror(errno)); } - /* - * kernel commit 46ce341b2f176c2611f12ac390adf862e932eb02 - * changed -EINVAL to -ENOIOCTLCMD, so vfs_ioctl now - * returns -ENOTTY. - */ - if ((tst_kvercmp(3, 5, 0)) >= 0) - tdat[testno].experrno = ENOTTY; + tdat[testno].experrno = ENOTTY; } } @@ -211,8 +205,7 @@ static void setup1(void) sinlen = sizeof(fsin1); if (strncmp(tdat[testno].desc, "ATMARK on UDP", 14) == 0) { - if ((tst_kvercmp(2, 6, 39)) >= 0) - tdat[testno].experrno = ENOTTY; + tdat[testno].experrno = ENOTTY; } } diff --git a/testcases/kernel/syscalls/splice/splice01.c b/testcases/kernel/syscalls/splice/splice01.c index 82407743f..f5b2cbe17 100644 --- a/testcases/kernel/syscalls/splice/splice01.c +++ b/testcases/kernel/syscalls/splice/splice01.c @@ -79,12 +79,6 @@ static void setup(void) { int i; - if (tst_fs_type(".") == TST_NFS_MAGIC) { - if (tst_kvercmp(2, 6, 32) < 0) - tst_brk(TCONF, "Cannot do splice on a file" - " on NFS filesystem before 2.6.32"); - } - for (i = 0; i < TEST_BLOCK_SIZE; i++) buffer[i] = i & 0xff; diff --git a/testcases/kernel/syscalls/symlinkat/symlinkat01.c b/testcases/kernel/syscalls/symlinkat/symlinkat01.c index 711f10aec..d510872f0 100644 --- a/testcases/kernel/syscalls/symlinkat/symlinkat01.c +++ b/testcases/kernel/syscalls/symlinkat/symlinkat01.c @@ -134,13 +134,6 @@ int main(int ac, char **av) int lc; int i; - /* Disable test if the version of the kernel is less than 2.6.16 */ - if ((tst_kvercmp(2, 6, 16)) < 0) { - tst_resm(TWARN, "This test can only run on kernels that are "); - tst_resm(TWARN, "2.6.16 and higher"); - exit(0); - } - tst_parse_opts(ac, av, NULL, NULL); setup(); diff --git a/testcases/kernel/syscalls/sysctl/sysctl03.c b/testcases/kernel/syscalls/sysctl/sysctl03.c index ea41f9d09..73f98f0b1 100644 --- a/testcases/kernel/syscalls/sysctl/sysctl03.c +++ b/testcases/kernel/syscalls/sysctl/sysctl03.c @@ -68,14 +68,10 @@ static void verify_sysctl(void) static void setup(void) { - if ((tst_kvercmp(2, 6, 32)) <= 0) { - exp_eno = EPERM; - } else { - /* Look above this warning. */ - tst_res(TINFO, - "this test's results are based on potentially undocumented behavior in the kernel. read the NOTE in the source file for more details"); - exp_eno = EACCES; - } + /* Look above this warning. */ + tst_res(TINFO, + "this test's results are based on potentially undocumented behavior in the kernel. read the NOTE in the source file for more details"); + exp_eno = EACCES; } static void do_test(void) diff --git a/testcases/kernel/syscalls/tee/tee01.c b/testcases/kernel/syscalls/tee/tee01.c index dd4d8bfa5..87a7ecd09 100644 --- a/testcases/kernel/syscalls/tee/tee01.c +++ b/testcases/kernel/syscalls/tee/tee01.c @@ -84,12 +84,6 @@ static void setup(void) { int i; - if (tst_fs_type(".") == TST_NFS_MAGIC) { - if ((tst_kvercmp(2, 6, 32)) < 0) - tst_brk(TCONF, "Cannot do tee on a file" - " on NFS filesystem before 2.6.32"); - } - for (i = 0; i < TEST_BLOCK_SIZE; i++) buffer[i] = i & 0xff; diff --git a/testcases/kernel/syscalls/timer_create/timer_create01.c b/testcases/kernel/syscalls/timer_create/timer_create01.c index 1cb9a9fdc..d56e68c23 100644 --- a/testcases/kernel/syscalls/timer_create/timer_create01.c +++ b/testcases/kernel/syscalls/timer_create/timer_create01.c @@ -59,16 +59,6 @@ static void run(unsigned int n) evp.sigev_signo = nt->sigev_signo; evp.sigev_notify = nt->sigev_notify; - if (clock == CLOCK_PROCESS_CPUTIME_ID || - clock == CLOCK_THREAD_CPUTIME_ID) { - /* (PROCESS_CPUTIME_ID & - * THREAD_CPUTIME_ID) - * is not supported on kernel versions - * lower than 2.6.12 - */ - if (!have_cputime_timers()) - continue; - } if (clock == CLOCK_MONOTONIC_RAW) continue; diff --git a/testcases/kernel/syscalls/timer_delete/timer_delete01.c b/testcases/kernel/syscalls/timer_delete/timer_delete01.c index 6e5fc9940..bdc2e44cc 100644 --- a/testcases/kernel/syscalls/timer_delete/timer_delete01.c +++ b/testcases/kernel/syscalls/timer_delete/timer_delete01.c @@ -30,12 +30,6 @@ static void run(void) for (i = 0; i < CLOCKS_DEFINED; ++i) { clock_t clock = clock_list[i]; - if (clock == CLOCK_PROCESS_CPUTIME_ID || - clock == CLOCK_THREAD_CPUTIME_ID) { - if (!have_cputime_timers()) - continue; - } - tst_res(TINFO, "Testing %s", get_clock_str(clock)); TEST(tst_syscall(__NR_timer_create, clock, NULL, &timer_id)); diff --git a/testcases/kernel/syscalls/timer_settime/timer_settime01.c b/testcases/kernel/syscalls/timer_settime/timer_settime01.c index 599ef2891..5aee8b38a 100644 --- a/testcases/kernel/syscalls/timer_settime/timer_settime01.c +++ b/testcases/kernel/syscalls/timer_settime/timer_settime01.c @@ -98,12 +98,6 @@ static void run(unsigned int n) for (i = 0; i < CLOCKS_DEFINED; ++i) { clock_t clock = clock_list[i]; - if (clock == CLOCK_PROCESS_CPUTIME_ID || - clock == CLOCK_THREAD_CPUTIME_ID) { - if (!have_cputime_timers()) - continue; - } - TEST(tst_syscall(__NR_timer_create, clock, NULL, &timer)); if (TST_RET != 0) { if (possibly_unsupported(clock) && diff --git a/testcases/kernel/syscalls/timer_settime/timer_settime02.c b/testcases/kernel/syscalls/timer_settime/timer_settime02.c index 564f1c2ce..3309a81ad 100644 --- a/testcases/kernel/syscalls/timer_settime/timer_settime02.c +++ b/testcases/kernel/syscalls/timer_settime/timer_settime02.c @@ -87,12 +87,6 @@ static void run(unsigned int n) for (i = 0; i < CLOCKS_DEFINED; ++i) { clock_t clock = clock_list[i]; - if (clock == CLOCK_PROCESS_CPUTIME_ID || - clock == CLOCK_THREAD_CPUTIME_ID) { - if (!have_cputime_timers()) - continue; - } - /* Init temporary timer */ TEST(tst_syscall(__NR_timer_create, clock, NULL, &timer)); if (TST_RET != 0) { diff --git a/testcases/kernel/syscalls/timerfd/timerfd02.c b/testcases/kernel/syscalls/timerfd/timerfd02.c index 9d2e3ff3c..936cdbc53 100644 --- a/testcases/kernel/syscalls/timerfd/timerfd02.c +++ b/testcases/kernel/syscalls/timerfd/timerfd02.c @@ -127,11 +127,6 @@ int main(int argc, char *argv[]) int lc; tst_parse_opts(argc, argv, NULL, NULL); - if ((tst_kvercmp(2, 6, 27)) < 0) { - tst_brkm(TCONF, - NULL, - "This test can only run on kernels that are 2.6.27 and higher"); - } setup(); for (lc = 0; TEST_LOOPING(lc); ++lc) { diff --git a/testcases/kernel/syscalls/timerfd/timerfd03.c b/testcases/kernel/syscalls/timerfd/timerfd03.c index ca70d1759..89dec325f 100644 --- a/testcases/kernel/syscalls/timerfd/timerfd03.c +++ b/testcases/kernel/syscalls/timerfd/timerfd03.c @@ -123,11 +123,6 @@ int main(int argc, char *argv[]) int lc; tst_parse_opts(argc, argv, NULL, NULL); - if ((tst_kvercmp(2, 6, 27)) < 0) { - tst_brkm(TCONF, - NULL, - "This test can only run on kernels that are 2.6.27 and higher"); - } setup(); for (lc = 0; TEST_LOOPING(lc); ++lc) { diff --git a/testcases/kernel/syscalls/timerfd/timerfd_create01.c b/testcases/kernel/syscalls/timerfd/timerfd_create01.c index b9fe38954..3d70b84f0 100644 --- a/testcases/kernel/syscalls/timerfd/timerfd_create01.c +++ b/testcases/kernel/syscalls/timerfd/timerfd_create01.c @@ -66,9 +66,6 @@ int main(int argc, char *argv[]) static void setup(void) { - if ((tst_kvercmp(2, 6, 25)) < 0) - tst_brkm(TCONF, NULL, "This test needs kernel 2.6.25 or newer"); - tst_sig(NOFORK, DEF_HANDLER, cleanup); TEST_PAUSE; diff --git a/testcases/network/netstress/netstress.c b/testcases/network/netstress/netstress.c index 7c222531d..6a888f2ee 100644 --- a/testcases/network/netstress/netstress.c +++ b/testcases/network/netstress/netstress.c @@ -882,9 +882,6 @@ static void setup(void) if (!clients_num) clients_num = sysconf(_SC_NPROCESSORS_ONLN); - if (tfo_value > 0 && tst_kvercmp(3, 7, 0) < 0) - tst_brk(TCONF, "Test must be run with kernel 3.7 or newer"); - if (busy_poll >= 0 && tst_kvercmp(3, 11, 0) < 0) tst_brk(TCONF, "Test must be run with kernel 3.11 or newer"); diff --git a/testcases/open_posix_testsuite/Makefile b/testcases/open_posix_testsuite/Makefile index affabf9f7..8b4c8c0a2 100644 --- a/testcases/open_posix_testsuite/Makefile +++ b/testcases/open_posix_testsuite/Makefile @@ -27,10 +27,6 @@ TEST_MAKE= env $(TEST_MAKE_ENV) $(MAKE) -k all: conformance-all functional-all stress-all tools-all -ifeq ($(shell uname -s), Linux) -include Makefile.linux -endif - AUTOGENERATED_FILES = include/mk/config.mk .PHONY: ac-clean diff --git a/testcases/open_posix_testsuite/Makefile.linux b/testcases/open_posix_testsuite/Makefile.linux deleted file mode 100644 index 77e20a958..000000000 --- a/testcases/open_posix_testsuite/Makefile.linux +++ /dev/null @@ -1,20 +0,0 @@ -cmd_disable = @set -e; \ - echo "Disabling: $(1)"; \ - echo "\#!/bin/sh" > $(1); \ - echo "echo $(1) skipped" >> $(1); \ - echo "echo $(2)" >> $(1); \ - echo "exit 0" >> $(1); \ - chmod a+x $(1) - -BROKEN := - -kver_cmp = $(shell $(top_srcdir)/scripts/tst_kvercmp.sh 2 6 22) -ifeq ($(kver_cmp), 1) -BROKEN += t_sigaction_16-1 -endif - -filter-known-fails: $(BROKEN) - -t_sigaction_16-1: - $(call cmd_disable,conformance/interfaces/sigaction/sigaction_16-1.run-test, \ - This fails on old linux because sem_wait always be interrupted by a signal.) From patchwork Mon Dec 12 11:40:29 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Yang Xu \\(Fujitsu\\)" X-Patchwork-Id: 1714916 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.linux.it (client-ip=2001:1418:10:5::2; helo=picard.linux.it; envelope-from=ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=fujitsu.com header.i=@fujitsu.com header.a=rsa-sha256 header.s=170520fj header.b=VyAnSQxV; dkim-atps=neutral Received: from picard.linux.it (picard.linux.it [IPv6:2001:1418:10:5::2]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NVynT01m8z23yh for ; Mon, 12 Dec 2022 21:40:12 +1100 (AEDT) Received: from picard.linux.it (localhost [IPv6:::1]) by picard.linux.it (Postfix) with ESMTP id E70553CBE6F for ; Mon, 12 Dec 2022 11:40:10 +0100 (CET) X-Original-To: ltp@lists.linux.it Delivered-To: ltp@picard.linux.it Received: from in-5.smtp.seeweb.it (in-5.smtp.seeweb.it [IPv6:2001:4b78:1:20::5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384)) (No client certificate requested) by picard.linux.it (Postfix) with ESMTPS id 5DC133CBE6A for ; Mon, 12 Dec 2022 11:39:46 +0100 (CET) Received: from mail1.bemta32.messagelabs.com (mail1.bemta32.messagelabs.com [195.245.230.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by in-5.smtp.seeweb.it (Postfix) with ESMTPS id 557BB600664 for ; Mon, 12 Dec 2022 11:39:44 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fujitsu.com; s=170520fj; t=1670841583; i=@fujitsu.com; bh=Nsp4gY/5nNxAzet9rRgkcdkiWojlLAdjUG9aSIPqUG0=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=VyAnSQxV6kgapcSZlzcpq1k9iqHbT3eYIk7r0QgvSJvxKoOtynEi8SW7pKgrIUr/1 KTWoPnX1VjkXFLkPdeDL6y6k/Ligiwtc9Ixzvio6Mtxq6TK4UWISIUBeeaq7M/zY5r ZKa/uO7Wv/y4wm0BTEP5uccXnyULhUByiljW66SriqWA3pCo5nbHuCNLl3SF/Xe/j/ KqBm454leu2oGEIAX4WHKz4usi9MhLjbkVIkEmN0Kp5m8DjtimMEHPBLq03vxGpRDr Ze8GxWweFeC0GuLKDfrCrK78gTs/jjUE+N3aBj1Mf+E4jN2K/fywl1/JV2lv88MVA5 AmYXrvzHMnVKA== X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrBIsWRWlGSWpSXmKPExsViZ8ORpPuOZXq ywcZXBhYrvu9gdGD02Pd7HWsAYxRrZl5SfkUCa8bP49OYC050MVV8ex7QwPjrMWMXIxeHkMAp Rok/k6YzdTFyAjl7mSQa7zlCJPYwSnRfnsUGkmAT0JR41rmAGcQWEZCQ6Gh4yw5iMwuoSyyf9 AusWVjAW6Kn9SUjiM0ioCpx4eAasHpeAQ+JY7f6wOolBBQkpjx8DxbnFPCU+Hb3EivEYg+JVb NmsEDUC0qcnPmEBWK+hMTBFy+YIXoVJS51fGOEsCskZs1qY4Kw1SSuntvEPIFRcBaS9llI2hc wMq1iNC1OLSpLLdI10UsqykzPKMlNzMzRS6zSTdRLLdUtTy0u0TXUSywv1kstLtYrrsxNzknR y0st2cQIDN6UYjafHYz/lv7RO8QoycGkJMqb/mdashBfUn5KZUZicUZ8UWlOavEhRhkODiUJ3 oAvQDnBotT01Iq0zBxgJMGkJTh4lER4jzFNTxbiLS5IzC3OTIdInWI05ljbcGAvM8fU2f/2Mw ux5OXnpUqJ8woxA5UKgJRmlObBDYJF+CVGWSlhXkYGBgYhnoLUotzMElT5V4ziHIxKwrzbQRb yZOaVwO17BXQKE9ApUS+ngpxSkoiQkmpgYt2v3lFr399+yMw0bfXf9BsXjKOtWU0333f1u8ic myBj8qM/Lnb2gsJv5Tm3it2SLDM1bnnaKHcZyLk55mie6K5z3XGrw/X4OWu7225Jp48t3Z/Ic c/LkE05in/O6f5Adt8zPv8E84sUXlhfM3k1N/nKiq5vV+wnZt9SDLgXkJsRZX9t9UapmNL02Q 4ChVWdmtYivJPtpOa/1ep5vjPYxLTrRtPBtjM2c7/WRcTsmPArv1TulpZ6Gc/Lp5W7H+412jP Pof/m8qaQrDfXP23Wa1M5u/kWs7hEapKO8pZah8TvXnPunDJ02/JK5LdFmaD2gQU8OYwV61lf /a1OkHfRPtz5YcPc/d9eM7G/2qLEUpyRaKjFXFScCACjRs1eawMAAA== X-Env-Sender: xuyang2018.jy@fujitsu.com X-Msg-Ref: server-17.tower-587.messagelabs.com!1670841582!310961!1 X-Originating-IP: [62.60.8.98] X-SYMC-ESS-Client-Auth: outbound-route-from=pass X-StarScan-Received: X-StarScan-Version: 9.101.2; banners=-,-,- X-VirusChecked: Checked Received: (qmail 25290 invoked from network); 12 Dec 2022 10:39:42 -0000 Received: from unknown (HELO n03ukasimr03.n03.fujitsu.local) (62.60.8.98) by server-17.tower-587.messagelabs.com with ECDHE-RSA-AES256-GCM-SHA384 encrypted SMTP; 12 Dec 2022 10:39:42 -0000 Received: from n03ukasimr03.n03.fujitsu.local (localhost [127.0.0.1]) by n03ukasimr03.n03.fujitsu.local (Postfix) with ESMTP id 6524D1B6 for ; Mon, 12 Dec 2022 10:39:42 +0000 (GMT) Received: from R01UKEXCASM126.r01.fujitsu.local (R01UKEXCASM126 [10.183.43.178]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by n03ukasimr03.n03.fujitsu.local (Postfix) with ESMTPS id 598DD1AD for ; Mon, 12 Dec 2022 10:39:42 +0000 (GMT) Received: from localhost.localdomain (10.167.220.84) by R01UKEXCASM126.r01.fujitsu.local (10.183.43.178) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Mon, 12 Dec 2022 10:39:40 +0000 From: Yang Xu To: Date: Mon, 12 Dec 2022 19:40:29 +0800 Message-ID: <1670845229-1981-4-git-send-email-xuyang2018.jy@fujitsu.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1670845229-1981-1-git-send-email-xuyang2018.jy@fujitsu.com> References: <1670845229-1981-1-git-send-email-xuyang2018.jy@fujitsu.com> MIME-Version: 1.0 X-Originating-IP: [10.167.220.84] X-ClientProxiedBy: G08CNEXCHPEKD07.g08.fujitsu.local (10.167.33.80) To R01UKEXCASM126.r01.fujitsu.local (10.183.43.178) X-Virus-Scanned: clamav-milter 0.102.4 at in-5.smtp.seeweb.it X-Virus-Status: Clean X-Spam-Status: No, score=0.1 required=7.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=disabled version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on in-5.smtp.seeweb.it Subject: [LTP] [PATCH v1 4/4] Remove old kernel version check when using min_kver X-BeenThere: ltp@lists.linux.it X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux Test Project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it Sender: "ltp" The oldest supported kernel version check is 3.10, so remove them. Signed-off-by: Yang Xu --- doc/c-test-api.txt | 2 +- testcases/cve/cve-2016-10044.c | 1 - testcases/cve/cve-2016-7117.c | 1 - testcases/cve/meltdown.c | 1 - testcases/kernel/controllers/memcg/regression/memcg_test_3.c | 1 - testcases/kernel/logging/kmsg/kmsg01.c | 1 - testcases/kernel/mem/cpuset/cpuset01.c | 1 - testcases/kernel/mem/hugetlb/hugemmap/hugemmap06.c | 1 - testcases/kernel/mem/ksm/ksm01.c | 1 - testcases/kernel/mem/ksm/ksm02.c | 1 - testcases/kernel/mem/ksm/ksm03.c | 1 - testcases/kernel/mem/ksm/ksm04.c | 1 - testcases/kernel/mem/ksm/ksm05.c | 1 - testcases/kernel/syscalls/clone/clone09.c | 1 - testcases/kernel/syscalls/epoll_create1/epoll_create1_01.c | 1 - testcases/kernel/syscalls/epoll_ctl/epoll_ctl03.c | 1 - testcases/kernel/syscalls/fadvise/posix_fadvise04.c | 1 - testcases/kernel/syscalls/fchmodat/fchmodat01.c | 1 - testcases/kernel/syscalls/fcntl/fcntl35.c | 1 - testcases/kernel/syscalls/futex/futex_wake04.c | 1 - testcases/kernel/syscalls/getrusage/getrusage03.c | 1 - testcases/kernel/syscalls/getxattr/getxattr05.c | 1 - testcases/kernel/syscalls/ipc/msgrcv/msgrcv03.c | 1 - testcases/kernel/syscalls/kcmp/kcmp01.c | 1 - testcases/kernel/syscalls/kcmp/kcmp02.c | 1 - testcases/kernel/syscalls/kcmp/kcmp03.c | 1 - testcases/kernel/syscalls/keyctl/keyctl08.c | 1 - testcases/kernel/syscalls/madvise/madvise05.c | 1 - testcases/kernel/syscalls/madvise/madvise06.c | 1 - testcases/kernel/syscalls/madvise/madvise07.c | 1 - testcases/kernel/syscalls/madvise/madvise08.c | 1 - testcases/kernel/syscalls/migrate_pages/migrate_pages03.c | 1 - testcases/kernel/syscalls/mlock2/mlock201.c | 1 - testcases/kernel/syscalls/mlock2/mlock202.c | 1 - testcases/kernel/syscalls/mlock2/mlock203.c | 1 - testcases/kernel/syscalls/mmap/mmap12.c | 1 - testcases/kernel/syscalls/move_pages/move_pages12.c | 1 - testcases/kernel/syscalls/msync/msync04.c | 1 - testcases/kernel/syscalls/pipe2/pipe2_04.c | 1 - testcases/kernel/syscalls/preadv/preadv01.c | 1 - testcases/kernel/syscalls/preadv/preadv02.c | 1 - testcases/kernel/syscalls/preadv/preadv03.c | 1 - testcases/kernel/syscalls/pwritev/pwritev01.c | 1 - testcases/kernel/syscalls/pwritev/pwritev02.c | 1 - testcases/kernel/syscalls/pwritev/pwritev03.c | 1 - testcases/kernel/syscalls/recvmsg/recvmsg02.c | 1 - testcases/kernel/syscalls/sendfile/sendfile08.c | 1 - testcases/kernel/syscalls/sendfile/sendfile09.c | 1 - testcases/kernel/syscalls/setsockopt/setsockopt02.c | 1 - testcases/kernel/syscalls/setsockopt/setsockopt03.c | 1 - testcases/kernel/syscalls/socket/socket02.c | 1 - testcases/kernel/syscalls/socketpair/socketpair02.c | 1 - testcases/kernel/syscalls/splice/splice01.c | 1 - testcases/kernel/syscalls/splice/splice02.c | 1 - testcases/kernel/syscalls/splice/splice03.c | 1 - testcases/kernel/syscalls/splice/splice04.c | 1 - testcases/kernel/syscalls/splice/splice05.c | 1 - testcases/kernel/syscalls/switch/endian_switch01.c | 1 - testcases/kernel/syscalls/tee/tee01.c | 1 - testcases/kernel/syscalls/tee/tee02.c | 1 - testcases/kernel/syscalls/timerfd/timerfd01.c | 1 - testcases/kernel/syscalls/timerfd/timerfd_gettime01.c | 1 - testcases/kernel/syscalls/timerfd/timerfd_settime01.c | 1 - testcases/kernel/syscalls/timerfd/timerfd_settime02.c | 1 - testcases/kernel/syscalls/unlinkat/unlinkat01.c | 1 - testcases/kernel/syscalls/vmsplice/vmsplice01.c | 1 - testcases/kernel/syscalls/vmsplice/vmsplice02.c | 1 - testcases/kernel/syscalls/vmsplice/vmsplice03.c | 1 - testcases/kernel/syscalls/vmsplice/vmsplice04.c | 1 - 69 files changed, 1 insertion(+), 69 deletions(-) diff --git a/doc/c-test-api.txt b/doc/c-test-api.txt index e6d121dce..b15321ca2 100644 --- a/doc/c-test-api.txt +++ b/doc/c-test-api.txt @@ -559,7 +559,7 @@ static struct tst_test test = { Testcases for newly added kernel functionality require kernel newer than a certain version to run. All you need to skip a test on older kernels is to set the '.min_kver' string in the 'struct tst_test' to a minimal required -kernel version, e.g. '.min_kver = "2.6.30"'. +kernel version, e.g. '.min_kver = "4.10.0"'. For more complicated operations such as skipping a test for a certain range of kernel versions, following functions could be used: diff --git a/testcases/cve/cve-2016-10044.c b/testcases/cve/cve-2016-10044.c index b0a329d83..9ac644fc2 100644 --- a/testcases/cve/cve-2016-10044.c +++ b/testcases/cve/cve-2016-10044.c @@ -61,7 +61,6 @@ found_mapping: static struct tst_test test = { .test_all = run, .cleanup = cleanup, - .min_kver = "2.6.8", .tags = (const struct tst_tag[]) { {"linux-git", "22f6b4d34fcf"}, {"CVE", "2016-10044"}, diff --git a/testcases/cve/cve-2016-7117.c b/testcases/cve/cve-2016-7117.c index 64bf0a85e..109333985 100644 --- a/testcases/cve/cve-2016-7117.c +++ b/testcases/cve/cve-2016-7117.c @@ -149,7 +149,6 @@ static struct tst_test test = { .test_all = run, .setup = setup, .cleanup = cleanup, - .min_kver = "2.6.33", .max_runtime = 60, .tags = (const struct tst_tag[]) { {"linux-git", "a2e2725541fa"}, diff --git a/testcases/cve/meltdown.c b/testcases/cve/meltdown.c index cd16b0fb2..398e496a9 100644 --- a/testcases/cve/meltdown.c +++ b/testcases/cve/meltdown.c @@ -377,7 +377,6 @@ static struct tst_test test = { .setup = setup, .test_all = run, .cleanup = cleanup, - .min_kver = "2.6.32", .supported_archs = (const char *const []) { "x86", "x86_64", diff --git a/testcases/kernel/controllers/memcg/regression/memcg_test_3.c b/testcases/kernel/controllers/memcg/regression/memcg_test_3.c index 4bf4270bb..f29c2bea5 100644 --- a/testcases/kernel/controllers/memcg/regression/memcg_test_3.c +++ b/testcases/kernel/controllers/memcg/regression/memcg_test_3.c @@ -81,7 +81,6 @@ static void cleanup(void) static struct tst_test test = { .needs_root = 1, .forks_child = 1, - .min_kver = "2.6.24", .setup = setup, .cleanup = cleanup, .test_all = do_test, diff --git a/testcases/kernel/logging/kmsg/kmsg01.c b/testcases/kernel/logging/kmsg/kmsg01.c index bf2de5741..ba8179d5a 100644 --- a/testcases/kernel/logging/kmsg/kmsg01.c +++ b/testcases/kernel/logging/kmsg/kmsg01.c @@ -573,5 +573,4 @@ static struct tst_test test = { .cleanup = cleanup, .needs_root = 1, .test_all = test_kmsg, - .min_kver = "3.5.0" }; diff --git a/testcases/kernel/mem/cpuset/cpuset01.c b/testcases/kernel/mem/cpuset/cpuset01.c index 6e9691edb..956ac30c8 100644 --- a/testcases/kernel/mem/cpuset/cpuset01.c +++ b/testcases/kernel/mem/cpuset/cpuset01.c @@ -175,7 +175,6 @@ static struct tst_test test = { .forks_child = 1, .setup = setup, .test_all = test_cpuset, - .min_kver = "2.6.32", .needs_cgroup_ctrls = (const char *const []){ "cpuset", NULL }, }; diff --git a/testcases/kernel/mem/hugetlb/hugemmap/hugemmap06.c b/testcases/kernel/mem/hugetlb/hugemmap/hugemmap06.c index 91dfa0616..79bea8e8b 100644 --- a/testcases/kernel/mem/hugetlb/hugemmap/hugemmap06.c +++ b/testcases/kernel/mem/hugetlb/hugemmap/hugemmap06.c @@ -114,7 +114,6 @@ static void do_mmap(unsigned int j LTP_ATTRIBUTE_UNUSED) } static struct tst_test test = { - .min_kver = "2.6.32", .needs_root = 1, .tcnt = LOOP, .needs_tmpdir = 1, diff --git a/testcases/kernel/mem/ksm/ksm01.c b/testcases/kernel/mem/ksm/ksm01.c index fafa2da71..bcd095865 100644 --- a/testcases/kernel/mem/ksm/ksm01.c +++ b/testcases/kernel/mem/ksm/ksm01.c @@ -93,5 +93,4 @@ static struct tst_test test = { NULL }, .test_all = verify_ksm, - .min_kver = "2.6.32", }; diff --git a/testcases/kernel/mem/ksm/ksm02.c b/testcases/kernel/mem/ksm/ksm02.c index b5c90464e..bce639dce 100644 --- a/testcases/kernel/mem/ksm/ksm02.c +++ b/testcases/kernel/mem/ksm/ksm02.c @@ -114,7 +114,6 @@ static struct tst_test test = { NULL }, .test_all = verify_ksm, - .min_kver = "2.6.32", .max_runtime = 32, .needs_cgroup_ctrls = (const char *const []){ "cpuset", NULL }, }; diff --git a/testcases/kernel/mem/ksm/ksm03.c b/testcases/kernel/mem/ksm/ksm03.c index 94029054f..4a733269f 100644 --- a/testcases/kernel/mem/ksm/ksm03.c +++ b/testcases/kernel/mem/ksm/ksm03.c @@ -96,6 +96,5 @@ static struct tst_test test = { NULL }, .test_all = verify_ksm, - .min_kver = "2.6.32", .needs_cgroup_ctrls = (const char *const []){ "memory", NULL }, }; diff --git a/testcases/kernel/mem/ksm/ksm04.c b/testcases/kernel/mem/ksm/ksm04.c index 2302a2a1d..4f1f2f721 100644 --- a/testcases/kernel/mem/ksm/ksm04.c +++ b/testcases/kernel/mem/ksm/ksm04.c @@ -116,7 +116,6 @@ static struct tst_test test = { NULL }, .test_all = verify_ksm, - .min_kver = "2.6.32", .max_runtime = 32, .needs_cgroup_ctrls = (const char *const []){ "memory", "cpuset", NULL diff --git a/testcases/kernel/mem/ksm/ksm05.c b/testcases/kernel/mem/ksm/ksm05.c index c4cb779aa..25f3435b2 100644 --- a/testcases/kernel/mem/ksm/ksm05.c +++ b/testcases/kernel/mem/ksm/ksm05.c @@ -87,7 +87,6 @@ static struct tst_test test = { .needs_root = 1, .forks_child = 1, .test_all = test_ksm, - .min_kver = "2.6.32", .save_restore = (const struct tst_path_val[]) { {"/sys/kernel/mm/ksm/run", "1", TST_SR_TBROK}, {} diff --git a/testcases/kernel/syscalls/clone/clone09.c b/testcases/kernel/syscalls/clone/clone09.c index e4691f513..37528e4b6 100644 --- a/testcases/kernel/syscalls/clone/clone09.c +++ b/testcases/kernel/syscalls/clone/clone09.c @@ -87,5 +87,4 @@ static struct tst_test test = { .setup = setup, .cleanup = cleanup, .needs_root = 1, - .min_kver = "2.6.24", }; diff --git a/testcases/kernel/syscalls/epoll_create1/epoll_create1_01.c b/testcases/kernel/syscalls/epoll_create1/epoll_create1_01.c index ed359d434..6d2bf2a30 100644 --- a/testcases/kernel/syscalls/epoll_create1/epoll_create1_01.c +++ b/testcases/kernel/syscalls/epoll_create1/epoll_create1_01.c @@ -44,7 +44,6 @@ static void run(unsigned int n) } static struct tst_test test = { - .min_kver = "2.6.27", .tcnt = ARRAY_SIZE(tc), .test = run, }; diff --git a/testcases/kernel/syscalls/epoll_ctl/epoll_ctl03.c b/testcases/kernel/syscalls/epoll_ctl/epoll_ctl03.c index e96960ba9..c92b0b62e 100644 --- a/testcases/kernel/syscalls/epoll_ctl/epoll_ctl03.c +++ b/testcases/kernel/syscalls/epoll_ctl/epoll_ctl03.c @@ -74,5 +74,4 @@ static struct tst_test test = { .setup = setup, .cleanup = cleanup, .test_all = run_all, - .min_kver = "2.6.17", }; diff --git a/testcases/kernel/syscalls/fadvise/posix_fadvise04.c b/testcases/kernel/syscalls/fadvise/posix_fadvise04.c index f389a219b..8baf91bb0 100644 --- a/testcases/kernel/syscalls/fadvise/posix_fadvise04.c +++ b/testcases/kernel/syscalls/fadvise/posix_fadvise04.c @@ -83,5 +83,4 @@ static struct tst_test test = { .cleanup = cleanup, .test = verify_fadvise, .tcnt = ARRAY_SIZE(defined_advise), - .min_kver = "2.6.16", }; diff --git a/testcases/kernel/syscalls/fchmodat/fchmodat01.c b/testcases/kernel/syscalls/fchmodat/fchmodat01.c index 925f397ef..3deff0ebe 100644 --- a/testcases/kernel/syscalls/fchmodat/fchmodat01.c +++ b/testcases/kernel/syscalls/fchmodat/fchmodat01.c @@ -97,7 +97,6 @@ static void cleanup(void) } static struct tst_test test = { - .min_kver = "2.6.16", .tcnt = ARRAY_SIZE(tcases), .test = verify_fchmodat, .setup = setup, diff --git a/testcases/kernel/syscalls/fcntl/fcntl35.c b/testcases/kernel/syscalls/fcntl/fcntl35.c index 8eb71486f..2d730377b 100644 --- a/testcases/kernel/syscalls/fcntl/fcntl35.c +++ b/testcases/kernel/syscalls/fcntl/fcntl35.c @@ -113,7 +113,6 @@ static void do_test(unsigned int n) } static struct tst_test test = { - .min_kver = "2.6.35", .needs_root = 1, .forks_child = 1, .tcnt = ARRAY_SIZE(tcases), diff --git a/testcases/kernel/syscalls/futex/futex_wake04.c b/testcases/kernel/syscalls/futex/futex_wake04.c index 110c628c3..176dd4aeb 100644 --- a/testcases/kernel/syscalls/futex/futex_wake04.c +++ b/testcases/kernel/syscalls/futex/futex_wake04.c @@ -130,7 +130,6 @@ static struct tst_test test = { .test_all = wakeup_thread2, .test_variants = ARRAY_SIZE(variants), .needs_root = 1, - .min_kver = "2.6.32", .needs_tmpdir = 1, .hugepages = {1, TST_NEEDS}, }; diff --git a/testcases/kernel/syscalls/getrusage/getrusage03.c b/testcases/kernel/syscalls/getrusage/getrusage03.c index 7e7a1f555..fc14e93cf 100644 --- a/testcases/kernel/syscalls/getrusage/getrusage03.c +++ b/testcases/kernel/syscalls/getrusage/getrusage03.c @@ -177,7 +177,6 @@ static struct tst_test test = { .forks_child = 1, .child_needs_reinit = 1, .resource_files = resource, - .min_kver = "2.6.32", .min_mem_avail = 512, .tags = (const struct tst_tag[]) { {"linux-git", "1f10206cf8e9"}, diff --git a/testcases/kernel/syscalls/getxattr/getxattr05.c b/testcases/kernel/syscalls/getxattr/getxattr05.c index 28eb4cbcf..8d1752fd0 100644 --- a/testcases/kernel/syscalls/getxattr/getxattr05.c +++ b/testcases/kernel/syscalls/getxattr/getxattr05.c @@ -175,7 +175,6 @@ static struct tst_test test = { .cleanup = cleanup, .tcnt = ARRAY_SIZE(tcases), .test = do_getxattr, - .min_kver = "3.8", }; #else /* HAVE_SYS_XATTR_H && HAVE_LIBACL*/ diff --git a/testcases/kernel/syscalls/ipc/msgrcv/msgrcv03.c b/testcases/kernel/syscalls/ipc/msgrcv/msgrcv03.c index ebc583b3e..3e461b307 100644 --- a/testcases/kernel/syscalls/ipc/msgrcv/msgrcv03.c +++ b/testcases/kernel/syscalls/ipc/msgrcv/msgrcv03.c @@ -83,7 +83,6 @@ static struct tst_test test = { "CONFIG_CHECKPOINT_RESTORE", NULL }, - .min_kver = "3.8.0", .tcnt = ARRAY_SIZE(tcases), .test = verify_msgrcv, .setup = setup, diff --git a/testcases/kernel/syscalls/kcmp/kcmp01.c b/testcases/kernel/syscalls/kcmp/kcmp01.c index 903525ff0..0e7cc7a22 100644 --- a/testcases/kernel/syscalls/kcmp/kcmp01.c +++ b/testcases/kernel/syscalls/kcmp/kcmp01.c @@ -103,6 +103,5 @@ static struct tst_test test = { .cleanup = cleanup, .forks_child = 1, .test = verify_kcmp, - .min_kver = "3.5.0", .needs_tmpdir = 1, }; diff --git a/testcases/kernel/syscalls/kcmp/kcmp02.c b/testcases/kernel/syscalls/kcmp/kcmp02.c index ab07bb866..076b4a723 100644 --- a/testcases/kernel/syscalls/kcmp/kcmp02.c +++ b/testcases/kernel/syscalls/kcmp/kcmp02.c @@ -94,6 +94,5 @@ static struct tst_test test = { .setup = setup, .cleanup = cleanup, .test = verify_kcmp, - .min_kver = "3.5.0", .needs_tmpdir = 1 }; diff --git a/testcases/kernel/syscalls/kcmp/kcmp03.c b/testcases/kernel/syscalls/kcmp/kcmp03.c index 4b90e6d87..7af5cb150 100644 --- a/testcases/kernel/syscalls/kcmp/kcmp03.c +++ b/testcases/kernel/syscalls/kcmp/kcmp03.c @@ -87,5 +87,4 @@ static struct tst_test test = { .cleanup = cleanup, .forks_child = 1, .test = verify_kcmp, - .min_kver = "3.5.0" }; diff --git a/testcases/kernel/syscalls/keyctl/keyctl08.c b/testcases/kernel/syscalls/keyctl/keyctl08.c index bc01192e7..be4b23b14 100644 --- a/testcases/kernel/syscalls/keyctl/keyctl08.c +++ b/testcases/kernel/syscalls/keyctl/keyctl08.c @@ -28,7 +28,6 @@ void run(void) static struct tst_test test = { .test_all = run, .needs_root = 1, - .min_kver = "2.6.13", .tags = (const struct tst_tag[]) { {"CVE", "2016-9604"}, {"linux-git", "ee8f844e3c5a"}, diff --git a/testcases/kernel/syscalls/madvise/madvise05.c b/testcases/kernel/syscalls/madvise/madvise05.c index 3ab4a8749..9b00a1ff0 100644 --- a/testcases/kernel/syscalls/madvise/madvise05.c +++ b/testcases/kernel/syscalls/madvise/madvise05.c @@ -46,7 +46,6 @@ static void verify_madvise(void) } static struct tst_test test = { - .min_kver = "3.9.0", .test_all = verify_madvise, .tags = (const struct tst_tag[]) { {"linux-git", "ee53664bda16"}, diff --git a/testcases/kernel/syscalls/madvise/madvise06.c b/testcases/kernel/syscalls/madvise/madvise06.c index c1c55bbc2..c7967ae6f 100644 --- a/testcases/kernel/syscalls/madvise/madvise06.c +++ b/testcases/kernel/syscalls/madvise/madvise06.c @@ -235,7 +235,6 @@ static void test_advice_willneed(void) static struct tst_test test = { .test_all = test_advice_willneed, .setup = setup, - .min_kver = "3.10.0", .needs_tmpdir = 1, .needs_root = 1, .save_restore = (const struct tst_path_val[]) { diff --git a/testcases/kernel/syscalls/madvise/madvise07.c b/testcases/kernel/syscalls/madvise/madvise07.c index ca76d237b..d6e2e7d1f 100644 --- a/testcases/kernel/syscalls/madvise/madvise07.c +++ b/testcases/kernel/syscalls/madvise/madvise07.c @@ -92,7 +92,6 @@ static void run(void) static struct tst_test test = { .test_all = run, - .min_kver = "2.6.31", .needs_root = 1, .forks_child = 1 }; diff --git a/testcases/kernel/syscalls/madvise/madvise08.c b/testcases/kernel/syscalls/madvise/madvise08.c index 0996cf91b..96bcaf159 100644 --- a/testcases/kernel/syscalls/madvise/madvise08.c +++ b/testcases/kernel/syscalls/madvise/madvise08.c @@ -208,7 +208,6 @@ static struct tst_test test = { .tcnt = 2, .setup = setup, .cleanup = cleanup, - .min_kver = "3.4.0", .needs_tmpdir = 1, .needs_root = 1, .forks_child = 1, diff --git a/testcases/kernel/syscalls/migrate_pages/migrate_pages03.c b/testcases/kernel/syscalls/migrate_pages/migrate_pages03.c index f77e47539..4d3299b61 100644 --- a/testcases/kernel/syscalls/migrate_pages/migrate_pages03.c +++ b/testcases/kernel/syscalls/migrate_pages/migrate_pages03.c @@ -140,7 +140,6 @@ static void migrate_test(void) static struct tst_test test = { .max_runtime = 300, - .min_kver = "2.6.32", .needs_root = 1, .setup = setup, .cleanup = cleanup, diff --git a/testcases/kernel/syscalls/mlock2/mlock201.c b/testcases/kernel/syscalls/mlock2/mlock201.c index 1d1f5b7ac..b0e5f12b7 100644 --- a/testcases/kernel/syscalls/mlock2/mlock201.c +++ b/testcases/kernel/syscalls/mlock2/mlock201.c @@ -144,5 +144,4 @@ static struct tst_test test = { .test = verify_mlock2, .setup = setup, .needs_root = 1, - .min_kver = "2.6.9", }; diff --git a/testcases/kernel/syscalls/mlock2/mlock202.c b/testcases/kernel/syscalls/mlock2/mlock202.c index 630da6568..3b4965065 100644 --- a/testcases/kernel/syscalls/mlock2/mlock202.c +++ b/testcases/kernel/syscalls/mlock2/mlock202.c @@ -109,5 +109,4 @@ static struct tst_test test = { .setup = setup, .cleanup = cleanup, .needs_root = 1, - .min_kver = "2.6.9", }; diff --git a/testcases/kernel/syscalls/mlock2/mlock203.c b/testcases/kernel/syscalls/mlock2/mlock203.c index 8451b2cd1..0a519ad51 100644 --- a/testcases/kernel/syscalls/mlock2/mlock203.c +++ b/testcases/kernel/syscalls/mlock2/mlock203.c @@ -88,5 +88,4 @@ static struct tst_test test = { .setup = setup, .cleanup = cleanup, .needs_root = 1, - .min_kver = "2.6.9", }; diff --git a/testcases/kernel/syscalls/mmap/mmap12.c b/testcases/kernel/syscalls/mmap/mmap12.c index 2c0ebfb22..995a2bab0 100644 --- a/testcases/kernel/syscalls/mmap/mmap12.c +++ b/testcases/kernel/syscalls/mmap/mmap12.c @@ -135,5 +135,4 @@ static struct tst_test test = { .cleanup = cleanup, .test_all = verify_mmap, .needs_tmpdir = 1, - .min_kver = "2.6.25", }; diff --git a/testcases/kernel/syscalls/move_pages/move_pages12.c b/testcases/kernel/syscalls/move_pages/move_pages12.c index df55bbbe9..fd7017d79 100644 --- a/testcases/kernel/syscalls/move_pages/move_pages12.c +++ b/testcases/kernel/syscalls/move_pages/move_pages12.c @@ -333,7 +333,6 @@ static void cleanup(void) } static struct tst_test test = { - .min_kver = "2.6.32", .needs_root = 1, .forks_child = 1, .setup = setup, diff --git a/testcases/kernel/syscalls/msync/msync04.c b/testcases/kernel/syscalls/msync/msync04.c index abe8f1659..72ddc27a4 100644 --- a/testcases/kernel/syscalls/msync/msync04.c +++ b/testcases/kernel/syscalls/msync/msync04.c @@ -102,5 +102,4 @@ static struct tst_test test = { "tmpfs", NULL }, - .min_kver = "2.6.25", }; diff --git a/testcases/kernel/syscalls/pipe2/pipe2_04.c b/testcases/kernel/syscalls/pipe2/pipe2_04.c index 45e0f075b..3911f95b4 100644 --- a/testcases/kernel/syscalls/pipe2/pipe2_04.c +++ b/testcases/kernel/syscalls/pipe2/pipe2_04.c @@ -97,7 +97,6 @@ static void cleanup(void) } static struct tst_test test = { - .min_kver = "2.6.35", .test_all = test_pipe2, .setup = setup, .cleanup = cleanup, diff --git a/testcases/kernel/syscalls/preadv/preadv01.c b/testcases/kernel/syscalls/preadv/preadv01.c index 4b257968d..62f9296f2 100644 --- a/testcases/kernel/syscalls/preadv/preadv01.c +++ b/testcases/kernel/syscalls/preadv/preadv01.c @@ -105,7 +105,6 @@ static struct tst_test test = { .setup = setup, .cleanup = cleanup, .test = verify_preadv, - .min_kver = "2.6.30", .needs_tmpdir = 1, .bufs = (struct tst_buffers []) { {&rd_iovec, .iov_sizes = (int[]){CHUNK, 0, -1}}, diff --git a/testcases/kernel/syscalls/preadv/preadv02.c b/testcases/kernel/syscalls/preadv/preadv02.c index 12d93da43..500059e42 100644 --- a/testcases/kernel/syscalls/preadv/preadv02.c +++ b/testcases/kernel/syscalls/preadv/preadv02.c @@ -126,6 +126,5 @@ static struct tst_test test = { .setup = setup, .cleanup = cleanup, .test = verify_preadv, - .min_kver = "2.6.30", .needs_tmpdir = 1, }; diff --git a/testcases/kernel/syscalls/preadv/preadv03.c b/testcases/kernel/syscalls/preadv/preadv03.c index 00b25c549..d4595dda6 100644 --- a/testcases/kernel/syscalls/preadv/preadv03.c +++ b/testcases/kernel/syscalls/preadv/preadv03.c @@ -131,7 +131,6 @@ static struct tst_test test = { .setup = setup, .cleanup = cleanup, .test = verify_direct_preadv, - .min_kver = "2.6.30", .mntpoint = MNTPOINT, .mount_device = 1, .all_filesystems = 1, diff --git a/testcases/kernel/syscalls/pwritev/pwritev01.c b/testcases/kernel/syscalls/pwritev/pwritev01.c index 1ee783855..66358f7c4 100644 --- a/testcases/kernel/syscalls/pwritev/pwritev01.c +++ b/testcases/kernel/syscalls/pwritev/pwritev01.c @@ -103,6 +103,5 @@ static struct tst_test test = { .setup = setup, .cleanup = cleanup, .test = verify_pwritev, - .min_kver = "2.6.30", .needs_tmpdir = 1, }; diff --git a/testcases/kernel/syscalls/pwritev/pwritev02.c b/testcases/kernel/syscalls/pwritev/pwritev02.c index 82792df27..0881b7566 100644 --- a/testcases/kernel/syscalls/pwritev/pwritev02.c +++ b/testcases/kernel/syscalls/pwritev/pwritev02.c @@ -117,6 +117,5 @@ static struct tst_test test = { .setup = setup, .cleanup = cleanup, .test = verify_pwritev, - .min_kver = "2.6.30", .needs_tmpdir = 1, }; diff --git a/testcases/kernel/syscalls/pwritev/pwritev03.c b/testcases/kernel/syscalls/pwritev/pwritev03.c index 91a5e3c54..8b91de336 100644 --- a/testcases/kernel/syscalls/pwritev/pwritev03.c +++ b/testcases/kernel/syscalls/pwritev/pwritev03.c @@ -130,7 +130,6 @@ static struct tst_test test = { .setup = setup, .cleanup = cleanup, .test = verify_direct_pwritev, - .min_kver = "2.6.30", .mntpoint = MNTPOINT, .mount_device = 1, .all_filesystems = 1, diff --git a/testcases/kernel/syscalls/recvmsg/recvmsg02.c b/testcases/kernel/syscalls/recvmsg/recvmsg02.c index b15b37867..3aac4dd36 100644 --- a/testcases/kernel/syscalls/recvmsg/recvmsg02.c +++ b/testcases/kernel/syscalls/recvmsg/recvmsg02.c @@ -94,7 +94,6 @@ static void cleanup(void) } static struct tst_test test = { - .min_kver = "2.6.27", .test_all = verify_recvmsg, .cleanup = cleanup, .tags = (const struct tst_tag[]) { diff --git a/testcases/kernel/syscalls/sendfile/sendfile08.c b/testcases/kernel/syscalls/sendfile/sendfile08.c index da334f1f5..66fd40cae 100644 --- a/testcases/kernel/syscalls/sendfile/sendfile08.c +++ b/testcases/kernel/syscalls/sendfile/sendfile08.c @@ -71,7 +71,6 @@ static struct tst_test test = { .setup = setup, .cleanup = cleanup, .test_all = run, - .min_kver = "2.6.33", .tags = (const struct tst_tag[]) { {"linux-git", "2cb4b05e76478"}, {} diff --git a/testcases/kernel/syscalls/sendfile/sendfile09.c b/testcases/kernel/syscalls/sendfile/sendfile09.c index 66d5f31a9..4a2d2083f 100644 --- a/testcases/kernel/syscalls/sendfile/sendfile09.c +++ b/testcases/kernel/syscalls/sendfile/sendfile09.c @@ -96,7 +96,6 @@ static struct tst_test test = { .setup = setup, .test = run, .tcnt = ARRAY_SIZE(tc), - .min_kver = "2.6.33", .max_runtime = 120, .tags = (const struct tst_tag[]) { {"linux-git", "5d73320a96fcc"}, diff --git a/testcases/kernel/syscalls/setsockopt/setsockopt02.c b/testcases/kernel/syscalls/setsockopt/setsockopt02.c index f0a2a5ecd..e7621538b 100644 --- a/testcases/kernel/syscalls/setsockopt/setsockopt02.c +++ b/testcases/kernel/syscalls/setsockopt/setsockopt02.c @@ -96,5 +96,4 @@ static struct tst_test test = { .needs_root = 1, .setup = setup, .cleanup = cleanup, - .min_kver = "3.2", }; diff --git a/testcases/kernel/syscalls/setsockopt/setsockopt03.c b/testcases/kernel/syscalls/setsockopt/setsockopt03.c index 191c4cdfe..210b75429 100644 --- a/testcases/kernel/syscalls/setsockopt/setsockopt03.c +++ b/testcases/kernel/syscalls/setsockopt/setsockopt03.c @@ -74,7 +74,6 @@ static void run(void) } static struct tst_test test = { - .min_kver = "2.6.32", .setup = setup, .test_all = run, .needs_root = 1, diff --git a/testcases/kernel/syscalls/socket/socket02.c b/testcases/kernel/syscalls/socket/socket02.c index 59fd942d5..51b8cc59c 100644 --- a/testcases/kernel/syscalls/socket/socket02.c +++ b/testcases/kernel/syscalls/socket/socket02.c @@ -68,6 +68,5 @@ static void cleanup(void) static struct tst_test test = { .tcnt = ARRAY_SIZE(tcases), .test = verify_socket, - .min_kver = "2.6.27", .cleanup = cleanup }; diff --git a/testcases/kernel/syscalls/socketpair/socketpair02.c b/testcases/kernel/syscalls/socketpair/socketpair02.c index e23945c53..eb679d5d9 100644 --- a/testcases/kernel/syscalls/socketpair/socketpair02.c +++ b/testcases/kernel/syscalls/socketpair/socketpair02.c @@ -81,6 +81,5 @@ static void cleanup(void) static struct tst_test test = { .tcnt = ARRAY_SIZE(tcases), .test = verify_socketpair, - .min_kver = "2.6.27", .cleanup = cleanup }; diff --git a/testcases/kernel/syscalls/splice/splice01.c b/testcases/kernel/syscalls/splice/splice01.c index f5b2cbe17..508ccdeb7 100644 --- a/testcases/kernel/syscalls/splice/splice01.c +++ b/testcases/kernel/syscalls/splice/splice01.c @@ -101,5 +101,4 @@ static struct tst_test test = { .cleanup = cleanup, .test_all = splice_test, .needs_tmpdir = 1, - .min_kver = "2.6.17", }; diff --git a/testcases/kernel/syscalls/splice/splice02.c b/testcases/kernel/syscalls/splice/splice02.c index b29415a8a..1da1186b2 100644 --- a/testcases/kernel/syscalls/splice/splice02.c +++ b/testcases/kernel/syscalls/splice/splice02.c @@ -155,7 +155,6 @@ static struct tst_test test = { .setup = setup, .needs_tmpdir = 1, .forks_child = 1, - .min_kver = "2.6.17", .options = (struct tst_option[]) { {"s:", &sarg, "Size of output file in bytes (default: 16x max pipe size, i.e. 1M on intel)"}, {} diff --git a/testcases/kernel/syscalls/splice/splice03.c b/testcases/kernel/syscalls/splice/splice03.c index f3c135dee..c054e6c1c 100644 --- a/testcases/kernel/syscalls/splice/splice03.c +++ b/testcases/kernel/syscalls/splice/splice03.c @@ -123,5 +123,4 @@ static struct tst_test test = { .test = splice_verify, .tcnt = ARRAY_SIZE(tcases), .needs_tmpdir = 1, - .min_kver = "2.6.17", }; diff --git a/testcases/kernel/syscalls/splice/splice04.c b/testcases/kernel/syscalls/splice/splice04.c index 896f45839..5e6e8df05 100644 --- a/testcases/kernel/syscalls/splice/splice04.c +++ b/testcases/kernel/syscalls/splice/splice04.c @@ -83,5 +83,4 @@ static struct tst_test test = { {"l:", &str_len_data, "Length of test data (in bytes)"}, {} }, - .min_kver = "2.6.31" }; diff --git a/testcases/kernel/syscalls/splice/splice05.c b/testcases/kernel/syscalls/splice/splice05.c index d77dc887e..501df10f6 100644 --- a/testcases/kernel/syscalls/splice/splice05.c +++ b/testcases/kernel/syscalls/splice/splice05.c @@ -108,5 +108,4 @@ static struct tst_test test = { {"l:", &str_len_data, "Length of test data (in bytes)"}, {} }, - .min_kver = "2.6.17" }; diff --git a/testcases/kernel/syscalls/switch/endian_switch01.c b/testcases/kernel/syscalls/switch/endian_switch01.c index f357ff54d..bee35184a 100644 --- a/testcases/kernel/syscalls/switch/endian_switch01.c +++ b/testcases/kernel/syscalls/switch/endian_switch01.c @@ -93,7 +93,6 @@ static void endian_test(void) static struct tst_test test = { .test_all = endian_test, - .min_kver = "2.6.26", .forks_child = 1, }; diff --git a/testcases/kernel/syscalls/tee/tee01.c b/testcases/kernel/syscalls/tee/tee01.c index 87a7ecd09..d1489d045 100644 --- a/testcases/kernel/syscalls/tee/tee01.c +++ b/testcases/kernel/syscalls/tee/tee01.c @@ -106,5 +106,4 @@ static struct tst_test test = { .cleanup = cleanup, .test_all = tee_test, .needs_tmpdir = 1, - .min_kver = "2.6.17", }; diff --git a/testcases/kernel/syscalls/tee/tee02.c b/testcases/kernel/syscalls/tee/tee02.c index 885877d1f..5ebb3c3f6 100644 --- a/testcases/kernel/syscalls/tee/tee02.c +++ b/testcases/kernel/syscalls/tee/tee02.c @@ -90,5 +90,4 @@ static struct tst_test test = { .test = tee_verify, .tcnt = ARRAY_SIZE(tcases), .needs_tmpdir = 1, - .min_kver = "2.6.17", }; diff --git a/testcases/kernel/syscalls/timerfd/timerfd01.c b/testcases/kernel/syscalls/timerfd/timerfd01.c index 9f5694217..4461c4fd4 100644 --- a/testcases/kernel/syscalls/timerfd/timerfd01.c +++ b/testcases/kernel/syscalls/timerfd/timerfd01.c @@ -158,5 +158,4 @@ static struct tst_test test = { .tcnt = ARRAY_SIZE(tcases), .test_variants = ARRAY_SIZE(variants), .setup = setup, - .min_kver = "2.6.25", }; diff --git a/testcases/kernel/syscalls/timerfd/timerfd_gettime01.c b/testcases/kernel/syscalls/timerfd/timerfd_gettime01.c index aba77c05d..8dd31f9f0 100644 --- a/testcases/kernel/syscalls/timerfd/timerfd_gettime01.c +++ b/testcases/kernel/syscalls/timerfd/timerfd_gettime01.c @@ -101,5 +101,4 @@ static struct tst_test test = { .setup = setup, .cleanup = cleanup, .needs_tmpdir = 1, - .min_kver = "2.6.25", }; diff --git a/testcases/kernel/syscalls/timerfd/timerfd_settime01.c b/testcases/kernel/syscalls/timerfd/timerfd_settime01.c index 36577e2c4..7ebcaf4b4 100644 --- a/testcases/kernel/syscalls/timerfd/timerfd_settime01.c +++ b/testcases/kernel/syscalls/timerfd/timerfd_settime01.c @@ -108,5 +108,4 @@ static struct tst_test test = { .setup = setup, .cleanup = cleanup, .needs_tmpdir = 1, - .min_kver = "2.6.25", }; diff --git a/testcases/kernel/syscalls/timerfd/timerfd_settime02.c b/testcases/kernel/syscalls/timerfd/timerfd_settime02.c index 84ce95538..33d9f7b46 100644 --- a/testcases/kernel/syscalls/timerfd/timerfd_settime02.c +++ b/testcases/kernel/syscalls/timerfd/timerfd_settime02.c @@ -110,7 +110,6 @@ static struct tst_test test = { .test_variants = ARRAY_SIZE(variants), .setup = setup, .cleanup = cleanup, - .min_kver = "2.6.25", .taint_check = TST_TAINT_W | TST_TAINT_D, .max_runtime = 150, .tags = (const struct tst_tag[]) { diff --git a/testcases/kernel/syscalls/unlinkat/unlinkat01.c b/testcases/kernel/syscalls/unlinkat/unlinkat01.c index cdbb09927..7dba1d641 100644 --- a/testcases/kernel/syscalls/unlinkat/unlinkat01.c +++ b/testcases/kernel/syscalls/unlinkat/unlinkat01.c @@ -107,7 +107,6 @@ static void cleanup(void) static struct tst_test test = { .needs_tmpdir = 1, .tcnt = ARRAY_SIZE(tc), - .min_kver = "2.6.16", .setup = setup, .test = run, .cleanup = cleanup, diff --git a/testcases/kernel/syscalls/vmsplice/vmsplice01.c b/testcases/kernel/syscalls/vmsplice/vmsplice01.c index 36ecc08ef..17486179b 100644 --- a/testcases/kernel/syscalls/vmsplice/vmsplice01.c +++ b/testcases/kernel/syscalls/vmsplice/vmsplice01.c @@ -121,5 +121,4 @@ static struct tst_test test = { "nfs", NULL }, - .min_kver = "2.6.17", }; diff --git a/testcases/kernel/syscalls/vmsplice/vmsplice02.c b/testcases/kernel/syscalls/vmsplice/vmsplice02.c index 0135b6f7e..8f1965c2e 100644 --- a/testcases/kernel/syscalls/vmsplice/vmsplice02.c +++ b/testcases/kernel/syscalls/vmsplice/vmsplice02.c @@ -103,5 +103,4 @@ static struct tst_test test = { "nfs", NULL }, - .min_kver = "2.6.17", }; diff --git a/testcases/kernel/syscalls/vmsplice/vmsplice03.c b/testcases/kernel/syscalls/vmsplice/vmsplice03.c index 622c11017..d3a39254b 100644 --- a/testcases/kernel/syscalls/vmsplice/vmsplice03.c +++ b/testcases/kernel/syscalls/vmsplice/vmsplice03.c @@ -62,7 +62,6 @@ static void setup(void) static struct tst_test test = { .setup = setup, .test_all = vmsplice_test, - .min_kver = "2.6.23", .bufs = (struct tst_buffers []) { {&iov, .iov_sizes = (int[]){TEST_BLOCK_SIZE, -1}}, {} diff --git a/testcases/kernel/syscalls/vmsplice/vmsplice04.c b/testcases/kernel/syscalls/vmsplice/vmsplice04.c index 9aaa0b56f..96c24bc60 100644 --- a/testcases/kernel/syscalls/vmsplice/vmsplice04.c +++ b/testcases/kernel/syscalls/vmsplice/vmsplice04.c @@ -88,6 +88,5 @@ static struct tst_test test = { .setup = setup, .cleanup = cleanup, .test_all = vmsplice_test, - .min_kver = "2.6.17", .forks_child = 1, };