All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v14 00/28] CoreSight: Refactor power management for CoreSight path
@ 2026-05-15 20:08 Leo Yan
  2026-05-15 20:08 ` [PATCH v14 01/28] coresight: Fix source not disabled on idr_alloc_u32 failure Leo Yan
                   ` (27 more replies)
  0 siblings, 28 replies; 30+ messages in thread
From: Leo Yan @ 2026-05-15 20:08 UTC (permalink / raw)
  To: Suzuki K Poulose, Mike Leach, James Clark, Yeoreum Yun,
	Mark Rutland, Will Deacon, Yabin Cui, Keita Morisaki, Jie Gan,
	Yuanfang Zhang, Greg Kroah-Hartman, Alexander Shishkin,
	Tamas Petz, Thomas Gleixner, Peter Zijlstra
  Cc: coresight, linux-arm-kernel, Leo Yan, Mike Leach

This series focuses on CoreSight path power management.  The changes can
be divided into four parts for review:

  Patches 01 - 10: Preparison for CPU PM:
                   Fix source disabling on idr_alloc failure.
                   Fix helper enable failure handling.
                   Refactor CPU ID stored in csdev.
                   Move CPU lock to sysfs layer.
		   Move per-CPU source pointer from etm-perf to core layer.
		   Refactor etm-perf to retrieve source via per-CPU's event
		   data for lockless and get source reference during AUX
		   setup.
  Patches 11 - 13: Refactor CPU idle flow managed in the CoreSight core
                   layer.
  Patches 14 - 23: Refactor path enable / disable with range, control path
                   during CPU idle.
  Patches 24 - 25: Support the sink (TRBE) control during CPU idle.
  Patches 26 - 28: Move CPU hotplug into the core layer, and fix sysfs
                   mode for hotplug.

This series is rebased on the coresight-next branch and has been verified
on Juno-r2 (ETM + ETR) and FVP RevC (ETE + TRBE).  Built successfully
for armv7 (ARCH=arm).

---
Changes in v14:
- Fixed percpu_pm_failed write with per_cpu(percpu_pm_faile, cpu).
- Link to v13: https://lore.kernel.org/r/20260515-arm_coresight_path_power_management_improvement-v13-0-9dfc558ed65e@arm.com

Changes in v13:
- Cleared percpu_pm_failed flag when source is unregistered (Suzuki).
- Rebased on latest coresight-next.
- Link to v12: https://lore.kernel.org/r/20260511-arm_coresight_path_power_management_improvement-v12-0-1c9dcb1de8c9@arm.com

Changes in v12:
- Added comments on coresight_{get|put)_percpu_source_ref (Suzuki).
- Refined failure handling in path enable (Suzuki).
- Added coresight_is_software_source() helper (Suzuki).
- Reordered taking ref on csdev and its parent in patch 07.
- Define the enum mode with bit flags.
- Minor improvements on commit logs.
- Rebased on lastest coresight-next.
- Link to v11: https://lore.kernel.org/r/20260501-arm_coresight_path_power_management_improvement-v11-0-fc7fb9d5af1c@arm.com

Changes in v11:
- Moved per-CPU source pointer from etm-perf to core (Suzuki).
- Added grabbing/ungrabbing csdev for device reference (Suzuki).
- Minor refine for error handling and logs in CPU PM (James).
- Refactored etm-perf with fetching path/source from event data (Suzuki).
- Fixed Helper error handling (sashiko).
- Added Jie's test tag (thanks!).
- Minor improvement for comments and commit logs.
- Link to v10: https://lore.kernel.org/r/20260405-arm_coresight_path_power_management_improvement-v10-0-13e94754a8be@arm.com

Changes in v10:
- Removed redundant checks in ETMv4 PM callbacks (sashiko).
- Added a new const structure etm4_cs_pm_ops (sashiko).
- Used fine-grained spinlock on sysfs_active_config (sashiko).
- Blocked notification after failures in save / restore to avoid lockups.
- Changed Change CPUHP_AP_ARM_CORESIGHT_STARTING to
  CPUHP_AP_ARM_CORESIGHT_ONLINE so that the CPU hotplug callback runs in
  the thread context (sashiko).
- Link to v9: https://lore.kernel.org/r/20260401-arm_coresight_path_power_management_improvement-v9-0-091d73e44072@arm.com

Signed-off-by: Leo Yan <leo.yan@arm.com>

---
Jie Gan (1):
      coresight: Fix source not disabled on idr_alloc_u32 failure

Leo Yan (26):
      coresight: Handle helper enable failure properly
      coresight: Extract device init into coresight_init_device()
      coresight: Populate CPU ID into coresight_device
      coresight: Remove .cpu_id() callback from source ops
      coresight: Take hotplug lock in enable_source_store() for Sysfs mode
      coresight: perf: Retrieve path and source from event data
      coresight: Take a reference on csdev
      coresight: Move per-CPU source pointer to core layer
      coresight: Take per-CPU source reference during AUX setup
      coresight: Register CPU PM notifier in core layer
      coresight: etm4x: Hook CPU PM callbacks
      coresight: etm4x: Remove redundant checks in PM save and restore
      coresight: syscfg: Use IRQ-safe spinlock to protect active variables
      coresight: Disable source helpers in coresight_disable_path()
      coresight: Control path with range
      coresight: Use helpers to fetch first and last nodes
      coresight: Introduce coresight_enable_source() helper
      coresight: Save active path for system tracers
      coresight: etm4x: Set active path on target CPU
      coresight: etm3x: Set active path on target CPU
      coresight: sysfs: Use source's path pointer for path control
      coresight: Control path during CPU idle
      coresight: Add PM callbacks for sink device
      coresight: sysfs: Increment refcount only for software source
      coresight: Move CPU hotplug callbacks to core layer
      coresight: sysfs: Validate CPU online status for per-CPU sources

Yabin Cui (1):
      coresight: trbe: Save and restore state across CPU low power state

 drivers/hwtracing/coresight/coresight-catu.c       |   2 +-
 drivers/hwtracing/coresight/coresight-core.c       | 551 +++++++++++++++++++--
 drivers/hwtracing/coresight/coresight-cti-core.c   |   9 +-
 drivers/hwtracing/coresight/coresight-etm-perf.c   | 288 ++++++-----
 drivers/hwtracing/coresight/coresight-etm3x-core.c |  73 +--
 drivers/hwtracing/coresight/coresight-etm4x-core.c | 166 ++-----
 drivers/hwtracing/coresight/coresight-priv.h       |   6 +
 drivers/hwtracing/coresight/coresight-syscfg.c     |  38 +-
 drivers/hwtracing/coresight/coresight-syscfg.h     |   2 +
 drivers/hwtracing/coresight/coresight-sysfs.c      | 131 ++---
 drivers/hwtracing/coresight/coresight-trbe.c       |  61 ++-
 include/linux/coresight.h                          |  27 +-
 include/linux/cpuhotplug.h                         |   2 +-
 13 files changed, 874 insertions(+), 482 deletions(-)
---
base-commit: f4526ffee6ff9f5845b430957417149eded74bf3
change-id: 20251104-arm_coresight_path_power_management_improvement-dab4966f8280

Best regards,
-- 
Leo Yan <leo.yan@arm.com>



^ permalink raw reply	[flat|nested] 30+ messages in thread

end of thread, other threads:[~2026-05-16  8:57 UTC | newest]

Thread overview: 30+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-05-15 20:08 [PATCH v14 00/28] CoreSight: Refactor power management for CoreSight path Leo Yan
2026-05-15 20:08 ` [PATCH v14 01/28] coresight: Fix source not disabled on idr_alloc_u32 failure Leo Yan
2026-05-16  8:57   ` Yeoreum Yun
2026-05-15 20:08 ` [PATCH v14 02/28] coresight: Handle helper enable failure properly Leo Yan
2026-05-15 20:08 ` [PATCH v14 03/28] coresight: Extract device init into coresight_init_device() Leo Yan
2026-05-15 20:08 ` [PATCH v14 04/28] coresight: Populate CPU ID into coresight_device Leo Yan
2026-05-15 20:08 ` [PATCH v14 05/28] coresight: Remove .cpu_id() callback from source ops Leo Yan
2026-05-15 20:08 ` [PATCH v14 06/28] coresight: Take hotplug lock in enable_source_store() for Sysfs mode Leo Yan
2026-05-15 20:08 ` [PATCH v14 07/28] coresight: perf: Retrieve path and source from event data Leo Yan
2026-05-15 20:08 ` [PATCH v14 08/28] coresight: Take a reference on csdev Leo Yan
2026-05-15 20:08 ` [PATCH v14 09/28] coresight: Move per-CPU source pointer to core layer Leo Yan
2026-05-15 20:08 ` [PATCH v14 10/28] coresight: Take per-CPU source reference during AUX setup Leo Yan
2026-05-15 20:08 ` [PATCH v14 11/28] coresight: Register CPU PM notifier in core layer Leo Yan
2026-05-15 20:08 ` [PATCH v14 12/28] coresight: etm4x: Hook CPU PM callbacks Leo Yan
2026-05-15 20:08 ` [PATCH v14 13/28] coresight: etm4x: Remove redundant checks in PM save and restore Leo Yan
2026-05-15 20:08 ` [PATCH v14 14/28] coresight: syscfg: Use IRQ-safe spinlock to protect active variables Leo Yan
2026-05-15 20:08 ` [PATCH v14 15/28] coresight: Disable source helpers in coresight_disable_path() Leo Yan
2026-05-15 20:08 ` [PATCH v14 16/28] coresight: Control path with range Leo Yan
2026-05-15 20:08 ` [PATCH v14 17/28] coresight: Use helpers to fetch first and last nodes Leo Yan
2026-05-15 20:08 ` [PATCH v14 18/28] coresight: Introduce coresight_enable_source() helper Leo Yan
2026-05-15 20:08 ` [PATCH v14 19/28] coresight: Save active path for system tracers Leo Yan
2026-05-15 20:08 ` [PATCH v14 20/28] coresight: etm4x: Set active path on target CPU Leo Yan
2026-05-15 20:08 ` [PATCH v14 21/28] coresight: etm3x: " Leo Yan
2026-05-15 20:08 ` [PATCH v14 22/28] coresight: sysfs: Use source's path pointer for path control Leo Yan
2026-05-15 20:08 ` [PATCH v14 23/28] coresight: Control path during CPU idle Leo Yan
2026-05-15 20:08 ` [PATCH v14 24/28] coresight: Add PM callbacks for sink device Leo Yan
2026-05-15 20:08 ` [PATCH v14 25/28] coresight: trbe: Save and restore state across CPU low power state Leo Yan
2026-05-15 20:08 ` [PATCH v14 26/28] coresight: sysfs: Increment refcount only for software source Leo Yan
2026-05-15 20:08 ` [PATCH v14 27/28] coresight: Move CPU hotplug callbacks to core layer Leo Yan
2026-05-15 20:08 ` [PATCH v14 28/28] coresight: sysfs: Validate CPU online status for per-CPU sources Leo Yan

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.