configure.ac | 2 - src/via_driver.c | 17 +++++++++++++++ src/via_driver.h | 6 +++++ src/via_lvds.c | 62 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ src/via_ums.h | 1 5 files changed, 87 insertions(+), 1 deletion(-)
New commits: commit 84193485247e7a0cc871b1e003ba596026768cf5 Author: Kevin Brace <kevinbr...@gmx.com> Date: Thu Feb 23 13:24:08 2017 -0800 Version bumped to 0.5.183 This version fixes FIC CE260 / CE261 netbook FP LVDS interface turn on / off. Another major bug fix for OpenChrome DDX. Signed-off-by: Kevin Brace <kevinbr...@gmx.com> diff --git a/configure.ac b/configure.ac index a9a72a0..8efe157 100644 --- a/configure.ac +++ b/configure.ac @@ -23,7 +23,7 @@ # Initialize Autoconf AC_PREREQ(2.57) AC_INIT([xf86-video-openchrome], - [0.5.182], + [0.5.183], [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg&component=Driver/openchrome], [xf86-video-openchrome]) commit 41c4beb6000c154b5920c715fadd86ca2da197f0 Author: Kevin Brace <kevinbr...@gmx.com> Date: Thu Feb 23 13:21:14 2017 -0800 Improvement in initializing FIC CE260 / CE261 netbook FP Had to add a special handling case in order to properly handle FIC CE260 / CE261 netbook FP LVDS interface turn on / off. In particular, this fix aids FP reinitialization when resuming from standby. FIC CE260 / CE261 were sold as Everex CloudBook and Sylvania g netbook. Signed-off-by: Kevin Brace <kevinbr...@gmx.com> diff --git a/src/via_driver.c b/src/via_driver.c index ee2ee40..01090e2 100644 --- a/src/via_driver.c +++ b/src/via_driver.c @@ -1462,6 +1462,23 @@ viaPreInit(ScrnInfoPtr pScrn, int flags) pVia->I2CScan ? "" : "not "); #endif /* HAVE_DEBUG */ + /* Checking for VIA Technologies NanoBook reference design. + Examples include Everex CloudBook and Sylvania g netbook. + It is also called FIC CE260 and CE261 by its ODM (Original + Design Manufacturer) name. + This device has its strapping resistors set to a wrong + setting to handle DVI. As a result, we need to make special + accommodations to handle DVI properly. */ + if ((pVia->Chipset == VIA_CX700) && + (SUBVENDOR_ID(pVia->PciInfo) == 0x1509) && + (SUBSYS_ID(pVia->PciInfo) == 0x2D30)) { + + pVia->isVIANanoBook = TRUE; + } else { + pVia->isVIANanoBook = FALSE; + } + + /* Checking for OLPC XO-1.5. */ if ((pVia->Chipset == VIA_VX855) && (SUBVENDOR_ID(pVia->PciInfo) == 0x152D) && diff --git a/src/via_driver.h b/src/via_driver.h index d566187..123463c 100644 --- a/src/via_driver.h +++ b/src/via_driver.h @@ -284,6 +284,12 @@ typedef struct _VIA { /* BIOS Info Ptr */ VIABIOSInfoPtr pBIOSInfo; + /* VIA Technologies NanoBook reference design. + Examples include Everex CloudBook and Sylvania g netbook. + It is also called FIC CE260 and CE261 by its ODM (Original + Design Manufacturer) name. */ + Bool isVIANanoBook; + /* OLPC XO-1.5 */ Bool IsOLPCXO15; diff --git a/src/via_lvds.c b/src/via_lvds.c index 0605cce..3af9290 100644 --- a/src/via_lvds.c +++ b/src/via_lvds.c @@ -106,6 +106,28 @@ static DisplayModeRec OLPCMode = { #define TD3 25 /* + * Sets CX700 or later single chipset's LVDS1 I/O pad state. + */ +void +viaLVDS1SetIOPadSetting(ScrnInfoPtr pScrn, CARD8 ioPadState) +{ + vgaHWPtr hwp = VGAHWPTR(pScrn); + + DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO, + "Entered viaLVDS1SetIOPadSetting.\n")); + + /* Set LVDS1 I/O pad state. */ + /* 3C5.2A[1:0] - LVDS1 I/O Pad Control */ + ViaSeqMask(hwp, 0x2A, ioPadState, 0x03); + xf86DrvMsg(pScrn->scrnIndex, X_INFO, + "LVDS1 I/O Pad State: %d\n", + (ioPadState & 0x03)); + + DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO, + "Exiting viaLVDS1SetIOPadSetting.\n")); +} + +/* * Sets IGA1 or IGA2 as the display output source for VIA Technologies * Chrome IGP LVDS1 integrated LVDS transmitter. */ @@ -158,6 +180,28 @@ viaLVDS1SetFormat(ScrnInfoPtr pScrn, CARD8 format) } /* + * Sets CX700 or later single chipset's LVDS2 I/O pad state. + */ +static void +viaLVDS2SetIOPadSetting(ScrnInfoPtr pScrn, CARD8 ioPadState) +{ + vgaHWPtr hwp = VGAHWPTR(pScrn); + + DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO, + "Entered viaLVDS2SetIOPadSetting.\n")); + + /* Set LVDS2 I/O pad state. */ + /* 3C5.2A[3:2] - LVDS2 I/O Pad Control */ + ViaSeqMask(hwp, 0x2A, ioPadState << 2, 0x0C); + xf86DrvMsg(pScrn->scrnIndex, X_INFO, + "LVDS2 I/O Pad State: %d\n", + (ioPadState & 0x03)); + + DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO, + "Exiting viaLVDS2SetIOPadSetting.\n")); +} + +/* * Sets IGA1 or IGA2 as the display output source for VIA Technologies * Chrome IGP LVDS2 integrated LVDS transmitter. */ @@ -471,6 +515,24 @@ viaFPIOPadSetting(ScrnInfoPtr pScrn, Bool ioPadOn) case VIA_VX800: case VIA_VX855: case VIA_VX900: + /* 3C5.13[7:6] - DVP1D15 and DVP1D14 pin strappings + * 00: LVDS1 + LVDS2 + * 01: DVI + LVDS2 + * 10: Dual LVDS (LVDS1 + LVDS2 used + * simultaneously) + * 11: DVI only */ + if ((((~(sr13 & 0x80)) && (~(sr13 & 0x40))) + || ((sr13 & 0x80) && (~(sr13 & 0x40)))) + && (!pVia->isVIANanoBook)) { + + viaLVDS1SetIOPadSetting(pScrn, ioPadOn ? 0x03 : 0x00); + } + + if (((~(sr13 & 0x80)) || (~(sr13 & 0x40))) + || (pVia->isVIANanoBook)) { + + viaLVDS2SetIOPadSetting(pScrn, ioPadOn ? 0x03 : 0x00); + } break; default: break; diff --git a/src/via_ums.h b/src/via_ums.h index bba65a7..254686c 100644 --- a/src/via_ums.h +++ b/src/via_ums.h @@ -265,6 +265,7 @@ void ViaShadowCRTCSetMode(ScrnInfoPtr pScrn, DisplayModePtr mode); void via_analog_init(ScrnInfoPtr pScrn); /* via_lvds.c */ +void viaLVDS1SetIOPadSetting(ScrnInfoPtr pScrn, CARD8 ioPadState); void via_lvds_init(ScrnInfoPtr pScrn); /* via_tmds.c */ _______________________________________________ Openchrome-devel mailing list Openchrome-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/openchrome-devel