]> git.karo-electronics.de Git - mv-sheeva.git/commit
drm: Don't switch fb when disabling an output
authorChris Wilson <chris@chris-wilson.co.uk>
Fri, 28 Jan 2011 11:53:03 +0000 (11:53 +0000)
committerChris Wilson <chris@chris-wilson.co.uk>
Mon, 31 Jan 2011 12:35:51 +0000 (12:35 +0000)
commit9334ef755f060e251f3f395caeda1a58b6834ea3
tree8032fbc2dbfd7675b6dd96275fbadb214ba5faa4
parent5d1d0cc87fc0887921993ea0742932e0c8adeda0
drm: Don't switch fb when disabling an output

In drm_crtc_helper_set_config, we call drm_crtc_helper_set_mode which
may return early and do no operation if the crtc is to be disabled. In
this case we merrily swap to the new fb, discarding the old_fb believing
that it has been cleaned up. However, due to the early return, the
old_fb was not presented to the backend for correct reaping, and nor was
the new one - which is about to be reaped via the
drm_helper_disable_unused_functions(), leading to incorrect refcounting
of the pinned objects.

Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=27722
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=29857
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=29230
Tested-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
drivers/gpu/drm/drm_crtc_helper.c