From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.0 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 72B29C433E0 for ; Tue, 23 Jun 2020 20:41:01 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 42A6F2053B for ; Tue, 23 Jun 2020 20:41:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1592944861; bh=rzvja3UF3NYTTw7BxVOgNjPDOe6GvHtvLbfBgJcCI2o=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=m/TpTyDOiZlyEBiTldosvW3WPw5jFpsm0oyLb68WwwMa91U2RGCina9XnJgDc8YCG hrRHdYi8FbHr7fYmcKVGWZuyfZakdatHJ2W5FkU+qdfu8eVnYU032EqoAPsP9ihRyT oTuNxzdYWnm5/NEXBARsAHUYthHFNslpErPKogHM= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2403859AbgFWUk7 (ORCPT ); Tue, 23 Jun 2020 16:40:59 -0400 Received: from mail.kernel.org ([198.145.29.99]:37190 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2392284AbgFWUkz (ORCPT ); Tue, 23 Jun 2020 16:40:55 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (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 14D5F2053B; Tue, 23 Jun 2020 20:40:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1592944855; bh=rzvja3UF3NYTTw7BxVOgNjPDOe6GvHtvLbfBgJcCI2o=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=xE4EK4jm6dyppYMzJ/qm7nTkF07LwsjBL9KZvAZzrGpLTWRZR0doH0ZSEGxB5wswu rLgdjqWI8T/OG2Ye4WEo4exTVM6EzySEQiSMJoIoIbSvlKelStFsNCMtqhB0BcfUYx 4ZkE1trKEUmp9sVn6vClUJuOlMq6Rv5h9c3GGORs= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Shaokun Zhang , Will Deacon , Mark Rutland , Sasha Levin Subject: [PATCH 4.19 151/206] drivers/perf: hisi: Fix wrong value for all counters enable Date: Tue, 23 Jun 2020 21:57:59 +0200 Message-Id: <20200623195324.417084094@linuxfoundation.org> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20200623195316.864547658@linuxfoundation.org> References: <20200623195316.864547658@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Shaokun Zhang [ Upstream commit 961abd78adcb4c72c343fcd9f9dc5e2ebbe9b448 ] In L3C uncore PMU drivers, bit16 is used to control all counters enable & disable. Wrong value is given in the driver and its default value is 1'b1, it can work because each PMU counter has its own control bits too. Let's fix the wrong value. Fixes: 2940bc433370 ("perf: hisi: Add support for HiSilicon SoC L3C PMU driver") Signed-off-by: Shaokun Zhang Cc: Will Deacon Cc: Mark Rutland Link: https://lore.kernel.org/r/1591350221-32275-1-git-send-email-zhangshaokun@hisilicon.com Signed-off-by: Will Deacon Signed-off-by: Sasha Levin --- drivers/perf/hisilicon/hisi_uncore_l3c_pmu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/perf/hisilicon/hisi_uncore_l3c_pmu.c b/drivers/perf/hisilicon/hisi_uncore_l3c_pmu.c index 0bde5d919b2eb..4aff69cbb9032 100644 --- a/drivers/perf/hisilicon/hisi_uncore_l3c_pmu.c +++ b/drivers/perf/hisilicon/hisi_uncore_l3c_pmu.c @@ -38,7 +38,7 @@ /* L3C has 8-counters */ #define L3C_NR_COUNTERS 0x8 -#define L3C_PERF_CTRL_EN 0x20000 +#define L3C_PERF_CTRL_EN 0x10000 #define L3C_EVTYPE_NONE 0xff /* -- 2.25.1