From patchwork Wed Jan 24 04:30:14 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ian Rogers X-Patchwork-Id: 191342 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:2553:b0:103:945f:af90 with SMTP id p19csp771812dyi; Tue, 23 Jan 2024 20:31:31 -0800 (PST) X-Google-Smtp-Source: AGHT+IGHamvAzWMzX41IhbDO5XvW/8SEPBj7Yt+wH/lXklSlXX7LVgrkvOWuq1Q/BIs7IfusorEk X-Received: by 2002:ad4:5bef:0:b0:686:92ba:8e2d with SMTP id k15-20020ad45bef000000b0068692ba8e2dmr2634349qvc.97.1706070691703; Tue, 23 Jan 2024 20:31:31 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706070691; cv=pass; d=google.com; s=arc-20160816; b=JoCcAiGCgZXZZx3kiwn+dPhKAfJODd6O1cVW3hh313cSSUxt0dqqRyjmlxaTX9bc5k Hcd2MbXNpHhROUjW1z3a6dfsBZihs/VWf64HW39xNE69DaLOE4BkUwRrz12AOi68hTHk Fdks9L4Io0b492LEhZq/+/nuWfFi7bSOkzTI9tgCIeYuUNi5uKkAeVHf0khJbUN5CJFd lxD9px/lEngD5HJ2ea/ZQ7aWfBJYn+MWLGIDtewvRSograHS3WdvFr9Q63UIaCd+qtiG 1xfwF8WrccMziIWcikimAqvogIZx8jsgdx1vdeI5YTcEK817uM/jenFkXRzHc6NApvpc OUSw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=to:from:subject:references:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:in-reply-to:date :dkim-signature; bh=fBCtMKasWa4R0QCHWLL2yjNv7OcjwMumfCEw+e3pMI0=; fh=OSPvvrodhCXrbS0tgWY7ZQ1FjQjyOgKyIFsZYsPrQ8s=; b=r3vMClS5gaF3jW5UOgSxCfpZHtpgTxFdiRkbixBENSQA/gliRPkdA6PtExmSnFMqNi oBHPWqeop4DtISw5d0CHCAvULCTJajpaDFlogGOjzA0WZouv3iNwJUdAHSIvo3aOBGbr LVGmJxcDGMRAChe+6YSW1DdDs8FZd9Z+5hqoWz1qdnughRyC+pA+jPOSxyCt08ob904I OdLb3pPkYD90WZJZqOO9Mk7RsFH1LkCc+Wlx90EQfew4tHRLDyLbSn1zS2gQlA6jJwup m6AOqiuE7jYHDjjXrxbUg0ZxOEANv/kgFPSZkGVGd+sbfZIqfuYDVJn4HdEla8r6tCBd Vk8g== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@google.com header.s=20230601 header.b=fvQJOOXh; arc=pass (i=1 spf=pass spfdomain=flex--irogers.bounces.google.com dkim=pass dkdomain=google.com dmarc=pass fromdomain=google.com); spf=pass (google.com: domain of linux-kernel+bounces-36430-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-36430-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id e17-20020a0ce3d1000000b0068190e1ba61si9147702qvl.191.2024.01.23.20.31.31 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 23 Jan 2024 20:31:31 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-36430-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20230601 header.b=fvQJOOXh; arc=pass (i=1 spf=pass spfdomain=flex--irogers.bounces.google.com dkim=pass dkdomain=google.com dmarc=pass fromdomain=google.com); spf=pass (google.com: domain of linux-kernel+bounces-36430-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-36430-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 722EF1C276C7 for ; Wed, 24 Jan 2024 04:31:31 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 2BF8AC8EA; Wed, 24 Jan 2024 04:30:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="fvQJOOXh" Received: from mail-yb1-f202.google.com (mail-yb1-f202.google.com [209.85.219.202]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id EF1EBF9EC for ; Wed, 24 Jan 2024 04:30:28 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.219.202 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706070630; cv=none; b=XgI9Bdd600ctBn8YWgzdUzrWCTlRSwRBDKoCSEjfYovZQuXTP3sicgZw+W8+KOrU/GhYwXTiB0f9eI6aI0EDDwUM2QpW0ojhNDUXBY6gL0JxLuL8+3/Snbm+FOOkUgYWBYtxmHslb4fhYx/N/RDm0GfJPXy2IJdXlg8Hf+D5Byo= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706070630; c=relaxed/simple; bh=/BVg/i0Vw7TAHNOWxEpu0gen2xUd569y8hw0+uU0hkA=; h=Date:In-Reply-To:Message-Id:Mime-Version:References:Subject:From: To:Content-Type; b=o1yARNjYSXrKZovCM+M9DDO/5MqrcRkXpVXxgMh/6+H8B6LHRH8VfCszK91epsInHyVTQk3CDPJEBpm8Vv/gl/pLCD/oJV804vc7cUVy6KqVRdjSOOOpzumH38Pw/dbC5qVC3To3oSd8sqWviZVw1VmTUhUQdMDfQq0dnj010ws= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com; spf=pass smtp.mailfrom=flex--irogers.bounces.google.com; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b=fvQJOOXh; arc=none smtp.client-ip=209.85.219.202 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=flex--irogers.bounces.google.com Received: by mail-yb1-f202.google.com with SMTP id 3f1490d57ef6-dbf1c3816a3so6012433276.1 for ; Tue, 23 Jan 2024 20:30:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1706070628; x=1706675428; darn=vger.kernel.org; h=to:from:subject:references:mime-version:message-id:in-reply-to:date :from:to:cc:subject:date:message-id:reply-to; bh=fBCtMKasWa4R0QCHWLL2yjNv7OcjwMumfCEw+e3pMI0=; b=fvQJOOXh0tGyRzU3GoC2EnLnD6suVdBLp+XPUOpW5Dl9qrNQRsmiLhNk7k7WPU0bOM l2posPmK/7pcLpjNGtoep1rLCfyA74El0+LR+IOm4fROdiyZ/1nkhZ2GrL/UBejXm+M+ iqdhlc2ZII2ccZTGpw9f+D0ZUi6udwUDWvkJbyWD2BhXgwujRj8184QePEwPVF07shKN M6vhX9n8txVvoTI3CTRwc2FRz5UtyJpJuDJdEOQxsCG090K2tZp5AOZkvX3P/BdIi2GN l3sVdnjHSxTk05PMgfw9/wnrSzaNYozbaRZxSH7W/sm5WL2EFEwXHO4uMKeCf5xRu3VS hYmQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1706070628; x=1706675428; h=to:from:subject:references:mime-version:message-id:in-reply-to:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=fBCtMKasWa4R0QCHWLL2yjNv7OcjwMumfCEw+e3pMI0=; b=atdGCX9n/vlHeYMB3DUzqY0VRRn7zQIU1oG+LhKIYnX37949yWaI7Z1nj0TcpETzmj Ja7/CyCpq+VIHrPRkHBUxebtHgq2AD4xWdxaE94U/wY/bxlE+MZ9DHphd1WCCgHqyjaf JLvZF+xYZxb7lHwQqF0iZZU5cUfq038Hvgy1oekdttjB73fPIDggRzdu+fKGkUfzbwFk HV7uFlNggumCN2AdaPhgvu5hRB7xBfE4DMDd5Urzo4PxyvBZC79gFkZcKGI4VyZJLL7s QqcO//Cm3oyNittR/QwnMo5ntZM/8TmwNHbWAArMbzwX6vf5BBFrt7caWUUtdvwOewlX cX8Q== X-Gm-Message-State: AOJu0YyFNqQjG+nAwhAg1RoMsjwfAxwqELR3+ippsoUmg5CkHTF8AOQ4 f1DDWzEu1oCtYubopfFGkKqt0TPLtvPruOycQi+MM+6DZ2jAPHgc7ta1kdWM216mTEHK8Em2Vdw OiHbVTg== X-Received: from irogers.svl.corp.google.com ([2620:15c:2a3:200:b37:2438:2b2f:daae]) (user=irogers job=sendgmr) by 2002:a05:6902:152:b0:dc2:3268:e9e7 with SMTP id p18-20020a056902015200b00dc23268e9e7mr14661ybh.10.1706070628081; Tue, 23 Jan 2024 20:30:28 -0800 (PST) Date: Tue, 23 Jan 2024 20:30:14 -0800 In-Reply-To: <20240124043015.1388867-1-irogers@google.com> Message-Id: <20240124043015.1388867-5-irogers@google.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 References: <20240124043015.1388867-1-irogers@google.com> X-Mailer: git-send-email 2.43.0.429.g432eaa2c6b-goog Subject: [PATCH v2 4/5] perf test: Fix script test for python being disabled From: Ian Rogers To: Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Namhyung Kim , Mark Rutland , Alexander Shishkin , Jiri Olsa , Ian Rogers , Adrian Hunter , Ravi Bangoria , Ross Zwisler , Athira Rajeev , Shirisha G , Kajol Jain , Kan Liang , linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1788944781557178254 X-GMAIL-MSGID: 1788944781557178254 "grep -cv" can exit with an error code that causes the "set -e" to abort the script. Switch to using the grep exit code in the if condition to avoid this. Signed-off-by: Ian Rogers Acked-by: Namhyung Kim --- tools/perf/tests/shell/script.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tools/perf/tests/shell/script.sh b/tools/perf/tests/shell/script.sh index 5ae7bd0031a8..b43077dbaf98 100755 --- a/tools/perf/tests/shell/script.sh +++ b/tools/perf/tests/shell/script.sh @@ -36,8 +36,7 @@ test_db() echo "DB test" # Check if python script is supported - libpython=$(perf version --build-options | grep python | grep -cv OFF) - if [ "${libpython}" != "1" ] ; then + if perf version --build-options | grep python | grep -q OFF ; then echo "SKIP: python scripting is not supported" err=2 return