[Openchrome-devel] xf86-video-openchrome: 8 commits - configure.ac src/via_display.c
Kevin Brace
kevinbrace at kemper.freedesktop.org
Mon Apr 25 00:19:39 UTC 2016
configure.ac | 2
src/via_display.c | 152 ++++++++++++++++++++++++++++--------------------------
2 files changed, 80 insertions(+), 74 deletions(-)
New commits:
commit e75369dbfeda296c51995ae79318c3fb0ead0ff2
Author: Kevin Brace <kevinbrace at gmx.com>
Date: Sun Apr 24 12:50:33 2016 -0700
Version bumped to 0.4.133
Signed-off-by: Kevin Brace <kevinbrace at gmx.com>
diff --git a/configure.ac b/configure.ac
index 8c2dcf6..c2dcacc 100644
--- a/configure.ac
+++ b/configure.ac
@@ -23,7 +23,7 @@
# Initialize Autoconf
AC_PREREQ(2.57)
AC_INIT([xf86-video-openchrome],
- [0.4.132],
+ [0.4.133],
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg&component=Driver/openchrome],
[xf86-video-openchrome])
commit 5a165f2904fe9e3563d7e50007beb777978e2f61
Author: Kevin Brace <kevinbrace at gmx.com>
Date: Sun Apr 24 12:48:02 2016 -0700
Moving viaIGA2SetMode location
This function is located inside via_display.c.
Signed-off-by: Kevin Brace <kevinbrace at gmx.com>
diff --git a/src/via_display.c b/src/via_display.c
index 3de9edc..81be558 100644
--- a/src/via_display.c
+++ b/src/via_display.c
@@ -948,26 +948,6 @@ viaIGA2SetDisplayRegister(ScrnInfoPtr pScrn, DisplayModePtr mode)
"Exiting viaIGA2SetDisplayRegister.\n"));
}
-void
-viaIGA2SetMode(ScrnInfoPtr pScrn, DisplayModePtr mode)
-{
- VIAPtr pVia = VIAPTR(pScrn);
- VIABIOSInfoPtr pBIOSInfo = pVia->pBIOSInfo;
- vgaHWPtr hwp = VGAHWPTR(pScrn);
- DisplayModePtr realMode = mode;
-
- DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO, "viaIGA2SetMode\n"));
-
- viaIGA2SetDisplayRegister(pScrn, realMode);
- ViaSetSecondaryFIFO(pScrn, realMode);
- pBIOSInfo->Clock = ViaModeDotClockTranslate(pScrn, realMode);
- pBIOSInfo->ClockExternal = FALSE;
- ViaSetSecondaryDotclock(pScrn, pBIOSInfo->Clock);
- ViaSetUseExternalClock(hwp);
-
- hwp->disablePalette(hwp);
-}
-
static ModeStatus
viaIGA2ModeValid(ScrnInfoPtr pScrn, DisplayModePtr mode)
{
@@ -1015,6 +995,26 @@ viaIGA2ModeValid(ScrnInfoPtr pScrn, DisplayModePtr mode)
return MODE_OK;
}
+void
+viaIGA2SetMode(ScrnInfoPtr pScrn, DisplayModePtr mode)
+{
+ VIAPtr pVia = VIAPTR(pScrn);
+ VIABIOSInfoPtr pBIOSInfo = pVia->pBIOSInfo;
+ vgaHWPtr hwp = VGAHWPTR(pScrn);
+ DisplayModePtr realMode = mode;
+
+ DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO, "viaIGA2SetMode\n"));
+
+ viaIGA2SetDisplayRegister(pScrn, realMode);
+ ViaSetSecondaryFIFO(pScrn, realMode);
+ pBIOSInfo->Clock = ViaModeDotClockTranslate(pScrn, realMode);
+ pBIOSInfo->ClockExternal = FALSE;
+ ViaSetSecondaryDotclock(pScrn, pBIOSInfo->Clock);
+ ViaSetUseExternalClock(hwp);
+
+ hwp->disablePalette(hwp);
+}
+
/*
* Not tested yet
*/
commit 6a4a27f7414620a48f6f648ebc134f5c16f5ebc0
Author: Kevin Brace <kevinbrace at gmx.com>
Date: Sun Apr 24 12:43:06 2016 -0700
Moving viaIGA1ModeValid location
This function is located inside via_display.c.
Signed-off-by: Kevin Brace <kevinbrace at gmx.com>
diff --git a/src/via_display.c b/src/via_display.c
index 96381bc..3de9edc 100644
--- a/src/via_display.c
+++ b/src/via_display.c
@@ -527,6 +527,56 @@ viaIGA1SetFBStartingAddress(xf86CrtcPtr crtc, int x, int y)
"Exiting viaIGA1SetFBStartingAddress.\n"));
}
+/*
+ * Checks for limitations imposed by the available VGA timing registers.
+ */
+static ModeStatus
+viaIGA1ModeValid(ScrnInfoPtr pScrn, DisplayModePtr mode)
+{
+ DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO,
+ "Entered viaIGA1ModeValid.\n"));
+
+ if (mode->CrtcHTotal > 4100)
+ return MODE_BAD_HVALUE;
+
+ if (mode->CrtcHDisplay > 2048)
+ return MODE_BAD_HVALUE;
+
+ if (mode->CrtcHBlankStart > 2048)
+ return MODE_BAD_HVALUE;
+
+ if ((mode->CrtcHBlankEnd - mode->CrtcHBlankStart) > 1025)
+ return MODE_HBLANK_WIDE;
+
+ if (mode->CrtcHSyncStart > 4095)
+ return MODE_BAD_HVALUE;
+
+ if ((mode->CrtcHSyncEnd - mode->CrtcHSyncStart) > 256)
+ return MODE_HSYNC_WIDE;
+
+ if (mode->CrtcVTotal > 2049)
+ return MODE_BAD_VVALUE;
+
+ if (mode->CrtcVDisplay > 2048)
+ return MODE_BAD_VVALUE;
+
+ if (mode->CrtcVSyncStart > 2047)
+ return MODE_BAD_VVALUE;
+
+ if ((mode->CrtcVSyncEnd - mode->CrtcVSyncStart) > 16)
+ return MODE_VSYNC_WIDE;
+
+ if (mode->CrtcVBlankStart > 2048)
+ return MODE_BAD_VVALUE;
+
+ if ((mode->CrtcVBlankEnd - mode->CrtcVBlankStart) > 257)
+ return MODE_VBLANK_WIDE;
+
+ DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO,
+ "Exiting viaIGA1ModeValid.\n"));
+ return MODE_OK;
+}
+
void
viaIGA1SetMode(ScrnInfoPtr pScrn, DisplayModePtr mode)
{
@@ -918,56 +968,6 @@ viaIGA2SetMode(ScrnInfoPtr pScrn, DisplayModePtr mode)
hwp->disablePalette(hwp);
}
-/*
- * Checks for limitations imposed by the available VGA timing registers.
- */
-static ModeStatus
-viaIGA1ModeValid(ScrnInfoPtr pScrn, DisplayModePtr mode)
-{
- DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO,
- "Entered viaIGA1ModeValid.\n"));
-
- if (mode->CrtcHTotal > 4100)
- return MODE_BAD_HVALUE;
-
- if (mode->CrtcHDisplay > 2048)
- return MODE_BAD_HVALUE;
-
- if (mode->CrtcHBlankStart > 2048)
- return MODE_BAD_HVALUE;
-
- if ((mode->CrtcHBlankEnd - mode->CrtcHBlankStart) > 1025)
- return MODE_HBLANK_WIDE;
-
- if (mode->CrtcHSyncStart > 4095)
- return MODE_BAD_HVALUE;
-
- if ((mode->CrtcHSyncEnd - mode->CrtcHSyncStart) > 256)
- return MODE_HSYNC_WIDE;
-
- if (mode->CrtcVTotal > 2049)
- return MODE_BAD_VVALUE;
-
- if (mode->CrtcVDisplay > 2048)
- return MODE_BAD_VVALUE;
-
- if (mode->CrtcVSyncStart > 2047)
- return MODE_BAD_VVALUE;
-
- if ((mode->CrtcVSyncEnd - mode->CrtcVSyncStart) > 16)
- return MODE_VSYNC_WIDE;
-
- if (mode->CrtcVBlankStart > 2048)
- return MODE_BAD_VVALUE;
-
- if ((mode->CrtcVBlankEnd - mode->CrtcVBlankStart) > 257)
- return MODE_VBLANK_WIDE;
-
- DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO,
- "Exiting viaIGA1ModeValid.\n"));
- return MODE_OK;
-}
-
static ModeStatus
viaIGA2ModeValid(ScrnInfoPtr pScrn, DisplayModePtr mode)
{
commit 4834a9d9c57ff7eba5359da9a4d5597e3c31f89f
Author: Kevin Brace <kevinbrace at gmx.com>
Date: Sun Apr 24 12:35:48 2016 -0700
Added debug messages to viaIGA1ModeValid
This function is located inside via_display.c.
Signed-off-by: Kevin Brace <kevinbrace at gmx.com>
diff --git a/src/via_display.c b/src/via_display.c
index bb8875a..96381bc 100644
--- a/src/via_display.c
+++ b/src/via_display.c
@@ -924,7 +924,8 @@ viaIGA2SetMode(ScrnInfoPtr pScrn, DisplayModePtr mode)
static ModeStatus
viaIGA1ModeValid(ScrnInfoPtr pScrn, DisplayModePtr mode)
{
- DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO, "viaIGA1ModeValid\n"));
+ DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO,
+ "Entered viaIGA1ModeValid.\n"));
if (mode->CrtcHTotal > 4100)
return MODE_BAD_HVALUE;
@@ -962,6 +963,8 @@ viaIGA1ModeValid(ScrnInfoPtr pScrn, DisplayModePtr mode)
if ((mode->CrtcVBlankEnd - mode->CrtcVBlankStart) > 257)
return MODE_VBLANK_WIDE;
+ DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO,
+ "Exiting viaIGA1ModeValid.\n"));
return MODE_OK;
}
commit b0cecb3c48039f877d1ed994299ca7b6e12aeb7e
Author: Kevin Brace <kevinbrace at gmx.com>
Date: Sun Apr 24 12:29:50 2016 -0700
Changing ViaFirstCRTCModeValid to viaIGA1ModeValid
This function is located inside via_display.c.
Signed-off-by: Kevin Brace <kevinbrace at gmx.com>
diff --git a/src/via_display.c b/src/via_display.c
index e3f2a8d..bb8875a 100644
--- a/src/via_display.c
+++ b/src/via_display.c
@@ -922,9 +922,9 @@ viaIGA2SetMode(ScrnInfoPtr pScrn, DisplayModePtr mode)
* Checks for limitations imposed by the available VGA timing registers.
*/
static ModeStatus
-ViaFirstCRTCModeValid(ScrnInfoPtr pScrn, DisplayModePtr mode)
+viaIGA1ModeValid(ScrnInfoPtr pScrn, DisplayModePtr mode)
{
- DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO, "ViaFirstCRTCModeValid\n"));
+ DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO, "viaIGA1ModeValid\n"));
if (mode->CrtcHTotal > 4100)
return MODE_BAD_HVALUE;
@@ -1147,7 +1147,7 @@ iga1_crtc_mode_fixup(xf86CrtcPtr crtc, DisplayModePtr mode,
return FALSE;
}
- modestatus = ViaFirstCRTCModeValid(pScrn, mode);
+ modestatus = viaIGA1ModeValid(pScrn, mode);
if (modestatus != MODE_OK) {
xf86DrvMsg(pScrn->scrnIndex, X_INFO, "Not using mode \"%s\" : %s.\n",
mode->name, xf86ModeStatusToString(modestatus));
@@ -1544,7 +1544,7 @@ iga2_crtc_mode_fixup(xf86CrtcPtr crtc, DisplayModePtr mode,
return FALSE;
}
- modestatus = ViaFirstCRTCModeValid(pScrn, mode);
+ modestatus = viaIGA1ModeValid(pScrn, mode);
if (modestatus != MODE_OK) {
xf86DrvMsg(pScrn->scrnIndex, X_INFO, "Not using mode \"%s\" : %s.\n",
mode->name, xf86ModeStatusToString(modestatus));
commit 4ceb752d2075b04b070425d826099310013e9f65
Author: Kevin Brace <kevinbrace at gmx.com>
Date: Sun Apr 24 12:21:41 2016 -0700
Added debug messages to viaIGA2ModeValid
This function is located inside via_display.c.
Signed-off-by: Kevin Brace <kevinbrace at gmx.com>
diff --git a/src/via_display.c b/src/via_display.c
index f17cf13..e3f2a8d 100644
--- a/src/via_display.c
+++ b/src/via_display.c
@@ -968,7 +968,8 @@ ViaFirstCRTCModeValid(ScrnInfoPtr pScrn, DisplayModePtr mode)
static ModeStatus
viaIGA2ModeValid(ScrnInfoPtr pScrn, DisplayModePtr mode)
{
- DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO, "viaIGA2ModeValid\n"));
+ DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO,
+ "Entered viaIGA2ModeValid.\n"));
if (mode->CrtcHTotal > 4096)
return MODE_BAD_HVALUE;
@@ -1006,6 +1007,8 @@ viaIGA2ModeValid(ScrnInfoPtr pScrn, DisplayModePtr mode)
if ((mode->CrtcVSyncEnd - mode->CrtcVSyncStart) > 32)
return MODE_VSYNC_WIDE;
+ DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO,
+ "Exiting viaIGA2ModeValid.\n"));
return MODE_OK;
}
commit df1de1a8ddb243a8d58f94c9d9915bad1366c27b
Author: Kevin Brace <kevinbrace at gmx.com>
Date: Sun Apr 24 12:13:24 2016 -0700
Changing ViaSecondCRTCModeValid to viaIGA2ModeValid
This function is located inside via_display.c.
Signed-off-by: Kevin Brace <kevinbrace at gmx.com>
diff --git a/src/via_display.c b/src/via_display.c
index 257fccc..f17cf13 100644
--- a/src/via_display.c
+++ b/src/via_display.c
@@ -966,9 +966,9 @@ ViaFirstCRTCModeValid(ScrnInfoPtr pScrn, DisplayModePtr mode)
}
static ModeStatus
-ViaSecondCRTCModeValid(ScrnInfoPtr pScrn, DisplayModePtr mode)
+viaIGA2ModeValid(ScrnInfoPtr pScrn, DisplayModePtr mode)
{
- DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO, "ViaSecondCRTCModeValid\n"));
+ DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO, "viaIGA2ModeValid\n"));
if (mode->CrtcHTotal > 4096)
return MODE_BAD_HVALUE;
commit c7f8743ee99bd275d14abcf3339b8bd05008734a
Author: Kevin Brace <kevinbrace at gmx.com>
Date: Sun Apr 24 12:05:42 2016 -0700
Fixing horizontal and vertical retrace end registers for IGA2
It was likely that horizontal and vertical retrace end registers were
never set correctly when the screen mode was set for IGA2.
Signed-off-by: Kevin Brace <kevinbrace at gmx.com>
diff --git a/src/via_display.c b/src/via_display.c
index 967e3a2..257fccc 100644
--- a/src/via_display.c
+++ b/src/via_display.c
@@ -760,7 +760,7 @@ viaIGA2SetDisplayRegister(ScrnInfoPtr pScrn, DisplayModePtr mode)
/* Horizontal Retrace End: 511 (max) */
DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO,
"IGA2 CrtcHSyncEnd: %d\n", mode->CrtcHSyncEnd));
- temp = mode->CrtcHSyncEnd;
+ temp = mode->CrtcHSyncEnd - mode->CrtcHSyncStart;
/* 3X5.57[7:0]: Horizontal Retrace End Bits[7:0] */
hwp->writeCrtc(hwp, 0x57, temp & 0xFF);
@@ -838,7 +838,7 @@ viaIGA2SetDisplayRegister(ScrnInfoPtr pScrn, DisplayModePtr mode)
/* Vertical Retrace End: 511 (max) */
DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO,
"IGA2 CrtcVSyncEnd: %d\n", mode->CrtcVSyncEnd));
- temp = mode->CrtcVSyncEnd;
+ temp = mode->CrtcVSyncEnd - mode->CrtcVSyncStart;
/*3X5.5F[4:0]: Vertical Retrace End[4:0] */
ViaCrtcMask(hwp, 0x5F, temp & 0x1F, 0x1F);
More information about the Openchrome-devel
mailing list