diff options
| author | Daniel Vetter <[email protected]> | 2020-03-23 15:49:07 +0100 |
|---|---|---|
| committer | Daniel Vetter <[email protected]> | 2020-03-26 15:17:43 +0100 |
| commit | 7fb81e9d80738ee2673990f6be1e55494d5ea014 (patch) | |
| tree | b634f135ce75cf81d462326b44689452380a6650 /tools/perf/scripts/python/bin/stackcollapse-report | |
| parent | c1b164a5f7ab932699923f58c95767bfc6921d91 (diff) | |
drm/i915: Use drmm_add_final_kfree
With this we can drop the final kfree from the release function.
The mock device in the selftests needed it's pci_device split
up from the drm_device. In the future we could simplify this again
by allocating the pci_device as a managed allocation too.
v2: I overlooked that i915_driver_destroy is also called in the
unwind code of the error path. There we need a drm_dev_put.
Similar for the mock object.
Now the problem with that is that the drm_driver->release callbacks
for both the real driver and the mock one assume everything has been
set up. Hence going through that path for a partially set up driver
will result in issues. Quickest fix is to disable the ->release() hook
until the driver is fully initialized, and keep the onion unwinding.
Long term would be cleanest to move everything over to drmm_ release
actions, but that's a lot of work for a big driver like i915. Plus
more core work needed first anyway.
v3: Fix i915_drm pointer wrangling in mock_gem_device. Also switch
over to start using drm_dev_put() to clean up even on the error path.
Aside I think the current error path is leaking the allocation.
v4: more fixes for intel-gfx-ci, some if it damage from v3 :-/
Reviewed-by: Jani Nikula <[email protected]>
Signed-off-by: Daniel Vetter <[email protected]>
Cc: Jani Nikula <[email protected]>
Cc: Joonas Lahtinen <[email protected]>
Cc: Rodrigo Vivi <[email protected]>
Cc: Chris Wilson <[email protected]>
Cc: Tvrtko Ursulin <[email protected]>
Cc: Matthew Auld <[email protected]>
Cc: Andi Shyti <[email protected]>
Cc: Mika Kuoppala <[email protected]>
Cc: Daniele Ceraolo Spurio <[email protected]>
Cc: Daniel Vetter <[email protected]>
Cc: Abdiel Janulgue <[email protected]>
Cc: [email protected]
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
Diffstat (limited to 'tools/perf/scripts/python/bin/stackcollapse-report')
0 files changed, 0 insertions, 0 deletions