Received: by 2002:a05:6a10:9e8c:0:0:0:0 with SMTP id y12csp281187pxx; Wed, 28 Oct 2020 04:56:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyE32hfI5wsnoZMTQ/qSDccI4GVs6sX5vpE5hE+kYXYI9ddsp1UDxGv2sDn2Xmx6YNwl0eC X-Received: by 2002:a17:907:960b:: with SMTP id gb11mr6653791ejc.396.1603886182838; Wed, 28 Oct 2020 04:56:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1603886182; cv=none; d=google.com; s=arc-20160816; b=Nn7PUjRS05y2sWCnIeH9QZ/QOh0kCGyISDy4cphjiSzNH0oLm4wAQ0ts8mBV1vAqS9 Em/Xo/Xz7dDRPytvBaXUgb+dZn0Is3Mq2thScT53eCgi97MuzuWIG6BTS7/+UjRP6N4D SAXbOtlGkI23hWR2537UoiDrozv3bqceTeu6b2tgK/Tf+b/cHxhinZxr5FDFZjDu2HTY 9L1Kp1HTCreh9kXmUEcbGNO3vo6QHaMq89bVHJx2Vv+WYfa8EFLqq67JL5ZRqEXxvABR pKutJfy6ouwbrnHtwWUcZ38K4BLCGKFKmwGEUbLM53JumJ+UD7pk8uUyUYFs0wfu/UXH SKZw== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=qLu4GYhGneLfzX4beLzSqRHXWcD5uv6Fv3L1erfl67Y=; b=CGy0t9HRaN6/+qz+4fwCw4mkJ4xR/n9vNPT8j+HHASUwNnbZh6A14SyNXLfslJF711 4g0oqJALhh3CvyD5Aarhpw7XPaMiQqEPGwr9YwxHcKV8zg85YN6+IBzwHwBwmyG30k2v +WP1T84DnE+6+EfRpO2gERFiLbY9oMkBJqoFOK0s/bSmtpFjZBTes0r0XJ/s5++wyYzN 6/eG6igIlD3nPhFevs2JD8wDsRpPj0D0kxX/GTcwpLoWHG0czv+X5PAKvn0VjFg1L3lK EOqp8CMrBvFuBx6cdN2IUhzJqAkwYMDEGhKcjELbuMBaukSoRAo3Fo9mEsqvG3iowTJc mx/g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=qOUM4Eh3; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id t1si2868715ejb.712.2020.10.28.04.56.00; Wed, 28 Oct 2020 04:56:22 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=qOUM4Eh3; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1794787AbgJ0PNd (ORCPT + 99 others); Tue, 27 Oct 2020 11:13:33 -0400 Received: from mail.kernel.org ([198.145.29.99]:40414 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1793200AbgJ0PGS (ORCPT ); Tue, 27 Oct 2020 11:06:18 -0400 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id F0D0821D24; Tue, 27 Oct 2020 15:06:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1603811177; bh=82GcXZDbIcivgRmlOwbWBv25JRjEbhFhmORh4A3grv4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=qOUM4Eh3e4SSHqnpS1ppB0BnUsEmOi4sqaB023vgOQc8mU4cJtS4gggGVL0BkKVh0 sRoo4iYIlFWI8v3TSU89I1vYesLsGPxpDd/v4ARv6ekguS9i94UbaH+arNrxqr5fED z+f2IHWfwDMTPWqA5yorfpBH8RW0uKf0TIjcgaSI= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Kajol Jain , Michael Ellerman , Sasha Levin Subject: [PATCH 5.8 400/633] powerpc/perf/hv-gpci: Fix starting index value Date: Tue, 27 Oct 2020 14:52:23 +0100 Message-Id: <20201027135541.476126064@linuxfoundation.org> X-Mailer: git-send-email 2.29.1 In-Reply-To: <20201027135522.655719020@linuxfoundation.org> References: <20201027135522.655719020@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Kajol Jain [ Upstream commit 0f9866f7e85765bbda86666df56c92f377c3bc10 ] Commit 9e9f60108423f ("powerpc/perf/{hv-gpci, hv-common}: generate requests with counters annotated") adds a framework for defining gpci counters. In this patch, they adds starting_index value as '0xffffffffffffffff'. which is wrong as starting_index is of size 32 bits. Because of this, incase we try to run hv-gpci event we get error. In power9 machine: command#: perf stat -e hv_gpci/system_tlbie_count_and_time_tlbie_instructions_issued/ -C 0 -I 1000 event syntax error: '..bie_count_and_time_tlbie_instructions_issued/' \___ value too big for format, maximum is 4294967295 This patch fix this issue and changes starting_index value to '0xffffffff' After this patch: command#: perf stat -e hv_gpci/system_tlbie_count_and_time_tlbie_instructions_issued/ -C 0 -I 1000 1.000085786 1,024 hv_gpci/system_tlbie_count_and_time_tlbie_instructions_issued/ 2.000287818 1,024 hv_gpci/system_tlbie_count_and_time_tlbie_instructions_issued/ 2.439113909 17,408 hv_gpci/system_tlbie_count_and_time_tlbie_instructions_issued/ Fixes: 9e9f60108423 ("powerpc/perf/{hv-gpci, hv-common}: generate requests with counters annotated") Signed-off-by: Kajol Jain Signed-off-by: Michael Ellerman Link: https://lore.kernel.org/r/20201003074943.338618-1-kjain@linux.ibm.com Signed-off-by: Sasha Levin --- arch/powerpc/perf/hv-gpci-requests.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/arch/powerpc/perf/hv-gpci-requests.h b/arch/powerpc/perf/hv-gpci-requests.h index e608f9db12ddc..8965b4463d433 100644 --- a/arch/powerpc/perf/hv-gpci-requests.h +++ b/arch/powerpc/perf/hv-gpci-requests.h @@ -95,7 +95,7 @@ REQUEST(__field(0, 8, partition_id) #define REQUEST_NAME system_performance_capabilities #define REQUEST_NUM 0x40 -#define REQUEST_IDX_KIND "starting_index=0xffffffffffffffff" +#define REQUEST_IDX_KIND "starting_index=0xffffffff" #include I(REQUEST_BEGIN) REQUEST(__field(0, 1, perf_collect_privileged) __field(0x1, 1, capability_mask) @@ -223,7 +223,7 @@ REQUEST(__field(0, 2, partition_id) #define REQUEST_NAME system_hypervisor_times #define REQUEST_NUM 0xF0 -#define REQUEST_IDX_KIND "starting_index=0xffffffffffffffff" +#define REQUEST_IDX_KIND "starting_index=0xffffffff" #include I(REQUEST_BEGIN) REQUEST(__count(0, 8, time_spent_to_dispatch_virtual_processors) __count(0x8, 8, time_spent_processing_virtual_processor_timers) @@ -234,7 +234,7 @@ REQUEST(__count(0, 8, time_spent_to_dispatch_virtual_processors) #define REQUEST_NAME system_tlbie_count_and_time #define REQUEST_NUM 0xF4 -#define REQUEST_IDX_KIND "starting_index=0xffffffffffffffff" +#define REQUEST_IDX_KIND "starting_index=0xffffffff" #include I(REQUEST_BEGIN) REQUEST(__count(0, 8, tlbie_instructions_issued) /* -- 2.25.1