]> git.baikalelectronics.ru Git - kernel.git/commit
drm/plane: Make framebuffer refcounting the responsibility of setplane_internal callers
authorMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
Wed, 20 Dec 2017 09:35:43 +0000 (10:35 +0100)
committerMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
Wed, 20 Dec 2017 13:49:06 +0000 (14:49 +0100)
commit3f70f82ea32414c3addd5c588794c0f4fc6b0e22
treeb1ae3ef6f6f9f4822d0d742b1a4f53cf32f54fea
parentbf5d3d667aae2f0e6f07c618559beeefdabb0a4f
drm/plane: Make framebuffer refcounting the responsibility of setplane_internal callers

lock_all_ctx in setplane_internal may return -EINTR, and
__setplane_internal could return -EDEADLK. Making more
special cases for fb would make the code even harder to
read, so the easiest solution is not taking over the fb
refcount, and making callers responsible for dropping
the ref.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=102707
Fixes: 9777ac4fca6f ("drm/legacy: Convert setplane ioctl locking to interruptible.")
Testcase: kms_atomic_interruptible
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20171220093545.613-2-maarten.lankhorst@linux.intel.com
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/drm_plane.c