diff options
author | Daniel Vetter <daniel.vetter@ffwll.ch> | 2012-10-23 14:23:36 -0400 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2012-11-20 00:51:17 -0500 |
commit | 905bc9ff6575f78aab24c0261e8785425b5a0397 (patch) | |
tree | 633d4f1b534dc859139a614425f528d5a536077d /include/drm/drm_crtc.h | |
parent | 5e2cb2f6da72323877e5847512f8bd8d53c532f2 (diff) |
drm: don't start the poll engine in probe_single_connector
Actually there's a reason this stuff is there, and it's called
commit e58f637bb96d5a0ae0919b9998b891d1ba7e47c9
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date: Fri Aug 20 09:13:36 2010 +0100
drm/kms: Add a module parameter to disable polling
The idea has been that users can enable/disable polling at runtime. So
the quick hack has been to just re-enable the output polling if xrandr
asks for the latest state of the connectors.
The problem with that hack is that when we force connectors to another
state than what would be detected, we nicely ping-pong:
- Userspace calls probe, gets the forced state, but polling starts
again.
- Polling notices that the state is actually different, wakes up
userspace.
- Repeat.
As that commit already explains, the right fix would be to make the
locking more fine-grained, so that hotplug detection on one output
does not interfere with cursor updates on another crtc.
But that is way too much work. So let's just safe this gross hack by
caching the last-seen state of drm_kms_helper_poll for that driver,
and only fire up the poll engine again if it changed from off to on.
v2: Fixup the edge detection of drm_kms_helper_poll.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=49907
Tested-by: Tvrtko Ursulin <tvrtko.ursulin@onelan.co.uk>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'include/drm/drm_crtc.h')
-rw-r--r-- | include/drm/drm_crtc.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/drm/drm_crtc.h b/include/drm/drm_crtc.h index 1f5f1d642a98..c0635b7f8696 100644 --- a/include/drm/drm_crtc.h +++ b/include/drm/drm_crtc.h | |||
@@ -792,6 +792,7 @@ struct drm_mode_config { | |||
792 | 792 | ||
793 | /* output poll support */ | 793 | /* output poll support */ |
794 | bool poll_enabled; | 794 | bool poll_enabled; |
795 | bool poll_running; | ||
795 | struct delayed_work output_poll_work; | 796 | struct delayed_work output_poll_work; |
796 | 797 | ||
797 | /* pointers to standard properties */ | 798 | /* pointers to standard properties */ |