Skip to content

drm: Move struct drm_device.pdev to legacy

Thomas Zimmermann dri-devel intel-gfx 8 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v8 Latest5 patches 4 repliesIn review
  2. v74 patches 3 repliesSuperseded
  3. v65 patches 1 replySuperseded
Earlier versions · 5
VersionPostedPatchesRepliesStatus
v55 patches3 repliesSuperseded
v46 patches5 repliesSuperseded
v38 patches8 repliesSuperseded
v220 patches18 repliesSuperseded
v115 patches17 repliesSuperseded

Changes in v8 from the cover letter

* fix pdev bitrot in ast
* fix commit messages (Michael)

Patches in v8 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5drm/ast: Remove reference to struct drm_device.pdevdrivers/gpu/drm/ast/ast_main.c+0 -12 replies
2/5drm/i915/gt: Remove reference to struct drm_device.pdevdrivers/gpu/drm/i915/gt/intel_region_lmem.c+1 -11 reply
3/5drm/i915: Remove reference to struct drm_device.pdevdrivers/gpu/drm/i915/intel_runtime_pm.h+1 -11 reply
4/5drm/i915: Don't assign to struct drm_device.pdevdrivers/gpu/drm/i915/i915_drv.c drivers/gpu/drm/i915/selftests/mock_gem_device.c+0 -20 replies
5/5drm: Move struct drm_device.pdev to legacy sectioninclude/drm/drm_device.h+3 -30 replies

Reviews trailers per patch

All 5 patches have a Reviewed-by or Acked-by.

PatchChris WilsonSam RavnborgMichael J. Ruhl
1/5R-b
2/5R-b
3/5R-b
4/5R-b
5/5R-b A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 3 reviewers.

Read the v8 thread

Cover letter [PATCH v8 0/5] drm: Move struct drm_device.pdev to legacy

V8 of the patchset fixes more bitrot and some commit messages.

The pdev field in struct drm_device points to a PCI device structure and goes back to UMS-only days when all DRM drivers were for PCI devices. Meanwhile we also support USB, SPI and platform devices. Each of those uses the generic device stored in struct drm_device.dev.

To reduce duplication and remove the special case of PCI, this patchset converts all modesetting drivers from pdev to dev and makes pdev a field for legacy UMS drivers.

For PCI devices, the pointer in struct drm_device.dev can be upcasted to struct pci_device; or tested for PCI with dev_is_pci(). In several places the code can use the dev field directly.

After converting all drivers and the DRM core, the pdev fields becomes only relevant for legacy drivers. In a later patchset, we may want to convert these as well and remove pdev entirely.

v8:
* fix pdev bitrot in ast
* fix commit messages (Michael)
v7:
* fix instances of pdev that have benn added under i915/
v6:
* also remove assignment in i915/selftests in later patch (Chris)
v5:
* remove assignment in later patch (Chris)
v4:
* merged several patches
* moved core changes into separate patch
* vmwgfx build fix
v3:
* merged several patches
* fix one pdev reference in nouveau (Jeremy)
* rebases
v2:
* move whitespace fixes into separate patches (Alex, Sam)
* move i915 gt/ and gvt/ changes into separate patches (Joonas)

Thomas Zimmermann (5):
drm/ast: Remove reference to struct drm_device.pdev drm/i915/gt: Remove reference to struct drm_device.pdev drm/i915: Remove reference to struct drm_device.pdev drm/i915: Don't assign to struct drm_device.pdev
drm: Move struct drm_device.pdev to legacy section

 drivers/gpu/drm/ast/ast_main.c                   | 1 -
 drivers/gpu/drm/i915/gt/intel_region_lmem.c      | 2 +-
 drivers/gpu/drm/i915/i915_drv.c                  | 1 -
 drivers/gpu/drm/i915/intel_runtime_pm.h          | 2 +-
 drivers/gpu/drm/i915/selftests/mock_gem_device.c | 1 -
 include/drm/drm_device.h                         | 6 +++---
 6 files changed, 5 insertions(+), 8 deletions(-)

base-commit: bf25e1addaf44137e20ce95de72ff118b37d808c
prerequisite-patch-id: c2b2f08f0eccc9f5df0c0da49fa1d36267deb11d
prerequisite-patch-id: c67e5d886a47b7d0266d81100837557fda34cb24
prerequisite-patch-id: c59ca2ddb182af06006fa360ad3e90fe16b93d3a --
2.31.1

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx