Received: by 2002:a05:7412:798b:b0:fc:a2b0:25d7 with SMTP id fb11csp873864rdb; Fri, 23 Feb 2024 02:53:05 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCWoWNogySPoJNYBLmsDEv8ttudz9iXrTWuQLHFciQYtOkV8GcmBUBV77JGEkFKZCFIlmeZhw9QRTDkGyTAsr8f/xZr3Y0ZQIhy3L4n3/g== X-Google-Smtp-Source: AGHT+IFRFuoBsaGdS6d9jWC6FqcV5ERMJ9GZEkTlq49ShmILk/22iMJKC6NCwxA2lzQjQmYFx6VX X-Received: by 2002:a92:c843:0:b0:365:21fb:bbd2 with SMTP id b3-20020a92c843000000b0036521fbbbd2mr1524340ilq.7.1708685585393; Fri, 23 Feb 2024 02:53:05 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708685585; cv=pass; d=google.com; s=arc-20160816; b=fTFRGnELNga6GFXHhZTYk7cR0VGFBLaK2GTj+WzodMfgwZzWf6eE4k+eiJATlmsRPO wes4GKIV8VKSaYd1IskBtksXXsUj6Nihi/ixhA2qXhHrc5u+3ezGzViqcgepdAFF6kvS Fj9rd6m8VwLYlsNgQHTK+DF9+U/qFbvUxnY2hVwgQN+TWwu+2OrfQ7zvVXBUj9te5u/G lCbeKa/yZN94wJ1EyM9FB7dKsxBWXuTc0hiyLX406/FG3IBqlRJXctlZoD404YMD9Ktm JuMtnofYkDuRO7/8Iq6VHNOUQFuvbHRqiYVkq6NsFQX5gp43Ligt4EnZosQxj70tXtaI tsVQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from; bh=Y80pLqT83PGag8aDzoaV6Sd/q+TmsfLxglbq33oKlVg=; fh=jersQh8TE0KFZCA3V8poDAKHKQ+owT+1iuzuvpXietI=; b=zp1JDEhl0Az/UrUETJj50ZAvgPRthpsGGRToa+vItbMvitwOOcpwcxmzWLLtmSqblY UBYqll5DpPneG1HcFzLUlftNQfy51IZrR57080qxhWVDfOOn2MOZrlZkZXLIMWatFNrg i4vU/f2JPLJQGeCieI5AFIVvXLjr2ehM/EgQ4HXgufchhDVaz/StMqzDgygNljAATAkY SpXbwAT/znlhoIoame+IOFLV3XFflaWxAx6FQHUyHbOSkSsGTB4cLrM0gBd94MavXkFn M0X3JF+yemhp/LV+jGAdS1p5lPUURtFGJba5AT6X04xOcwkOTM9fToxTlV4OsK9dWR1R xqfw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=huawei.com dmarc=pass fromdomain=huawei.com); spf=pass (google.com: domain of linux-kernel+bounces-78147-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-78147-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id d28-20020a63735c000000b005d39e412039si12153162pgn.8.2024.02.23.02.53.04 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 23 Feb 2024 02:53:05 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-78147-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=huawei.com dmarc=pass fromdomain=huawei.com); spf=pass (google.com: domain of linux-kernel+bounces-78147-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-78147-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 4181BB2295C for ; Fri, 23 Feb 2024 10:39:04 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 4D9387A712; Fri, 23 Feb 2024 10:38:25 +0000 (UTC) Received: from szxga05-in.huawei.com (szxga05-in.huawei.com [45.249.212.191]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 601045D48A for ; Fri, 23 Feb 2024 10:38:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=45.249.212.191 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708684704; cv=none; b=mpNi/vHKQf4CTcO8k9DSFBUG6/hEB/UjVrQx5LYOFSOrQXE9LfEm5EY2VhcnHgr71tFeghOKujFB8F2xCwAqc7q0QvmvQGJ6KbNssDI8XbmTMoQ0yCYzyCGF82qy8QqYUdxg0L7lZjMA4HGK5fAcYiux2QKuEEPSP1kjrBD4YXM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708684704; c=relaxed/simple; bh=5n3559cEWEbpQWlpMl+OVrcvBOIGzA8flYrbVfgKdKw=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=jp7jvuLZ3dBy5joKx9eCXBaDUNkq8huIztRYMPxFOm0XYdo+TdKfkxvtuE2PQb/X+8Im96C4k1dl9QMT9iibDIE+pM4D6ucXRl8Ef05dhmd5fHSA6neWKIeJq5cySB+etN/MhQbeg3BpxDgOKjC4HaFiFw4nfugcUwO/ckWJoy0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com; spf=pass smtp.mailfrom=huawei.com; arc=none smtp.client-ip=45.249.212.191 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=huawei.com Received: from mail.maildlp.com (unknown [172.19.163.44]) by szxga05-in.huawei.com (SkyGuard) with ESMTP id 4Th5vS6z7Wz1FKlQ; Fri, 23 Feb 2024 18:33:24 +0800 (CST) Received: from canpemm500009.china.huawei.com (unknown [7.192.105.203]) by mail.maildlp.com (Postfix) with ESMTPS id D68C91400CB; Fri, 23 Feb 2024 18:38:18 +0800 (CST) Received: from localhost.localdomain (10.50.165.33) by canpemm500009.china.huawei.com (7.192.105.203) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.35; Fri, 23 Feb 2024 18:38:18 +0800 From: Yicong Yang To: , , , , , CC: , , , Subject: [PATCH v2 1/8] drivers/perf: hisi_pcie: Rename hisi_pcie_pmu_{config,clear}_filter() Date: Fri, 23 Feb 2024 18:33:52 +0800 Message-ID: <20240223103359.18669-2-yangyicong@huawei.com> X-Mailer: git-send-email 2.31.0 In-Reply-To: <20240223103359.18669-1-yangyicong@huawei.com> References: <20240223103359.18669-1-yangyicong@huawei.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: dggems705-chm.china.huawei.com (10.3.19.182) To canpemm500009.china.huawei.com (7.192.105.203) From: Yicong Yang hisi_pcie_pmu_{config,clear}_filter() are config/clear HISI_PCIE_EVENT_CTRL register which contains not only the filter but also the event code. The function names are bit misleading. Rename it to hisi_pcie_pmu_{config,clear}_event_ctrl() to reflects their functions more accurately. Signed-off-by: Yicong Yang --- drivers/perf/hisilicon/hisi_pcie_pmu.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/perf/hisilicon/hisi_pcie_pmu.c b/drivers/perf/hisilicon/hisi_pcie_pmu.c index b90ba8aca3fa..9760ddde46fd 100644 --- a/drivers/perf/hisilicon/hisi_pcie_pmu.c +++ b/drivers/perf/hisilicon/hisi_pcie_pmu.c @@ -216,7 +216,7 @@ static void hisi_pcie_pmu_writeq(struct hisi_pcie_pmu *pcie_pmu, u32 reg_offset, writeq_relaxed(val, pcie_pmu->base + offset); } -static void hisi_pcie_pmu_config_filter(struct perf_event *event) +static void hisi_pcie_pmu_config_event_ctrl(struct perf_event *event) { struct hisi_pcie_pmu *pcie_pmu = to_pcie_pmu(event->pmu); struct hw_perf_event *hwc = &event->hw; @@ -259,7 +259,7 @@ static void hisi_pcie_pmu_config_filter(struct perf_event *event) hisi_pcie_pmu_writeq(pcie_pmu, HISI_PCIE_EVENT_CTRL, hwc->idx, reg); } -static void hisi_pcie_pmu_clear_filter(struct perf_event *event) +static void hisi_pcie_pmu_clear_event_ctrl(struct perf_event *event) { struct hisi_pcie_pmu *pcie_pmu = to_pcie_pmu(event->pmu); struct hw_perf_event *hwc = &event->hw; @@ -505,7 +505,7 @@ static void hisi_pcie_pmu_start(struct perf_event *event, int flags) WARN_ON_ONCE(!(hwc->state & PERF_HES_UPTODATE)); hwc->state = 0; - hisi_pcie_pmu_config_filter(event); + hisi_pcie_pmu_config_event_ctrl(event); hisi_pcie_pmu_enable_counter(pcie_pmu, hwc); hisi_pcie_pmu_enable_int(pcie_pmu, hwc); hisi_pcie_pmu_set_period(event); @@ -526,7 +526,7 @@ static void hisi_pcie_pmu_stop(struct perf_event *event, int flags) hisi_pcie_pmu_event_update(event); hisi_pcie_pmu_disable_int(pcie_pmu, hwc); hisi_pcie_pmu_disable_counter(pcie_pmu, hwc); - hisi_pcie_pmu_clear_filter(event); + hisi_pcie_pmu_clear_event_ctrl(event); WARN_ON_ONCE(hwc->state & PERF_HES_STOPPED); hwc->state |= PERF_HES_STOPPED; -- 2.24.0