Skip to content

drm: Restrict GEM's pin/unpin to PRIME

Thomas Zimmermann dri-devel 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest4 patches 1 replyIn review
  2. v14 patches 6 repliesSuperseded

Changes in v2 from the cover letter

- fix coding style and comments (Dmitry)

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4drm/client: Do not pin in drm_client_buffer_vmap()drivers/gpu/drm/drm_client.c+6 -291 reply
2/4drm/gem-vram: Do not set pin and unpin callbacksdrivers/gpu/drm/drm_gem_vram_helper.c+0 -370 replies
3/4drm/gem-vram: Un-export pin helpersdrivers/gpu/drm/drm_gem_vram_helper.c include/drm/drm_gem_vram_helper.h+2 -420 replies
4/4drm/gem: Inline drm_gem_pin() into PRIME helpersdrivers/gpu/drm/drm_gem.c drivers/gpu/drm/drm_internal.h drivers/gpu/drm/drm_prime.c +1 more+22 -390 replies

Reviews trailers per patch

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

PatchBoris BrezillonDmitry Osipenko
1/4R-b R-b
2/4R-b
3/4R-b
4/4R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH v2 0/4] drm: Restrict GEM's pin/unpin to PRIME

The pin and unpin callbacks in struct drm_gem_object_funcs are for PRIME exported dma-bufs. Remove the pin calls in the client code, drop the unnecessary pin callbacks from gem-vram and inline drm_gem_pin() into the only remaining caller. Do the equivalent for drm_gem_unpin().

AFAICT the long-term plan is to switch to dynamic dma-buf imports and remove pin/unpin from GEM object functions.

v2:
- fix coding style and comments (Dmitry)

Thomas Zimmermann (4):
drm/client: Do not pin in drm_client_buffer_vmap() drm/gem-vram: Do not set pin and unpin callbacks drm/gem-vram: Un-export pin helpers drm/gem: Inline drm_gem_pin() into PRIME helpers

 drivers/gpu/drm/drm_client.c          | 35 ++----------
 drivers/gpu/drm/drm_gem.c             | 32 -----------
 drivers/gpu/drm/drm_gem_vram_helper.c | 79 +--------------------------
 drivers/gpu/drm/drm_internal.h        |  4 --
 drivers/gpu/drm/drm_prime.c           | 22 +++++++-
 include/drm/drm_gem.h                 |  3 +-
 include/drm/drm_gem_vram_helper.h     |  2 -
 7 files changed, 30 insertions(+), 147 deletions(-)

base-commit: 842c3c276c106040f9b96d72b9df35ed6aed9ae9

Signature · 1 line
2.49.0