[Openchrome-devel] xf86-video-openchrome: 4 commits - configure.ac src/via_vt1632.c src/via_vt1632.h

Kevin Brace kevinbrace at kemper.freedesktop.org
Sat Aug 6 17:20:40 UTC 2016


 configure.ac     |    2 -
 src/via_vt1632.c |   87 +++++++++++++++++++++++++++----------------------------
 src/via_vt1632.h |    1 
 3 files changed, 44 insertions(+), 46 deletions(-)

New commits:
commit accaf53a39c0612a5ed8ff4aadd7ed4c37ec292a
Author: Kevin Brace <kevinbrace at gmx.com>
Date:   Sat Aug 6 10:19:59 2016 -0700

    Version bumped to 0.5.118
    
    Signed-off-by: Kevin Brace <kevinbrace at gmx.com>

diff --git a/configure.ac b/configure.ac
index 523a9c2..1140394 100644
--- a/configure.ac
+++ b/configure.ac
@@ -23,7 +23,7 @@
 # Initialize Autoconf
 AC_PREREQ(2.57)
 AC_INIT([xf86-video-openchrome],
-        [0.5.117],
+        [0.5.118],
         [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg&component=Driver/openchrome],
         [xf86-video-openchrome])
 
commit 39b7d9fcba8f4d071872853f0efa4935a233e0df
Author: Kevin Brace <kevinbrace at gmx.com>
Date:   Sat Aug 6 01:56:04 2016 -0700

    Moving via_vt1632_mode_set functionality into viaVT1632InitRegister
    
    Signed-off-by: Kevin Brace <kevinbrace at gmx.com>

diff --git a/src/via_vt1632.c b/src/via_vt1632.c
index 2441bec..ba10de2 100644
--- a/src/via_vt1632.c
+++ b/src/via_vt1632.c
@@ -85,6 +85,42 @@ via_vt1632_power(xf86OutputPtr output, Bool powerState)
                         "Exiting via_vt1632_power.\n"));
 }
 
+static void
+viaVT1632InitRegisters(ScrnInfoPtr pScrn, I2CDevPtr pDev)
+{
+    DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO,
+                        "Entered viaVT1632InitRegisters.\n"));
+
+    /* For Wyse C00X VX855 chipset DVP1 (Digital Video Port 1), use
+     * 12-bit mode with dual edge transfer, along with rising edge
+     * data capture first mode. This is likely true for CX700, VX700,
+     * VX800, and VX900 chipsets as well. */
+    xf86I2CWriteByte(pDev, 0x08,
+                        VIA_VT1632_VEN | VIA_VT1632_HEN |
+                        VIA_VT1632_DSEL |
+                        VIA_VT1632_EDGE | VIA_VT1632_PDB);
+
+    /* Route receiver detect bit (Offset 0x09[2]) as the output of
+     * MSEN pin. */
+    xf86I2CWriteByte(pDev, 0x09, 0x20);
+
+    /* Turning on deskew feature caused screen display issues.
+     * This was observed with Wyse C00X. */
+    xf86I2CWriteByte(pDev, 0x0A, 0x00);
+
+    /* While VIA Technologies VT1632A datasheet insists on setting this
+     * register to 0x89 as the recommended setting, in practice, this
+     * leads to a blank screen on the display with Wyse C00X. According to
+     * Silicon Image SiI 164 datasheet (VT1632A is a pin and mostly
+     * register compatible chip), offset 0x0C is for PLL filter enable,
+     * PLL filter setting, and continuous SYNC enable bits. All of these are
+     * turned off for proper operation. */
+    xf86I2CWriteByte(pDev, 0x0C, 0x00);
+
+    DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO,
+                        "Exiting viaVT1632InitRegisters.\n"));
+}
+
 void
 via_vt1632_save(xf86OutputPtr output)
 {
@@ -157,44 +193,17 @@ void
 via_vt1632_mode_set(xf86OutputPtr output, DisplayModePtr mode,
                     DisplayModePtr adjusted_mode)
 {
-    ViaVT1632Ptr Private = output->driver_private;
     ScrnInfoPtr pScrn = output->scrn;
+    ViaVT1632Ptr pVIAVT1632Rec = output->driver_private;
 
     DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO, 
                         "Entered via_vt1632_mode_set.\n"));
 
-    xf86DrvMsg(pScrn->scrnIndex, X_INFO,
-                "VT1632A: Enabling DVI.\n");
-
-    via_vt1632_dump_registers(pScrn, Private->VT1632I2CDev);
-
-    /* For Wyse C00X VX855 chipset DVP1 (Digital Video Port 1), use
-     * 12-bit mode with dual edge transfer, along with rising edge
-     * data capture first mode. This is likely true for CX700, VX700,
-     * VX800, and VX900 chipsets as well. */
-    xf86I2CWriteByte(Private->VT1632I2CDev, 0x08,
-                        VIA_VT1632_VEN | VIA_VT1632_HEN |
-                        VIA_VT1632_DSEL |
-                        VIA_VT1632_EDGE | VIA_VT1632_PDB);
-
-    /* Route receiver detect bit (Offset 0x09[2]) as the output of
-     * MSEN pin. */
-    xf86I2CWriteByte(Private->VT1632I2CDev, 0x09, 0x20);
+    via_vt1632_dump_registers(pScrn, pVIAVT1632Rec->VT1632I2CDev);
 
-    /* Turning on deskew feature caused screen display issues.
-     * This was observed with Wyse C00X. */
-    xf86I2CWriteByte(Private->VT1632I2CDev, 0x0A, 0x00);
-
-    /* While VIA Technologies VT1632A datasheet insists on setting this
-     * register to 0x89 as the recommended setting, in practice, this
-     * leads to a blank screen on the display with Wyse C00X. According to
-     * Silicon Image SiI 164 datasheet (VT1632A is a pin and mostly
-     * register compatible chip), offset 0x0C is for PLL filter enable,
-     * PLL filter setting, and continuous SYNC enable bits. All of these are
-     * turned off for proper operation. */
-    xf86I2CWriteByte(Private->VT1632I2CDev, 0x0C, 0x00);
+    viaVT1632InitRegisters(pScrn, pVIAVT1632Rec->VT1632I2CDev);
 
-    via_vt1632_dump_registers(pScrn, Private->VT1632I2CDev);
+    via_vt1632_dump_registers(pScrn, pVIAVT1632Rec->VT1632I2CDev);
 
     DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO,
                 "Exiting via_vt1632_mode_set.\n"));
commit f41a57c7b98c32d8c7c8d681ee028deba4951a31
Author: Kevin Brace <kevinbrace at gmx.com>
Date:   Fri Aug 5 22:47:25 2016 -0700

    Discontinuing via_dvi_mode_set
    
    via_vt1632_mode_set callback function will take over the
    equivalent functionality.
    
    Signed-off-by: Kevin Brace <kevinbrace at gmx.com>

diff --git a/src/via_vt1632.c b/src/via_vt1632.c
index 59a2a03..2441bec 100644
--- a/src/via_vt1632.c
+++ b/src/via_vt1632.c
@@ -301,16 +301,6 @@ via_dvi_commit(xf86OutputPtr output)
 {
 }
 
-static void
-via_dvi_mode_set(xf86OutputPtr output, DisplayModePtr mode,
-                 DisplayModePtr adjusted_mode)
-{
-    ScrnInfoPtr pScrn = output->scrn;
-    vgaHWPtr hwp = VGAHWPTR(pScrn);
-
-    via_vt1632_mode_set(output, mode, adjusted_mode);
-}
-
 static xf86OutputStatus
 via_dvi_detect(xf86OutputPtr output)
 {
@@ -360,7 +350,7 @@ const xf86OutputFuncsRec via_dvi_funcs = {
     .mode_fixup         = via_dvi_mode_fixup,
     .prepare            = via_dvi_prepare,
     .commit             = via_dvi_commit,
-    .mode_set           = via_dvi_mode_set,
+    .mode_set           = via_vt1632_mode_set,
     .detect             = via_dvi_detect,
     .get_modes          = xf86OutputGetEDIDModes,
     .destroy            = via_dvi_destroy,
diff --git a/src/via_vt1632.h b/src/via_vt1632.h
index 7706ad6..5efd4f9 100644
--- a/src/via_vt1632.h
+++ b/src/via_vt1632.h
@@ -49,7 +49,6 @@ void via_vt1632_power(xf86OutputPtr output, Bool powerState);
 void via_vt1632_save(xf86OutputPtr output);
 void via_vt1632_restore(xf86OutputPtr output);
 int via_vt1632_mode_valid(xf86OutputPtr output, DisplayModePtr pMode);
-void via_vt1632_mode_set(xf86OutputPtr output, DisplayModePtr mode, DisplayModePtr adjusted_mode);
 xf86OutputStatus via_vt1632_detect(xf86OutputPtr output);
 Bool viaVT1632Init(ScrnInfoPtr pScrn, I2CBusPtr pI2CBus);
 
commit 096f4121173126f950462e1b0f583c7b14d573cb
Author: Kevin Brace <kevinbrace at gmx.com>
Date:   Fri Aug 5 22:31:38 2016 -0700

    Changing via_dvi_dpms to via_vt1632_dpms
    
    Signed-off-by: Kevin Brace <kevinbrace at gmx.com>

diff --git a/src/via_vt1632.c b/src/via_vt1632.c
index fc8c59b..59a2a03 100644
--- a/src/via_vt1632.c
+++ b/src/via_vt1632.c
@@ -248,7 +248,7 @@ via_dvi_get_property(xf86OutputPtr output, Atom property)
 #endif
 
 static void
-via_dvi_dpms(xf86OutputPtr output, int mode)
+via_vt1632_dpms(xf86OutputPtr output, int mode)
 {
     ScrnInfoPtr pScrn = output->scrn;
 
@@ -353,7 +353,7 @@ const xf86OutputFuncsRec via_dvi_funcs = {
 #ifdef RANDR_13_INTERFACE
     .get_property       = via_dvi_get_property,
 #endif
-    .dpms               = via_dvi_dpms,
+    .dpms               = via_vt1632_dpms,
     .save               = via_dvi_save,
     .restore            = via_dvi_restore,
     .mode_valid         = via_dvi_mode_valid,


More information about the Openchrome-devel mailing list