[PATCH v3 5/9] drm/amdgpu: Add mmio_remap bookkeeping to amdgpu_device

Alex Deucher alexdeucher at gmail.com
Thu Aug 28 15:22:06 UTC 2025


On Thu, Aug 28, 2025 at 5:21 AM Srinivasan Shanmugam
<srinivasan.shanmugam at amd.com> wrote:
>
> Add bookkeeping for the remap page to struct amdgpu_device:
>
> * bo:   kernel-owned singleton BO
>
> v2:
> - Use existing amdgpu_mmio_remap container; remove per-field members
>   (Alex).
> - Use AMD_GPU_PAGE_SIZE (always 4K) per Christian/Alex.
>
> Suggested-by: Alex Deucher <alexander.deucher at amd.com>
> Suggested-by: Christian König <christian.koenig at amd.com>
> Signed-off-by: Srinivasan Shanmugam <srinivasan.shanmugam at amd.com>

Reviewed-by: Alex Deucher <alexander.deucher at amd.com>


> ---
>  drivers/gpu/drm/amd/amdgpu/amdgpu.h | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu.h b/drivers/gpu/drm/amd/amdgpu/amdgpu.h
> index ddd472e56f69..24501d3fbefe 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu.h
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu.h
> @@ -752,6 +752,7 @@ typedef void (*amdgpu_block_wreg_t)(struct amdgpu_device*, uint32_t, uint32_t, u
>  struct amdgpu_mmio_remap {
>         u32 reg_offset;
>         resource_size_t bus_addr;
> +       struct amdgpu_bo *bo;
>  };
>
>  /* Define the HW IP blocks will be used in driver , add more if necessary */
> --
> 2.34.1
>


More information about the amd-gfx mailing list