diff options
author | Dave Airlie <airlied@airlied-rhel5.(none)> | 2010-04-21 11:05:45 +1000 |
---|---|---|
committer | Dave Airlie <airlied@airlied-rhel5.(none)> | 2010-04-21 11:05:45 +1000 |
commit | 11390cd554287b46c737a1dabbe085392fec4da8 (patch) | |
tree | 6340b66d45e26ab9d419d6c3c3cb2ad1b76e67a1 | |
parent | 5550bddb33b0b1d01c2b4d61287c74da3fb971b6 (diff) |
intel-1.5-misc.patch
-rw-r--r-- | src/i830_crt.c | 12 | ||||
-rw-r--r-- | src/i830_display.c | 9 | ||||
-rw-r--r-- | src/i830_driver.c | 2 |
3 files changed, 10 insertions, 13 deletions
diff --git a/src/i830_crt.c b/src/i830_crt.c index 82a774aa..4c192271 100644 --- a/src/i830_crt.c +++ b/src/i830_crt.c @@ -353,11 +353,9 @@ i830_crt_detect(xf86OutputPtr output) Bool connected; crtc = i830GetLoadDetectPipe (output, NULL, &dpms_mode); - if (!crtc) - return XF86OutputStatusUnknown; - if (IS_I945G(pI830) || IS_I945GM(pI830) || IS_I965G(pI830) || - IS_G33CLASS(pI830)) { + if (crtc && (IS_I945G(pI830) || IS_I945GM(pI830) || IS_I965G(pI830) || + IS_G33CLASS(pI830))) { if (i830_crt_detect_hotplug(output)) status = XF86OutputStatusConnected; else @@ -371,6 +369,9 @@ i830_crt_detect(xf86OutputPtr output) goto out; } + if (!crtc) + return XF86OutputStatusUnknown; + /* Use the load-detect method if we have no other way of telling. */ connected = i830_crt_detect_load (crtc, output); if (connected) @@ -379,7 +380,8 @@ i830_crt_detect(xf86OutputPtr output) status = XF86OutputStatusDisconnected; out: - i830ReleaseLoadDetectPipe (output, dpms_mode); + if (crtc) + i830ReleaseLoadDetectPipe (output, dpms_mode); return status; } diff --git a/src/i830_display.c b/src/i830_display.c index 8f984295..8959ecfe 100644 --- a/src/i830_display.c +++ b/src/i830_display.c @@ -1501,7 +1501,6 @@ i830GetLoadDetectPipe(xf86OutputPtr output, DisplayModePtr mode, int *dpms_mode) xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(pScrn); I830OutputPrivatePtr intel_output = output->driver_private; I830CrtcPrivatePtr intel_crtc; - xf86CrtcPtr supported_crtc =NULL; xf86CrtcPtr crtc = NULL; int i; @@ -1532,15 +1531,9 @@ i830GetLoadDetectPipe(xf86OutputPtr output, DisplayModePtr mode, int *dpms_mode) crtc = possible_crtc; break; } - if (!supported_crtc) - supported_crtc = possible_crtc; } if (!crtc) - { - crtc = supported_crtc; - if (!crtc) - return NULL; - } + return NULL; output->crtc = crtc; intel_output->load_detect_temp = TRUE; diff --git a/src/i830_driver.c b/src/i830_driver.c index 0a688480..d51d02fd 100644 --- a/src/i830_driver.c +++ b/src/i830_driver.c @@ -3414,6 +3414,8 @@ I830PMEvent(int scrnIndex, pmEvent event, Bool undo) ErrorF("I830PMEvent: Capability change\n"); xf86InitialConfiguration(pScrn, 0); xf86SetDesiredModes(pScrn); + xf86RandR12SetCurrentMode(pScrn->pScreen, pScrn->currentMode); + i830DescribeOutputConfiguration(pScrn); SaveScreens(SCREEN_SAVER_FORCER, ScreenSaverReset); break; default: |