[PATCH v4 0/6] drm/managed: Add drmm_release_action

Michał Winiarski michal.winiarski at intel.com
Fri Jan 5 10:13:18 UTC 2024


Upcoming Intel Xe driver will need to have a more fine-grained control
over DRM managed actions - namely, the ability to release a given
action, triggering it manually at a different point in time than the
final drm_dev_put().
This series adds a drmm_release_action function (which is similar to
devres devm_release_action) and a simple test that uses it.

v1 -> v2:
- Split the test changes (Maxime)
- Simplify priv lifetime management (Maxime)

v2 -> v3:
- Order tests alphabetically (Maxime)
- Add comments explaining the intention behind the tests and the reason
  why DRM device can't be embedded inside test priv (Maxime)
- Bring back priv lifetime management from v1 to avoid use-after-free

v3 -> v4:
- Split test changes into smaller patches (Maxime)
- Remove the waitqueue usage in tests
- Rename the test suite to match other DRM tests

Michał Winiarski (6):
  drm/managed: Add drmm_release_action
  drm/tests: managed: Rename the suite name to match other DRM tests
  drm/tests: managed: Remove the waitqueue usage
  drm/tests: managed: Add comments and expect fail messages
  drm/tests: managed: Extract device initialization into test init
  drm/tests: managed: Add a simple test for drmm_managed_release

 drivers/gpu/drm/drm_managed.c            | 39 +++++++++++
 drivers/gpu/drm/tests/drm_managed_test.c | 84 +++++++++++++++++-------
 include/drm/drm_managed.h                |  4 ++
 3 files changed, 105 insertions(+), 22 deletions(-)

-- 
2.43.0



More information about the Intel-xe mailing list