xf86-video-intel: Branch '2.7' - 6 commits - man/intel.man src/i830_driver.c src/i830_sdvo.c src/i830_tv.c src/i830_video.c

Carl Worth cworth at kemper.freedesktop.org
Mon Mar 16 14:24:11 PDT 2009


 man/intel.man     |    2 +-
 src/i830_driver.c |    8 ++------
 src/i830_sdvo.c   |   12 ++++++++----
 src/i830_tv.c     |   15 ++++++---------
 src/i830_video.c  |    2 +-
 5 files changed, 18 insertions(+), 21 deletions(-)

New commits:
commit 238c2c40afd9f8b61479b8640d53f20d52fd7ddf
Author: Zhenyu Wang <zhenyu.z.wang at intel.com>
Date:   Mon Mar 16 10:19:39 2009 +0800

    TV: fix contrast and saturation for 945G
    
    Bug #20670.
    (cherry picked from commit 1a6e70cd98abc63f24f710819961c24601afb59b)

diff --git a/src/i830_tv.c b/src/i830_tv.c
index 42d9e90..8eb3e26 100644
--- a/src/i830_tv.c
+++ b/src/i830_tv.c
@@ -1079,7 +1079,7 @@ i830_tv_update_contrast(I830Ptr pI830, uint8_t contrast)
 	c = float_to_fix_2_6(con);
     } else {
 	/* 2.6 floating point */
-	con = 8.875 * ((float) contrast / 255);
+	con = 2.65625 * ((float) contrast / 255);
 	c = float_to_float_2_6(con);
     }
     val |= (c << TV_CONTRAST_SHIFT) & TV_CONTRAST_MASK;
@@ -1098,7 +1098,7 @@ i830_tv_update_saturation(I830Ptr pI830, uint8_t saturation)
 	sat = 3.0 * ((float) saturation / 255);
 	s = float_to_fix_2_6(sat);
     } else {
-	sat = 8.875 * ((float) saturation / 255);
+	sat = 2.65625 * ((float) saturation / 255);
 	s = float_to_float_2_6(sat);
     }
     val |= (s << TV_SATURATION_SHIFT) & TV_SATURATION_MASK;
commit 14e09995a74b296acda33bb6c833b432075cd873
Author: Zhenyu Wang <zhenyu.z.wang at intel.com>
Date:   Mon Mar 16 09:30:22 2009 +0800

    TV: force TV as connected with TV_Connector option
    
    In order to bypass failure in TV load detect, TV_Connector option
    will always force TV as connected with user specified connector type.
    (cherry picked from commit 4e95327323e3d081b565147f7738eb49c28542bc)

diff --git a/man/intel.man b/man/intel.man
index ee237f8..e6cb03e 100644
--- a/man/intel.man
+++ b/man/intel.man
@@ -322,7 +322,7 @@ This property allows you to control the output standard used on your TV output p
 .B TV_Connector
 - connector type
 .TP 2
-This config option should be added to xorg.conf TV monitor's section, it allows you to control the TV output connector type, which bypass load detect. You can select between S-Video, Composite and Component.
+This config option should be added to xorg.conf TV monitor's section, it allows you to force the TV output connector type, which bypass load detect and TV will always be taken as connected. You can select between S-Video, Composite and Component.
 
 .SS "TMDS-1"
 First DVI SDVO output
diff --git a/src/i830_tv.c b/src/i830_tv.c
index 1e3cf7b..42d9e90 100644
--- a/src/i830_tv.c
+++ b/src/i830_tv.c
@@ -1458,6 +1458,10 @@ i830_tv_detect(xf86OutputPtr output)
     int			    dpms_mode;
     int			    type = dev_priv->type;
 
+    /* If TV connector type set by user, always return connected */
+    if (dev_priv->force_type)
+	return XF86OutputStatusConnected;
+
     mode = reported_modes[0];
     xf86SetModeCrtc (&mode, INTERLACE_HALVE_V);
     crtc = i830GetLoadDetectPipe (output, &mode, &dpms_mode);
@@ -1467,13 +1471,6 @@ i830_tv_detect(xf86OutputPtr output)
         i830ReleaseLoadDetectPipe (output, dpms_mode);
     }
 
-    if (dev_priv->force_type) {
-	if (type == TV_TYPE_NONE)
-	    return XF86OutputStatusDisconnected;
-	else
-	    return XF86OutputStatusConnected;
-    }
-
     if (type != dev_priv->type)
     {
 	dev_priv->type = type;
commit 72ab5ee2e1b459772641f3b6e347ef9389f24195
Author: Kalev Lember <kalev at smartlink.ee>
Date:   Fri Mar 13 21:32:08 2009 +0200

    Fix Xv crash with overlay video.
    
    Bug #20585.
    (cherry picked from commit 2026c57cf0a352d9e6f9d208cfb7d4d550614477)

diff --git a/src/i830_video.c b/src/i830_video.c
index daa2411..3c6fbf3 100644
--- a/src/i830_video.c
+++ b/src/i830_video.c
@@ -1382,7 +1382,7 @@ I830CopyPlanarData(ScrnInfoPtr pScrn, I830PortPrivPtr pPriv,
 	dst_base = pPriv->buf->virtual;
     } else {
 	drm_intel_gem_bo_start_gtt_access(pPriv->buf, TRUE);
-	dst_base = pI830->FbBase + pPriv->buf->offset;
+	dst_base = pI830->FbBase;
     }
 
     if (pPriv->currentBuf == 0)
commit d7e1543a618c54f1baeea7dd1ac54bb37e309fec
Author: Jesse Barnes <jbarnes at virtuousgeek.org>
Date:   Fri Mar 13 12:21:34 2009 -0700

    Use UXA when KMS is active
    
    EXA doesn't support KMS, so force UXA on if KMS is detected.  And warn
    the user if they've specified something other than UXA in their
    xorg.conf.
    
    Fixes bug #20620.
    (cherry picked from commit 3ef9d85371a97ea5baee0c47787b3bb3cdaf5135)

diff --git a/src/i830_driver.c b/src/i830_driver.c
index 6ec1a48..3ba5762 100644
--- a/src/i830_driver.c
+++ b/src/i830_driver.c
@@ -1707,12 +1707,8 @@ I830DrmModeInit(ScrnInfoPtr pScrn)
     pI830->accel = ACCEL_UXA;
 
     if ((s = (char *)xf86GetOptValString(pI830->Options, OPTION_ACCELMETHOD))) {
-	if (!xf86NameCmp(s, "EXA"))
-	    pI830->accel = ACCEL_EXA;
-	else if (!xf86NameCmp(s, "UXA"))
-	    pI830->accel = ACCEL_UXA;
-	else
-	    pI830->accel = ACCEL_UXA;
+	if (xf86NameCmp(s, "UXA"))
+	    xf86DrvMsg(pScrn->scrnIndex, X_WARNING, "kernel mode setting active,overridding accelmethod and using UXA\n");
     }
 
     pI830->can_resize = FALSE;
commit e87bcd19a608aa964d6ea43ca5a19aed2efc818d
Author: Zhenyu Wang <zhenyu.z.wang at intel.com>
Date:   Thu Mar 12 16:32:02 2009 +0800

    Revert "SDVO: Switch control bus only before DDC access"
    
    This reverts commit ddedf19f889da2ce6d69a3afce4665e2245682fa.
    
    After i2c STOP, control bus will return back to internal
    registers. So this brings back to origin code that we switch
    to DDC bus before START. But it's ideal to only issue DDC
    bus switch after STOP, not before every START, which might eliminate
    some complains from SDVO device, that will be another patch later.
    (cherry picked from commit dc3ff0b514b609448025680778f0e95e1980a5d8)

diff --git a/src/i830_sdvo.c b/src/i830_sdvo.c
index 004d5c4..254b866 100644
--- a/src/i830_sdvo.c
+++ b/src/i830_sdvo.c
@@ -1390,7 +1390,9 @@ i830_sdvo_ddc_i2c_start(I2CBusPtr b, int timeout)
     xf86OutputPtr	    output = b->DriverPrivate.ptr;
     I830OutputPrivatePtr    intel_output = output->driver_private;
     I2CBusPtr		    i2cbus = intel_output->pI2CBus;
+    struct i830_sdvo_priv   *dev_priv = intel_output->dev_priv;
 
+    i830_sdvo_set_control_bus_switch(output, dev_priv->ddc_bus);
     return i2cbus->I2CStart(i2cbus, timeout);
 }
 
@@ -1718,11 +1720,9 @@ i830_sdvo_get_ddc_modes(xf86OutputPtr output)
     xf86CrtcConfigPtr   xf86_config = XF86_CRTC_CONFIG_PTR(pScrn);
     DisplayModePtr modes = NULL;
     xf86OutputPtr crt;
-    I830OutputPrivatePtr intel_output = output->driver_private;
+    I830OutputPrivatePtr intel_output;
     xf86MonPtr edid_mon = NULL;
-    struct i830_sdvo_priv *dev_priv = intel_output->dev_priv;
-
-    i830_sdvo_set_control_bus_switch(output, dev_priv->ddc_bus);
+    struct i830_sdvo_priv *dev_priv;
 
     modes = i830_ddc_get_modes(output);
     if (modes != NULL)
commit 53b10efdb78c19d73689bff85f8d11863139b8b8
Author: Zhenyu Wang <zhenyu.z.wang at intel.com>
Date:   Thu Mar 12 16:31:01 2009 +0800

    SDVO: reset privates before output setup
    
    For multifunction encoder, forget to reset these values
    will cause wrong output type in later mode setting
    operations.
    (cherry picked from commit c6b0135d209bdad3dbc641d0e264596eaf6f99d3)

diff --git a/src/i830_sdvo.c b/src/i830_sdvo.c
index baba007..004d5c4 100644
--- a/src/i830_sdvo.c
+++ b/src/i830_sdvo.c
@@ -1544,6 +1544,10 @@ i830_sdvo_output_setup (xf86OutputPtr output, uint16_t flag)
     else
 	name_suffix = "-2";
 
+    /* clear up privates */
+    dev_priv->is_tv = FALSE;
+    intel_output->needs_tv_clock = FALSE;
+
     if (flag & (SDVO_OUTPUT_TMDS0 | SDVO_OUTPUT_TMDS1))
     {
 	if (flag & SDVO_OUTPUT_TMDS0)


More information about the xorg-commit mailing list