Received: by 2002:a05:6a10:413:0:0:0:0 with SMTP id 19csp2245429pxp; Mon, 21 Mar 2022 14:52:02 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzb46NJByjL3BKih6FAe8zAFuS6mIJ/65SSTSA9N4StYWVzXBLU8lHEuCb2Fr70caDZRWiI X-Received: by 2002:a05:6a00:158b:b0:4f8:e4a9:973f with SMTP id u11-20020a056a00158b00b004f8e4a9973fmr25845589pfk.2.1647899521996; Mon, 21 Mar 2022 14:52:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1647899521; cv=none; d=google.com; s=arc-20160816; b=sdg28aRPPS/BhCaJTP9eK7GyuB0vOVRceTtaraflz87xEH0ySDcufG/skr1ab15tMQ 5NqqhhYRNzk4UU2cIbxZgrd4e0pFD8+D2ZzfBtC3VUTCAQ4OxTr2el2AFXqftGxujh20 nZ/wAB8hKolgxnYWWw9xunIfkObWYbBAEZPH0OyafXSKhJaQ3iJ8x0Re69q75wJIobYe r20aPNth1dKD9Qzxy/aFv/dcf0UNYr+Doa48dG+OQmfZc/W+IZzrdo0tiX7VHRlt6BPJ /D4LLDRWWcTsyMbOS1pHuQWOItVEcmedvF8qIFQ92RRD6qSkoymuvD45Vdtto06IvSpO XC6w== 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 :message-id:date:subject:cc:to:from; bh=Ccdg6ThnoNyM1P7uUd/qfSCVGtZG/HLTwCRZtz/8M2w=; b=u2tYX8P+ke3e6mYXPWcgf9nPhbP7aNGMuo89228SBQjNUwlnIHry/wBUcJyQPYPC84 GSLsf0wvrko6AmCE7WhMY+OrfDhiZfMWZaFgS6msUdDKmDeeLE6gq8qu2unkfL9VhVDT 8jPcAEvaboI9U8sCT5fo6+Az5mZTK+e5saYeMTCza4w136qqS5N6edQAx97ngkj3GZpm dt5Y1I4l5ELfKA7XOfNcchNu46jSwohU0cza71Fu3erWIYyIgATB8Vo2Cb5Wxao4CrxD fOipyom4nmJMBSd29UixiWzhZMgSCVvc6zain/byxYatoQzse0PrD9FT8WKCKN1RleQ/ xxXA== 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:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id z16-20020a170902ccd000b00153b2d1656asi13419666ple.370.2022.03.21.14.52.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 21 Mar 2022 14:52:01 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id A2A7B188A3C; Mon, 21 Mar 2022 14:19:23 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1344706AbiCUHEQ (ORCPT + 99 others); Mon, 21 Mar 2022 03:04:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46704 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S245498AbiCUHEM (ORCPT ); Mon, 21 Mar 2022 03:04:12 -0400 Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 432EE4757C for ; Mon, 21 Mar 2022 00:02:48 -0700 (PDT) Received: from kwepemi100022.china.huawei.com (unknown [172.30.72.53]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4KMQVt5GcjzCqvP; Mon, 21 Mar 2022 15:00:38 +0800 (CST) Received: from kwepemm600003.china.huawei.com (7.193.23.202) by kwepemi100022.china.huawei.com (7.221.188.126) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.24; Mon, 21 Mar 2022 15:02:43 +0800 Received: from localhost.localdomain (10.67.164.66) by kwepemm600003.china.huawei.com (7.193.23.202) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.21; Mon, 21 Mar 2022 15:02:43 +0800 From: Qi Liu To: , CC: , , , Subject: [PATCH v3 0/2] Add Support for HiSilicon CPA PMU Date: Mon, 21 Mar 2022 15:01:22 +0800 Message-ID: <20220321070124.41338-1-liuqi115@huawei.com> X-Mailer: git-send-email 2.24.0 MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [10.67.164.66] X-ClientProxiedBy: dggems703-chm.china.huawei.com (10.3.19.180) To kwepemm600003.china.huawei.com (7.193.23.202) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RDNS_NONE, SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no 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 Add Support for HiSilicon CPA PMU driver. Json file in perf tool is applied in https://lore.kernel.org/linux-arm-kernel/YhkhSZp+a715Ldzr@kernel.org/. Change since v2: - Associate CPA PMUs with CPUs online, rather than CPUs in the nearest SCCL. - Move CPA power management to probe and remove function. - Address the comments from John. - Link: https://lore.kernel.org/linux-arm-kernel/20220224111129.41416-1-liuqi115@huawei.com/ Change since v1: - Address the comments from John. - Link: https://lore.kernel.org/linux-arm-kernel/20220214114228.40859-1-liuqi115@huawei.com/ Qi Liu (2): drivers/perf: hisi: Associate PMUs in SICL with CPUs online drivers/perf: hisi: Add Support for CPA PMU drivers/perf/hisilicon/Makefile | 2 +- drivers/perf/hisilicon/hisi_uncore_cpa_pmu.c | 400 +++++++++++++++++++ drivers/perf/hisilicon/hisi_uncore_pa_pmu.c | 18 +- drivers/perf/hisilicon/hisi_uncore_pmu.c | 4 + drivers/perf/hisilicon/hisi_uncore_pmu.h | 1 + include/linux/cpuhotplug.h | 1 + 6 files changed, 414 insertions(+), 12 deletions(-) create mode 100644 drivers/perf/hisilicon/hisi_uncore_cpa_pmu.c -- 2.24.0