mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Steven Price <steven.price@arm.com>
To: Karunika Choo <karunika.choo@arm.com>, dri-devel@lists.freedesktop.org
Cc: nd@arm.com, Boris Brezillon <boris.brezillon@collabora.com>,
	Liviu Dudau <liviu.dudau@arm.com>,
	Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
	Maxime Ripard <mripard@kernel.org>,
	Thomas Zimmermann <tzimmermann@suse.de>,
	David Airlie <airlied@gmail.com>, Simona Vetter <simona@ffwll.ch>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 0/8] drm/panthor: Localize register access by component
Date: Wed, 22 Apr 2026 10:34:40 +0100	[thread overview]
Message-ID: <c429eca5-fe69-4058-9d42-3fb25de53043@arm.com> (raw)
In-Reply-To: <20260412142951.2309135-1-karunika.choo@arm.com>

On 12/04/2026 15:29, Karunika Choo wrote:
> 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.

Generally this all looks fine, one minor comment (see patch 4), but
otherwise the series is:

Reviewed-by: Steven Price <steven.price@arm.com>

Thanks,
Steve

> v2:
> - Picked up Acks from Boris.
> - Moved GPU_ID definitions into panthor_gpu_regs.h and deleted
>   panthor_hw_regs.h
> - Fixed incorrect spelling of timestamp helper functions.
> - Changed IRQ request function to take an iomem pointer instead of an
>   offset.
> - Update panthor_gpu_info_init() to use the correct block-local iomem
>   pointers for register accesses.
> - Link to v1: https://lore.kernel.org/all/20260410164637.549145-1-karunika.choo@arm.com/
> 
> Kind regards,
> Karunika
> 
> 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       |  40 ++-
>  drivers/gpu/drm/panthor/panthor_fw.h       |   1 +
>  drivers/gpu/drm/panthor/panthor_fw_regs.h  |  29 ++
>  drivers/gpu/drm/panthor/panthor_gpu.c      | 101 +++++--
>  drivers/gpu/drm/panthor/panthor_gpu.h      |   6 +
>  drivers/gpu/drm/panthor/panthor_gpu_regs.h | 119 +++++++++
>  drivers/gpu/drm/panthor/panthor_heap.c     |   2 +-
>  drivers/gpu/drm/panthor/panthor_hw.c       |  54 ++--
>  drivers/gpu/drm/panthor/panthor_hw.h       |   2 +-
>  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 +-
>  18 files changed, 584 insertions(+), 480 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_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
> 


      parent reply	other threads:[~2026-04-22 13:32 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-12 14:29 Karunika Choo
2026-04-12 14:29 ` [PATCH v2 1/8] drm/panthor: Pass an iomem pointer to GPU register access helpers Karunika Choo
2026-04-15 11:46   ` Liviu Dudau
2026-04-12 14:29 ` [PATCH v2 2/8] drm/panthor: Split register definitions by components Karunika Choo
2026-04-13  7:43   ` Boris Brezillon
2026-04-15 11:47   ` Liviu Dudau
2026-04-12 14:29 ` [PATCH v2 3/8] drm/panthor: Replace cross-component register accesses with helpers Karunika Choo
2026-04-13  7:44   ` Boris Brezillon
2026-04-15 11:48   ` Liviu Dudau
2026-04-12 14:29 ` [PATCH v2 4/8] drm/panthor: Store IRQ register base iomem pointer in panthor_irq Karunika Choo
2026-04-13  7:46   ` Boris Brezillon
2026-04-15 12:16   ` Liviu Dudau
2026-04-22  9:34   ` Steven Price
2026-04-22 16:08     ` Karunika Choo
2026-04-24 10:38       ` Steven Price
2026-04-24 11:03         ` Boris Brezillon
2026-04-24 11:20           ` Steven Price
2026-04-24 12:09             ` Boris Brezillon
2026-04-27 16:08               ` Karunika Choo
2026-04-12 14:29 ` [PATCH v2 5/8] drm/panthor: Use a local iomem base for GPU registers Karunika Choo
2026-04-15 12:19   ` Liviu Dudau
2026-04-12 14:29 ` [PATCH v2 6/8] drm/panthor: Use a local iomem base for PWR registers Karunika Choo
2026-04-13  7:51   ` Boris Brezillon
2026-04-15 12:21   ` Liviu Dudau
2026-04-12 14:29 ` [PATCH v2 7/8] drm/panthor: Use a local iomem base for firmware control registers Karunika Choo
2026-04-15 12:22   ` Liviu Dudau
2026-04-12 14:29 ` [PATCH v2 8/8] drm/panthor: Use a local iomem base for MMU AS registers Karunika Choo
2026-04-15 12:23   ` Liviu Dudau
2026-04-22  9:34 ` Steven Price [this message]

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=c429eca5-fe69-4058-9d42-3fb25de53043@arm.com \
    --to=steven.price@arm.com \
    --cc=airlied@gmail.com \
    --cc=boris.brezillon@collabora.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=karunika.choo@arm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=liviu.dudau@arm.com \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=mripard@kernel.org \
    --cc=nd@arm.com \
    --cc=simona@ffwll.ch \
    --cc=tzimmermann@suse.de \
    /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

all inboxes | Powered by JetHome®