public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/8] drm/panthor: Localize register access by component
@ 2026-04-10 16:46 Karunika Choo
  2026-04-10 16:46 ` [PATCH 1/8] drm/panthor: Pass an iomem pointer to GPU register access helpers Karunika Choo
                   ` (7 more replies)
  0 siblings, 8 replies; 17+ messages in thread
From: Karunika Choo @ 2026-04-10 16:46 UTC (permalink / raw)
  To: dri-devel
  Cc: nd, Boris Brezillon, Steven Price, Liviu Dudau, Maarten Lankhorst,
	Maxime Ripard, Thomas Zimmermann, David Airlie, Simona Vetter,
	linux-kernel

Hi all,

This series refactors the panthor register access paths so that each
component uses its own local iomem base instead of relying on the
global device mapping throughout the driver.

Today a number of register definitions and helpers are still expressed
in terms of the full device register space, which makes it easy for one
component to reach into another component's registers.

The series prepares the driver for a cleaner per-component layout in 3
steps:
- make the low-level GPU register helpers operate on an iomem pointer
  rather than a panthor_device pointer
- split register definitions and move cross-component accesses behind
  helpers owned by the relevant component
- convert GPU, PWR, firmware and MMU code to use component-local iomem
  bases, while keeping IRQ handling on a dedicated IRQ-local base.

The end result is that register accesses become more obviously scoped to
the component that owns them, cross-component register accesses are
removed from callers, and the common IRQ helpers no longer depend on
absolute register offsets.

No functional change is intended.

Patch overview:
  1. drm/panthor: Pass an iomem pointer to GPU register access helpers
  2. drm/panthor: Split register definitions by components
  3. drm/panthor: Replace cross-component register accesses with helpers
  4. drm/panthor: Store IRQ register base iomem pointer in panthor_irq
  5. drm/panthor: Use a local iomem base for GPU registers
  6. drm/panthor: Use a local iomem base for PWR registers
  7. drm/panthor: Use a local iomem base for MCU_CONTROL registers
  8. drm/panthor: Use a local iomem base for MMU_AS registers

Karunika Choo (8):
  drm/panthor: Pass an iomem pointer to GPU register access helpers
  drm/panthor: Split register definitions by components
  drm/panthor: Replace cross-component register accesses with helpers
  drm/panthor: Store IRQ register base iomem pointer in panthor_irq
  drm/panthor: Use a local iomem base for GPU registers
  drm/panthor: Use a local iomem base for PWR registers
  drm/panthor: Use a local iomem base for firmware control registers
  drm/panthor: Use a local iomem base for MMU AS registers

 drivers/gpu/drm/panthor/panthor_device.c   |  28 +-
 drivers/gpu/drm/panthor/panthor_device.h   |  92 ++++---
 drivers/gpu/drm/panthor/panthor_drv.c      |   7 +-
 drivers/gpu/drm/panthor/panthor_fw.c       |  41 +--
 drivers/gpu/drm/panthor/panthor_fw.h       |   1 +
 drivers/gpu/drm/panthor/panthor_fw_regs.h  |  29 ++
 drivers/gpu/drm/panthor/panthor_gpu.c      | 100 +++++--
 drivers/gpu/drm/panthor/panthor_gpu.h      |   6 +
 drivers/gpu/drm/panthor/panthor_gpu_regs.h | 110 ++++++++
 drivers/gpu/drm/panthor/panthor_heap.c     |   2 +-
 drivers/gpu/drm/panthor/panthor_hw.c       |  50 ++--
 drivers/gpu/drm/panthor/panthor_hw.h       |   2 +-
 drivers/gpu/drm/panthor/panthor_hw_regs.h  |  16 ++
 drivers/gpu/drm/panthor/panthor_mmu.c      |  46 ++--
 drivers/gpu/drm/panthor/panthor_mmu_regs.h |  69 +++++
 drivers/gpu/drm/panthor/panthor_pwr.c      |  93 ++++---
 drivers/gpu/drm/panthor/panthor_pwr_regs.h |  79 ++++++
 drivers/gpu/drm/panthor/panthor_regs.h     | 291 ---------------------
 drivers/gpu/drm/panthor/panthor_sched.c    |   5 +-
 19 files changed, 586 insertions(+), 481 deletions(-)
 create mode 100644 drivers/gpu/drm/panthor/panthor_fw_regs.h
 create mode 100644 drivers/gpu/drm/panthor/panthor_gpu_regs.h
 create mode 100644 drivers/gpu/drm/panthor/panthor_hw_regs.h
 create mode 100644 drivers/gpu/drm/panthor/panthor_mmu_regs.h
 create mode 100644 drivers/gpu/drm/panthor/panthor_pwr_regs.h
 delete mode 100644 drivers/gpu/drm/panthor/panthor_regs.h

--
2.43.0


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

end of thread, other threads:[~2026-04-10 18:13 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-04-10 16:46 [PATCH 0/8] drm/panthor: Localize register access by component Karunika Choo
2026-04-10 16:46 ` [PATCH 1/8] drm/panthor: Pass an iomem pointer to GPU register access helpers Karunika Choo
2026-04-10 18:11   ` Boris Brezillon
2026-04-10 16:46 ` [PATCH 2/8] drm/panthor: Split register definitions by components Karunika Choo
2026-04-10 18:08   ` Boris Brezillon
2026-04-10 16:46 ` [PATCH 3/8] drm/panthor: Replace cross-component register accesses with helpers Karunika Choo
2026-04-10 17:55   ` Boris Brezillon
2026-04-10 16:46 ` [PATCH 4/8] drm/panthor: Store IRQ register base iomem pointer in panthor_irq Karunika Choo
2026-04-10 17:53   ` Boris Brezillon
2026-04-10 16:46 ` [PATCH 5/8] drm/panthor: Use a local iomem base for GPU registers Karunika Choo
2026-04-10 18:11   ` Boris Brezillon
2026-04-10 16:46 ` [PATCH 6/8] drm/panthor: Use a local iomem base for PWR registers Karunika Choo
2026-04-10 18:12   ` Boris Brezillon
2026-04-10 16:46 ` [PATCH 7/8] drm/panthor: Use a local iomem base for firmware control registers Karunika Choo
2026-04-10 18:12   ` Boris Brezillon
2026-04-10 16:46 ` [PATCH 8/8] drm/panthor: Use a local iomem base for MMU AS registers Karunika Choo
2026-04-10 18:13   ` Boris Brezillon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox