From patchwork Tue May 23 13:18:22 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Junhao He X-Patchwork-Id: 13252245 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 836B3C7EE26 for ; Tue, 23 May 2023 13:20:57 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-ID:Date:Subject:CC :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=rjaGOW7BBSuULvcDwV3gdsUDlMM5IHT8Ch682Ze4r7g=; b=wgnpVLCUQWQPP0 FB283YH4e3WCJHJo0tOxGMAwHz7HqPjXD8WSg9yBH+1EiijHid3tBi8AEseB2iIETN9b/IY91r9pQ wv6KaESbCNlAYipVzhJVtdD91xTYH/suU4mxH4PXgzj3v9Lt76w8MosTMNs+TBPGEKVVopML0JLa5 NPInUJT0f/+N/7BCQfG3zdvsOCuhbXBp5MAM79y71DqbgYMIygQRk/ipjCqeyZiwLjwoXhWNB9GRv JAw8bBwML03UlAKo1lXtR6UdF1asNL7yEqyHrppnZGRDG+JPjS1fX8mmWYr9/RoUBsCn0S6wf+GTJ cxvNCvU5UhK+SKBo/22Q==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1q1RwH-00AMYy-24; Tue, 23 May 2023 13:20:33 +0000 Received: from szxga08-in.huawei.com ([45.249.212.255]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1q1RwD-00AMUS-1G for linux-arm-kernel@lists.infradead.org; Tue, 23 May 2023 13:20:32 +0000 Received: from dggpeml500002.china.huawei.com (unknown [172.30.72.55]) by szxga08-in.huawei.com (SkyGuard) with ESMTP id 4QQZZC4CZ8z18LYw; Tue, 23 May 2023 21:15:47 +0800 (CST) Received: from localhost.localdomain (10.69.192.56) by dggpeml500002.china.huawei.com (7.185.36.158) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.23; Tue, 23 May 2023 21:20:15 +0800 From: Junhao He To: , , , CC: , , , , , , Subject: [PATCH 0/3] Add support for HiSilicon SoC uncore PMU Date: Tue, 23 May 2023 21:18:22 +0800 Message-ID: <20230523131825.6102-1-hejunhao3@huawei.com> X-Mailer: git-send-email 2.33.0 MIME-Version: 1.0 X-Originating-IP: [10.69.192.56] X-ClientProxiedBy: dggems705-chm.china.huawei.com (10.3.19.182) To dggpeml500002.china.huawei.com (7.185.36.158) X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230523_062029_638162_DF14DBCB X-CRM114-Status: UNSURE ( 8.65 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Add support for HiSilicon UC/H60PA/PAv3 PMU driver. PAv3 PMU: Compared with the PAv2 PMU, the PAv3 PMU has different event. The version of PMU version register is used to distinguish the v2 and v3. H60PA PMU: The H60PA PMU and PA are two different devices. The H60PA PMU supports higher bandwidth, and the PA PMU delay is relatively low. Different HIDs are used to distinguish the delay. UC PMU: Each cluster is integrated with a unified cache (UC) PMU, which provides consistency between NUMA and UMA domains. It sits between L2 and the memory system. Junhao He (3): drivers/perf: hisi: Add support for HiSilicon H60PA and PAv3 PMU driver drivers/perf: hisi: Add support for HiSilicon UC PMU driver docs: perf: Add new description for HiSilicon UC PMU Documentation/admin-guide/perf/hisi-pmu.rst | 8 + drivers/perf/hisilicon/Makefile | 2 +- drivers/perf/hisilicon/hisi_uncore_pa_pmu.c | 138 ++++- drivers/perf/hisilicon/hisi_uncore_pmu.c | 5 +- drivers/perf/hisilicon/hisi_uncore_pmu.h | 42 +- drivers/perf/hisilicon/hisi_uncore_uc_pmu.c | 581 ++++++++++++++++++++ 6 files changed, 757 insertions(+), 19 deletions(-) create mode 100644 drivers/perf/hisilicon/hisi_uncore_uc_pmu.c