]> git.baikalelectronics.ru Git - kernel.git/commit
drm: Fix getconnector connection_mutex locking
authorDaniel Vetter <daniel.vetter@ffwll.ch>
Thu, 5 Jun 2014 09:07:20 +0000 (11:07 +0200)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Thu, 5 Jun 2014 14:10:20 +0000 (16:10 +0200)
commita915aaa15616e957253766bf53a82ea6a1d53295
tree295a58a2583fa37acea0d56f9ae0cbd15e44754d
parent8d88f094a7b53ceb84e5e3d139aa12ef0069630e
drm: Fix getconnector connection_mutex locking

I've fumbled my own idea and enthusiastically wrapped all the
getconnector code with the connection_mutex. But we only need it to
chase the connector->encoder link. Even there it's not really needed
since races with userspace won't matter, but better paranoid and
consistent about this stuff.

If we grap it everywhere connector probe callbacks can't grab it
themselves, which means they'll deadlock. i915 does that for the load
detect pipe. Furthermore i915 needs to do a ww dance since we also
need to grab the mutex of the load detect crtc.

This is a regression from

commit d9e3d5709c9db926007485d575b4c21cfc4da9ea
Author: Daniel Vetter <daniel.vetter@ffwll.ch>
Date:   Thu May 29 23:54:47 2014 +0200

    drm: Split connection_mutex out of mode_config.mutex (v3)

Cc: Rob Clark <robdclark@gmail.com>
Cc: Dave Airlie <airlied@redhat.com>
Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reported-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Rob Clark <robdclark@gmail.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/drm_crtc.c