[Intel-gfx] [PATCH 02/14] drm: Hide hw.lock cleanup in filp->release better

Chris Wilson chris at chris-wilson.co.uk
Wed Jun 15 11:26:21 UTC 2016


On Tue, Jun 14, 2016 at 08:50:57PM +0200, Daniel Vetter wrote:
> A few things:
> - Rename the cleanup function from drm_master_release to
>   drm_legacy_lock_release. It doesn't relase any master stuff, but
>   just the legacy hw lock.
> - Hide it in drm_lock.c, which allows us to make a few more functions
>   static in there. To avoid forward decl we need to shuffle the code a
>   bit though.
> - Push the check for ->master into the function itself.
> - Only call this for !DRIVER_MODESET.
> 
> End result: Another place that takes struct_mutex gone for good for
> modern drivers.
> 
> v2: Remove leftover comment.
> 
> Signed-off-by: Daniel Vetter <daniel.vetter at intel.com>
Reviewed-by: Chris Wilson <chris at chris-wilson.co.uk>
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre


More information about the Intel-gfx mailing list