All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 0/8] refactor monolithic amdgpu.h
@ 2026-06-22 19:57 Shahyan Soltani
  2026-06-22 19:57 ` [PATCH v3 1/8] drm/amdgpu: move struct amdgpu_wb and helpers into separate files Shahyan Soltani
                   ` (7 more replies)
  0 siblings, 8 replies; 17+ messages in thread
From: Shahyan Soltani @ 2026-06-22 19:57 UTC (permalink / raw)
  To: amd-gfx; +Cc: alexander.deucher, christian.koenig

This patch series refactors amdgpu.h by moving several structures and their
associated helpers into dedicated or existing header files. This improves
code organization and makes the structure easier to parse.

v3:
 - Dropped patch "Move struct amdgpu_sa_manager out of the monolithic header
   amdgpu.h into its own dedicated header amdgpu_sa.h" addressing v2's feedback
 - Removed the "_device_" part for amdgpu_wb functions addressing v2's feedback
 - Patches 2 and 7 are unchanged but can be dropped if amdgpu_uid is not
   desired to be removed from amdgpu.h
 - Removed amdgpu_mqd.h and moved the relevant structs and helpers into
   amdgpu_mes.h addressing v2's feedback
 - Dropped patch "Move struct amdgpu_init_level and helpers from the monolithic amdgpu.h
   file into a new amdgpu_init_level.h file." addressing v2's feedback
 - Dropped patch "Remove #include "amdgpu_init_level.h" from amdgpu.h and add forward
   declaration of struct amdgpu_init_level."

v2:
 - Moved amdgpu_device_wb_get()/free() into new amdgpu_wb.c file and
   amdgpu_device_set_uid()/get_uid() into new amdgpu_uid.c file
   (addressing v1 review feedback)
 - Removed v1 patches 8, 10, and 11 (addressing v1 review feedback)
 - Moved the includes of headers amdgpu_uid.h, amdgpu_init_level.h
   and amdgpu_video_codecs.h out of amdgpu.h into files where they are
   actually used (addressing v1 review feedback)

Notes from v2:
- Moving the includes out of amdgpu.h into where they are actually used
  caused the commits to go into different subsystems like /pm.
- Dropping patches 9, 10, and 11 is advised if this isn't desirable.

Shahyan Soltani (8):
  drm/amdgpu: move struct amdgpu_wb and helpers into separate files
  drm/amdgpu: move struct amdgpu_uid and helpers into separate files
  drm/amdgpu: move struct amdgpu_video_codecs and helpers into header
    file
  drm/amdgpu: move struct amdgpu_mqd and helpers into header file
  drm/amdgpu: move amdgpu_acpi helpers into new header
  drm/amdgpu: move amdgpu_allowed_register_entry into
    amdgpu_reg_access.h
  drm/amdgpu: include amdgpu_uid.h only where needed
  drm/amdgpu: include amdgpu_video_codecs.h only where needed

 drivers/gpu/drm/amd/amdgpu/Makefile           |   3 +-
 drivers/gpu/drm/amd/amdgpu/amdgpu.h           | 289 +-----------------
 drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.h      | 151 +++++++++
 drivers/gpu/drm/amd/amdgpu/amdgpu_device.c    |  96 +-----
 drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c       |   6 +-
 drivers/gpu/drm/amd/amdgpu/amdgpu_ih.c        |  14 +-
 drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c       |   1 +
 drivers/gpu/drm/amd/amdgpu/amdgpu_mes.c       |  16 +-
 drivers/gpu/drm/amd/amdgpu/amdgpu_mes.h       |  46 +++
 .../gpu/drm/amd/amdgpu/amdgpu_reg_access.h    |   8 +
 drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c      |  18 +-
 drivers/gpu/drm/amd/amdgpu/amdgpu_uid.c       |  75 +++++
 drivers/gpu/drm/amd/amdgpu/amdgpu_uid.h       |  50 +++
 drivers/gpu/drm/amd/amdgpu/amdgpu_umsch_mm.c  |   6 +-
 .../gpu/drm/amd/amdgpu/amdgpu_video_codecs.h  |  47 +++
 drivers/gpu/drm/amd/amdgpu/amdgpu_virt.c      |   1 +
 drivers/gpu/drm/amd/amdgpu/amdgpu_vpe.c       |   8 +-
 drivers/gpu/drm/amd/amdgpu/amdgpu_wb.c        |  71 +++++
 drivers/gpu/drm/amd/amdgpu/amdgpu_wb.h        | 100 ++++++
 drivers/gpu/drm/amd/amdgpu/amdgpu_xcp.c       |   1 +
 drivers/gpu/drm/amd/amdgpu/cik.c              |   1 +
 drivers/gpu/drm/amd/amdgpu/cik_sdma.c         |   8 +-
 drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c        |   4 +-
 drivers/gpu/drm/amd/amdgpu/gfx_v11_0.c        |   4 +-
 drivers/gpu/drm/amd/amdgpu/gfx_v12_0.c        |   4 +-
 drivers/gpu/drm/amd/amdgpu/gfx_v12_1.c        |   4 +-
 drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c         |   4 +-
 drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c         |  10 +-
 drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c       |   4 +-
 drivers/gpu/drm/amd/amdgpu/mes_userqueue.c    |   4 +-
 drivers/gpu/drm/amd/amdgpu/mes_v11_0.c        |   6 +-
 drivers/gpu/drm/amd/amdgpu/mes_v12_0.c        |   6 +-
 drivers/gpu/drm/amd/amdgpu/mes_v12_1.c        |   6 +-
 drivers/gpu/drm/amd/amdgpu/nv.c               |   1 +
 drivers/gpu/drm/amd/amdgpu/sdma_v2_4.c        |   8 +-
 drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c        |   8 +-
 drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c        |   8 +-
 drivers/gpu/drm/amd/amdgpu/sdma_v4_4_2.c      |   8 +-
 drivers/gpu/drm/amd/amdgpu/sdma_v5_0.c        |  10 +-
 drivers/gpu/drm/amd/amdgpu/sdma_v5_2.c        |  10 +-
 drivers/gpu/drm/amd/amdgpu/sdma_v6_0.c        |  10 +-
 drivers/gpu/drm/amd/amdgpu/sdma_v7_0.c        |  10 +-
 drivers/gpu/drm/amd/amdgpu/sdma_v7_1.c        |  10 +-
 drivers/gpu/drm/amd/amdgpu/si.c               |   1 +
 drivers/gpu/drm/amd/amdgpu/si_dma.c           |   8 +-
 drivers/gpu/drm/amd/amdgpu/soc15.c            |   1 +
 drivers/gpu/drm/amd/amdgpu/soc21.c            |   1 +
 drivers/gpu/drm/amd/amdgpu/soc24.c            |   1 +
 drivers/gpu/drm/amd/amdgpu/soc_v1_0.c         |   1 +
 drivers/gpu/drm/amd/amdgpu/vi.c               |   1 +
 .../drm/amd/pm/swsmu/smu13/smu_v13_0_12_ppt.c |   1 +
 .../drm/amd/pm/swsmu/smu13/smu_v13_0_6_ppt.c  |   1 +
 .../drm/amd/pm/swsmu/smu15/smu_v15_0_8_ppt.c  |   1 +
 53 files changed, 679 insertions(+), 491 deletions(-)
 create mode 100644 drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.h
 create mode 100644 drivers/gpu/drm/amd/amdgpu/amdgpu_uid.c
 create mode 100644 drivers/gpu/drm/amd/amdgpu/amdgpu_uid.h
 create mode 100644 drivers/gpu/drm/amd/amdgpu/amdgpu_video_codecs.h
 create mode 100644 drivers/gpu/drm/amd/amdgpu/amdgpu_wb.c
 create mode 100644 drivers/gpu/drm/amd/amdgpu/amdgpu_wb.h

-- 
2.54.0


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

end of thread, other threads:[~2026-06-24 17:33 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-06-22 19:57 [PATCH v3 0/8] refactor monolithic amdgpu.h Shahyan Soltani
2026-06-22 19:57 ` [PATCH v3 1/8] drm/amdgpu: move struct amdgpu_wb and helpers into separate files Shahyan Soltani
2026-06-23  8:52   ` Christian König
2026-06-22 19:57 ` [PATCH v3 2/8] drm/amdgpu: move struct amdgpu_uid " Shahyan Soltani
2026-06-23  8:55   ` Christian König
2026-06-24 15:04     ` Soltani, Shahyan
2026-06-24 15:24       ` Christian König
2026-06-22 19:57 ` [PATCH v3 3/8] drm/amdgpu: move struct amdgpu_video_codecs and helpers into header file Shahyan Soltani
2026-06-22 19:57 ` [PATCH v3 4/8] drm/amdgpu: move struct amdgpu_mqd " Shahyan Soltani
2026-06-23  9:04   ` Christian König
2026-06-24 12:59     ` Khatri, Sunil
2026-06-24 13:10       ` Khatri, Sunil
2026-06-24 17:33         ` Soltani, Shahyan
2026-06-22 19:57 ` [PATCH v3 5/8] drm/amdgpu: move amdgpu_acpi helpers into new header Shahyan Soltani
2026-06-22 19:57 ` [PATCH v3 6/8] drm/amdgpu: move amdgpu_allowed_register_entry into amdgpu_reg_access.h Shahyan Soltani
2026-06-22 19:57 ` [PATCH v3 7/8] drm/amdgpu: include amdgpu_uid.h only where needed Shahyan Soltani
2026-06-22 19:57 ` [PATCH v3 8/8] drm/amdgpu: include amdgpu_video_codecs.h " Shahyan Soltani

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.