From patchwork Fri Apr 10 10:55:17 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrea Righi X-Patchwork-Id: 1269013 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=canonical.com Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 48zFKb2Xqmz9sSm; Fri, 10 Apr 2020 20:55:31 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from ) id 1jMrJn-0001c5-3A; Fri, 10 Apr 2020 10:55:27 +0000 Received: from youngberry.canonical.com ([91.189.89.112]) by huckleberry.canonical.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1jMrJl-0001bg-F4 for kernel-team@lists.ubuntu.com; Fri, 10 Apr 2020 10:55:25 +0000 Received: from mail-wr1-f69.google.com ([209.85.221.69]) by youngberry.canonical.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1jMrJl-0006Ia-80 for kernel-team@lists.ubuntu.com; Fri, 10 Apr 2020 10:55:25 +0000 Received: by mail-wr1-f69.google.com with SMTP id j16so288211wrw.20 for ; Fri, 10 Apr 2020 03:55:25 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=5uqXH4orUmQPdR78RdbCW6JxWdlaYLq8eFq5azHq04E=; b=a0GszUwgcKK0tJ09m0/LB5a9SRkJ1oP1DuVNks+6F5pd56f0st5TSymOrj1aojnjWu xK+/uYbF83FITHEX11sttAgKgjTC+3n01y1q5VnuWIwYPF4GTAtgdwGac8Blo63uMh7W 8BDOqmO73D574oM0KUyD7yB/nXbojRl2XXMXjFYTJstHSQu+c6hSdp8/x5X8zsBLFpoK Mk1eLoSq3ZV/M3JgzyKxnqlnO8ChXcUPjXbkY6DRmeDFuQq4fdP1HZpNOuXVDhTERhcs zJbiWLHdcxktKJRXoEbNpc5CyIein3mMets9Rl/59Daik/kEwldDIiY6R+GUeAnR2RtA 0WVw== X-Gm-Message-State: AGi0Pub1m9G1RHKGIWaILZEfVrR62cA/WTzJbZ5XXHBUZKf4RefDUwfd 98fqac3+HqKXFK+LZ6itctKqgyB7nwktlNVgroRmfqzezglvV8/xYDa72uKRMTg6n8ITqqr+Ymj u/C2F6NZgfq/X7Uab1EIZ7mKseC0aRWcy5urQTRrsDA== X-Received: by 2002:a5d:544f:: with SMTP id w15mr4290001wrv.77.1586516124626; Fri, 10 Apr 2020 03:55:24 -0700 (PDT) X-Google-Smtp-Source: APiQypI+XjO4uJ48ZlAvFrF2hG5Xwh0cUitaskWM5I6RNAbfbNwpAtmiJ0qfAE2Z8t2KUdUinNkiOg== X-Received: by 2002:a5d:544f:: with SMTP id w15mr4289985wrv.77.1586516124355; Fri, 10 Apr 2020 03:55:24 -0700 (PDT) Received: from xps-13.homenet.telecomitalia.it (host123-127-dynamic.36-79-r.retail.telecomitalia.it. [79.36.127.123]) by smtp.gmail.com with ESMTPSA id j5sm2533787wrm.76.2020.04.10.03.55.23 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 10 Apr 2020 03:55:23 -0700 (PDT) From: Andrea Righi To: kernel-team@lists.ubuntu.com Subject: [PATCH 1/2] [E] UBUNTU: SAUCE: kselftest/runner: avoid using timeout if timeout is disabled Date: Fri, 10 Apr 2020 12:55:17 +0200 Message-Id: <20200410105518.521722-2-andrea.righi@canonical.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200410105518.521722-1-andrea.righi@canonical.com> References: <20200410105518.521722-1-andrea.righi@canonical.com> MIME-Version: 1.0 X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" Avoid using /usr/bin/timeout unnecessarily if timeout is set to 0 in the "settings" file for a specific test. NOTE: this change prevents a syscall_restart failure in the seccomp kselftest. BugLink: https://bugs.launchpad.net/bugs/1870543 Signed-off-by: Andrea Righi --- tools/testing/selftests/kselftest/runner.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/testing/selftests/kselftest/runner.sh b/tools/testing/selftests/kselftest/runner.sh index e84d901f8567..2cd3c8def0f6 100644 --- a/tools/testing/selftests/kselftest/runner.sh +++ b/tools/testing/selftests/kselftest/runner.sh @@ -32,7 +32,7 @@ tap_prefix() tap_timeout() { # Make sure tests will time out if utility is available. - if [ -x /usr/bin/timeout ] ; then + if [ -x /usr/bin/timeout ] && [ $kselftest_timeout -gt 0 ] ; then /usr/bin/timeout "$kselftest_timeout" "$1" else "$1"