drm/radeon/kms: don't enable connectors that are off in the hotplug handler
authorAlex Deucher <alexander.deucher@amd.com>
Tue, 9 Aug 2011 17:09:06 +0000 (17:09 +0000)
committerDave Airlie <airlied@redhat.com>
Fri, 12 Aug 2011 09:47:25 +0000 (10:47 +0100)
If we get a hotplug event on an connector that is off, don't
attempt to turn it on or off, it should already be off.

Fixes:
https://bugzilla.redhat.com/show_bug.cgi?id=728228

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@kernel.org
Signed-off-by: Dave Airlie <airlied@redhat.com>
drivers/gpu/drm/radeon/radeon_connectors.c

index 6d6b5f16bc09461af70ea4eefcd1046999b113aa..519b5e2f1ee8ec2af9c0a314702c89af2bb54c82 100644 (file)
@@ -60,6 +60,10 @@ void radeon_connector_hotplug(struct drm_connector *connector)
 
        radeon_hpd_set_polarity(rdev, radeon_connector->hpd.hpd);
 
+       /* if the connector is already off, don't turn it back on */
+       if (connector->dpms != DRM_MODE_DPMS_ON)
+               return;
+
        /* powering up/down the eDP panel generates hpd events which
         * can interfere with modesetting.
         */