Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Yicong Yang <yangyicong@huawei.com>
To: <jonathan.cameron@huawei.com>, <will@kernel.org>,
	<mark.rutland@arm.com>, <linux-arm-kernel@lists.infradead.org>
Cc: <yangyicong@hisilicon.com>, <hejunhao3@huawei.com>,
	<linuxarm@huawei.com>, <wangyushan12@huawei.com>,
	<prime.zeng@hisilicon.com>
Subject: [PATCH v4 00/10] Refactor the common parts to the HiSilicon Uncore PMU core and cleanups
Date: Tue, 3 Dec 2024 20:50:39 +0800	[thread overview]
Message-ID: <20241203125049.39458-1-yangyicong@huawei.com> (raw)

From: Yicong Yang <yangyicong@hisilicon.com>

This series mainly contains the refactor of the HiSilicon Uncore PMU by
extracting the common parts from each drivers into the core:
- the retrieving of the PMU topology ID
- the common sysfs attributes like cpumask and identifier

In order to achieve this, we need to do below preparation:
- refactor the detection of associated CPUs for PMUs locates on a SICL
- maintain the topology information in a dedicated data structure
- provides a generic implementation of cpumask/identifier attributes

Besides also include below changes/cleanups in this patchset
- add one new sysfs attributes for better describing the topology information
  of the associated CPUs of the PMU.
- define a symbol namespace for HiSilicon Uncore PMUs to avoid pollute the
  common ones
- two minor nonfunctional cleanups of DDRC PMU

Change since v3:
- Split the associated_cpus refactor patches according to the functions, hope
  will be easier to review
- Drop the use of cpu_online_mask out of cpuhp
Link: https://lore.kernel.org/linux-arm-kernel/20241026072424.29887-1-yangyicong@huawei.com/

Change since v2:
- remove one redundant newline and add Jonathan's tag for Patch 1 and 5
Link: https://lore.kernel.org/linux-arm-kernel/20241022145305.47056-1-yangyicong@huawei.com/

Changes since v1:
Address Jonathan's comments and add tags for some patches
- Provide a generic cpumask/identifier attribute group
- refine the comments/commit as suggested
Link: https://lore.kernel.org/linux-arm-kernel/20241018095745.57057-1-yangyicong@huawei.com/

Junhao He (2):
  drivers/perf: hisi: Fix incorrect variable name "hha_pmu" in DDRC PMU
    driver
  drivers/perf: hisi: Delete redundant blank line of DDRC PMU

Yicong Yang (8):
  drivers/perf: hisi: Define a symbol namespace for HiSilicon Uncore
    PMUs
  drivers/perf: hisi: Don't update the associated_cpus on CPU offline
  drivers/perf: hisi: Migrate to one online CPU if no associated one
    online
  drivers/perf: hisi: Refactor the detection of associated CPUs
  drivers/perf: hisi: Extract topology information to a separate
    structure
  drivers/perf: hisi: Add a common function to retrieve topology from
    firmware
  drivers/perf: hisi: Provide a generic implementation of
    cpumask/identifier
  drivers/perf: hisi: Export associated CPUs of each PMU through sysfs

 Documentation/admin-guide/perf/hisi-pmu.rst   |   5 +-
 drivers/perf/hisilicon/hisi_uncore_cpa_pmu.c  |  42 +----
 drivers/perf/hisilicon/hisi_uncore_ddrc_pmu.c |  61 ++-----
 drivers/perf/hisilicon/hisi_uncore_hha_pmu.c  |  48 ++----
 drivers/perf/hisilicon/hisi_uncore_l3c_pmu.c  |  44 ++---
 drivers/perf/hisilicon/hisi_uncore_pa_pmu.c   |  53 ++----
 drivers/perf/hisilicon/hisi_uncore_pmu.c      | 160 +++++++++++++-----
 drivers/perf/hisilicon/hisi_uncore_pmu.h      |  49 +++++-
 drivers/perf/hisilicon/hisi_uncore_sllc_pmu.c |  43 +----
 drivers/perf/hisilicon/hisi_uncore_uc_pmu.c   |  45 ++---
 10 files changed, 248 insertions(+), 302 deletions(-)

-- 
2.24.0



             reply	other threads:[~2024-12-03 13:12 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-03 12:50 Yicong Yang [this message]
2024-12-03 12:50 ` [PATCH v4 01/10] drivers/perf: hisi: Define a symbol namespace for HiSilicon Uncore PMUs Yicong Yang
2024-12-03 12:50 ` [PATCH v4 02/10] drivers/perf: hisi: Don't update the associated_cpus on CPU offline Yicong Yang
2024-12-03 12:50 ` [PATCH v4 03/10] drivers/perf: hisi: Migrate to one online CPU if no associated one online Yicong Yang
2024-12-03 12:50 ` [PATCH v4 04/10] drivers/perf: hisi: Refactor the detection of associated CPUs Yicong Yang
2024-12-03 12:50 ` [PATCH v4 05/10] drivers/perf: hisi: Extract topology information to a separate structure Yicong Yang
2024-12-03 12:50 ` [PATCH v4 06/10] drivers/perf: hisi: Add a common function to retrieve topology from firmware Yicong Yang
2024-12-03 12:50 ` [PATCH v4 07/10] drivers/perf: hisi: Provide a generic implementation of cpumask/identifier Yicong Yang
2024-12-03 12:50 ` [PATCH v4 08/10] drivers/perf: hisi: Export associated CPUs of each PMU through sysfs Yicong Yang
2024-12-09 15:48   ` Will Deacon
2024-12-10 10:49     ` Yicong Yang
2024-12-10 11:39       ` Will Deacon
2024-12-10 13:02         ` Yicong Yang
2024-12-03 12:50 ` [PATCH v4 09/10] drivers/perf: hisi: Fix incorrect variable name "hha_pmu" in DDRC PMU driver Yicong Yang
2024-12-03 12:50 ` [PATCH v4 10/10] drivers/perf: hisi: Delete redundant blank line of DDRC PMU Yicong Yang
2024-12-10 12:05 ` [PATCH v4 00/10] Refactor the common parts to the HiSilicon Uncore PMU core and cleanups Will Deacon
2024-12-10 13:04   ` Yicong Yang

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20241203125049.39458-1-yangyicong@huawei.com \
    --to=yangyicong@huawei.com \
    --cc=hejunhao3@huawei.com \
    --cc=jonathan.cameron@huawei.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linuxarm@huawei.com \
    --cc=mark.rutland@arm.com \
    --cc=prime.zeng@hisilicon.com \
    --cc=wangyushan12@huawei.com \
    --cc=will@kernel.org \
    --cc=yangyicong@hisilicon.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox