summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKevin Brace <kevinbrace@gmx.com>2018-11-28 16:50:26 -0800
committerKevin Brace <kevinbrace@gmx.com>2018-12-29 15:53:31 -0600
commit7d5e01a41fa21293c286a5e42ac3ed4371bb9103 (patch)
treeaa790960b0ba2f0e40c45c8f532251cbe7c616d3
parent2fd317834a6ec0e271a5d12fce4b0cbfcacd5db4 (diff)
Stop the use of originalCRXX variables inside VIADisplayRec struct
Signed-off-by: Kevin Brace <kevinbrace@gmx.com>
-rw-r--r--src/via_display.c10
-rw-r--r--src/via_ums.c7
-rw-r--r--src/via_ums.h4
3 files changed, 5 insertions, 16 deletions
diff --git a/src/via_display.c b/src/via_display.c
index a6773f5..03cf12f 100644
--- a/src/via_display.c
+++ b/src/via_display.c
@@ -959,11 +959,11 @@ viaIGAInitCommon(ScrnInfoPtr pScrn)
}
/* 3X5.3B through 3X5.3F are scratch pad registers. */
- ViaCrtcMask(hwp, 0x3B, pVIADisplay->originalCR3B, 0xFF);
- ViaCrtcMask(hwp, 0x3C, pVIADisplay->originalCR3C, 0xFF);
- ViaCrtcMask(hwp, 0x3D, pVIADisplay->originalCR3D, 0xFF);
- ViaCrtcMask(hwp, 0x3E, pVIADisplay->originalCR3E, 0xFF);
- ViaCrtcMask(hwp, 0x3F, pVIADisplay->originalCR3F, 0xFF);
+ ViaCrtcMask(hwp, 0x3B, Regs->CR[0x3B], 0xFF);
+ ViaCrtcMask(hwp, 0x3C, Regs->CR[0x3C], 0xFF);
+ ViaCrtcMask(hwp, 0x3D, Regs->CR[0x3D], 0xFF);
+ ViaCrtcMask(hwp, 0x3E, Regs->CR[0x3E], 0xFF);
+ ViaCrtcMask(hwp, 0x3F, Regs->CR[0x3F], 0xFF);
/* 3X5.47[5] - Peep at the PCI-bus
* 0: Disable
diff --git a/src/via_ums.c b/src/via_ums.c
index b0c3aa3..a789e4f 100644
--- a/src/via_ums.c
+++ b/src/via_ums.c
@@ -1227,13 +1227,6 @@ umsCrtcInit(ScrnInfoPtr pScrn)
}
}
- /* 3X5.3B through 3X5.3F are scratch pad registers. */
- pVIADisplay->originalCR3B = hwp->readCrtc(hwp, 0x3B);
- pVIADisplay->originalCR3C = hwp->readCrtc(hwp, 0x3C);
- pVIADisplay->originalCR3D = hwp->readCrtc(hwp, 0x3D);
- pVIADisplay->originalCR3E = hwp->readCrtc(hwp, 0x3E);
- pVIADisplay->originalCR3F = hwp->readCrtc(hwp, 0x3F);
-
/* Read memory bandwidth from registers. */
pVia->MemClk = hwp->readCrtc(hwp, 0x3D) >> 4;
DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO,
diff --git a/src/via_ums.h b/src/via_ums.h
index 898da05..6286983 100644
--- a/src/via_ums.h
+++ b/src/via_ums.h
@@ -228,10 +228,6 @@ typedef struct _VIADISPLAY {
/* OLPC XO-1.5 */
Bool isOLPCXO15;
- /* Shadow copy of CR3B through CR3F. */
- CARD8 originalCR3B, originalCR3C, originalCR3D,
- originalCR3E, originalCR3F;
-
VIARegRec SavedReg;
xf86OutputPtr tv;