]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915: Move the engine->destroy() vfunc onto the engine
authorChris Wilson <chris@chris-wilson.co.uk>
Wed, 1 May 2019 10:32:04 +0000 (11:32 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Wed, 1 May 2019 11:13:57 +0000 (12:13 +0100)
commit45b9c968c5b8a954576038d3cddf9771ebda0a8f
treecf3f4e81db3e3dc91d8786f59ed373ee2ef5d7ac
parent09b25812db10fcbd7937c1b7ca279c5c0d77ba9d
drm/i915: Move the engine->destroy() vfunc onto the engine

Make the engine responsible for cleaning itself up!

This removes the i915->gt.cleanup vfunc that has been annoying the
casual reader and myself for the last several years, and helps keep a
future patch to add more cleanup tidy.

v2: Assert that engine->destroy is set after the backend starts
allocating its own state.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190501103204.18632-1-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/gt/intel_engine.h
drivers/gpu/drm/i915/gt/intel_engine_cs.c
drivers/gpu/drm/i915/gt/intel_engine_types.h
drivers/gpu/drm/i915/gt/intel_lrc.c
drivers/gpu/drm/i915/gt/intel_ringbuffer.c
drivers/gpu/drm/i915/i915_drv.h
drivers/gpu/drm/i915/i915_gem.c