Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp3533367rwi; Wed, 12 Oct 2022 03:31:49 -0700 (PDT) X-Google-Smtp-Source: AMsMyM42xkh8vnVg4JWRk8OOXWKTQfeAIEOojRB59iBmz0BYNpJ6zMxnDmEOfwNyMwA/uYrBJgB8 X-Received: by 2002:a05:6402:3408:b0:43c:2dd3:d86b with SMTP id k8-20020a056402340800b0043c2dd3d86bmr27159870edc.108.1665570708756; Wed, 12 Oct 2022 03:31:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1665570708; cv=none; d=google.com; s=arc-20160816; b=VgSCryVjRrWYTsONaNX6BxE+87Pu04ydPDoMSnQ2zCsNWCArsDkF3J5f8Ti3uiSMUT paPC7xgxJSMoSOQTySxIopGX7OQCDej4Z+ujpJLD+7lLyhpBqbsAqmX5ssok6evalrQN 38aE7SF8WG1ZMXsw6BWlDz6mA+8UyOLJdEOho3LdwHx33aDLgHGxu8LWKB4s7bs3KgT2 3yDwMoqv9Akd4oaKsl5zSpEzjYCO55a9lRSNvLJT1OF893WBqiGoujtkk5hAI0u3HuQE l5hc1y2mFLeR4po4kSaBqR/K/hsQ1nYAPIclOdps1pyYKo52/N/Vu6Bx7Kf+XTO34H3F sePQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=e8b7Raj+Dm6NSgfFQ5V9xuAUHBw75eJa4NS4d4zYr68=; b=WfQ/6zUz4Wv+IR8SZPmiQKYQqefWEvgxwQfZW0QiT8/rNNPKM3kzULJAJGDfvJVl90 YN+a/np2SoYfGpF9qS4Hb3d7o2L7m66IonVDXYv03SWqq7NAzJQv3lLcY1v3TAVHDPYH 1oBHm482lhaLB07GTXZ3EX3RClf1GnBZkfPqnvHUGrjecnHW8IqRQ77A4pK7Q/o2p45T +p6R9NNmaKJ5gBFG23qE1zN3Aa4Ib4rec11scVMSci7ayMwPf8bozV43uDLMvV6WPpt9 XW22IkFOdJkY7rrVmC46/WhBFxV3ALM3fULYZKm/0ZBXZjlXE7DRTFOIonPnvnNTKvcD JScA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id e7-20020a056402190700b0045c329a4142si8496072edz.403.2022.10.12.03.31.22; Wed, 12 Oct 2022 03:31:48 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229971AbiJLJrQ (ORCPT + 99 others); Wed, 12 Oct 2022 05:47:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41538 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229921AbiJLJrK (ORCPT ); Wed, 12 Oct 2022 05:47:10 -0400 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id B71ADB0B32; Wed, 12 Oct 2022 02:47:06 -0700 (PDT) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 096CF1684; Wed, 12 Oct 2022 02:47:12 -0700 (PDT) Received: from e121896.Emea.Arm.com (e121896.Emea.Arm.com [10.32.36.24]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 24EC53F792; Wed, 12 Oct 2022 02:47:02 -0700 (PDT) From: James Clark To: linux-perf-users@vger.kernel.org, acme@kernel.org, namhyung@kernel.org Cc: linux-kernel@vger.kernel.org, James Clark , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Jiri Olsa , Adrian Hunter Subject: [PATCH v2 1/1] perf test: Fix attr tests for PERF_FORMAT_LOST Date: Wed, 12 Oct 2022 10:46:32 +0100 Message-Id: <20221012094633.21669-2-james.clark@arm.com> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20221012094633.21669-1-james.clark@arm.com> References: <20221012094633.21669-1-james.clark@arm.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_LOW, SPF_HELO_NONE,SPF_NONE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Since PERF_FORMAT_LOST was added, the default read format has that bit set, so add it to the tests. Keep the old value as well so that the test still passes on older kernels. This fixes the following failure: expected read_format=0|4, got 20 FAILED './tests/attr/test-record-C0' - match failure Fixes: 85b425f31c88 ("perf record: Set PERF_FORMAT_LOST by default") Cc: Namhyung Kim Signed-off-by: James Clark --- tools/perf/tests/attr/base-record | 2 +- tools/perf/tests/attr/system-wide-dummy | 2 +- tools/perf/tests/attr/test-record-group | 4 ++-- tools/perf/tests/attr/test-record-group-sampling | 6 +++--- tools/perf/tests/attr/test-record-group1 | 4 ++-- tools/perf/tests/attr/test-record-group2 | 4 ++-- 6 files changed, 11 insertions(+), 11 deletions(-) diff --git a/tools/perf/tests/attr/base-record b/tools/perf/tests/attr/base-record index 8c10955eff93..3ef07a12aa14 100644 --- a/tools/perf/tests/attr/base-record +++ b/tools/perf/tests/attr/base-record @@ -9,7 +9,7 @@ size=128 config=0 sample_period=* sample_type=263 -read_format=0|4 +read_format=0|4|20 disabled=1 inherit=1 pinned=0 diff --git a/tools/perf/tests/attr/system-wide-dummy b/tools/perf/tests/attr/system-wide-dummy index 86a15dd359d9..8fec06eda5f9 100644 --- a/tools/perf/tests/attr/system-wide-dummy +++ b/tools/perf/tests/attr/system-wide-dummy @@ -11,7 +11,7 @@ size=128 config=9 sample_period=4000 sample_type=455 -read_format=4 +read_format=4|20 # Event will be enabled right away. disabled=0 inherit=1 diff --git a/tools/perf/tests/attr/test-record-group b/tools/perf/tests/attr/test-record-group index 14ee60fd3f41..6c1cff8aae8b 100644 --- a/tools/perf/tests/attr/test-record-group +++ b/tools/perf/tests/attr/test-record-group @@ -7,14 +7,14 @@ ret = 1 fd=1 group_fd=-1 sample_type=327 -read_format=4 +read_format=4|20 [event-2:base-record] fd=2 group_fd=1 config=1 sample_type=327 -read_format=4 +read_format=4|20 mmap=0 comm=0 task=0 diff --git a/tools/perf/tests/attr/test-record-group-sampling b/tools/perf/tests/attr/test-record-group-sampling index 300b9f7e6d69..97e7e64a38f0 100644 --- a/tools/perf/tests/attr/test-record-group-sampling +++ b/tools/perf/tests/attr/test-record-group-sampling @@ -7,7 +7,7 @@ ret = 1 fd=1 group_fd=-1 sample_type=343 -read_format=12 +read_format=12|28 inherit=0 [event-2:base-record] @@ -21,8 +21,8 @@ config=3 # default | PERF_SAMPLE_READ sample_type=343 -# PERF_FORMAT_ID | PERF_FORMAT_GROUP -read_format=12 +# PERF_FORMAT_ID | PERF_FORMAT_GROUP | PERF_FORMAT_LOST +read_format=12|28 task=0 mmap=0 comm=0 diff --git a/tools/perf/tests/attr/test-record-group1 b/tools/perf/tests/attr/test-record-group1 index 3ffe246e0228..eeb1db392bc9 100644 --- a/tools/perf/tests/attr/test-record-group1 +++ b/tools/perf/tests/attr/test-record-group1 @@ -7,7 +7,7 @@ ret = 1 fd=1 group_fd=-1 sample_type=327 -read_format=4 +read_format=4|20 [event-2:base-record] fd=2 @@ -15,7 +15,7 @@ group_fd=1 type=0 config=1 sample_type=327 -read_format=4 +read_format=4|20 mmap=0 comm=0 task=0 diff --git a/tools/perf/tests/attr/test-record-group2 b/tools/perf/tests/attr/test-record-group2 index 6b9f8d182ce1..cebdaa8e64e4 100644 --- a/tools/perf/tests/attr/test-record-group2 +++ b/tools/perf/tests/attr/test-record-group2 @@ -9,7 +9,7 @@ group_fd=-1 config=0|1 sample_period=1234000 sample_type=87 -read_format=12 +read_format=12|28 inherit=0 freq=0 @@ -19,7 +19,7 @@ group_fd=1 config=0|1 sample_period=6789000 sample_type=87 -read_format=12 +read_format=12|28 disabled=0 inherit=0 mmap=0 -- 2.28.0