summaryrefslogtreecommitdiff
path: root/src/mga_merge.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mga_merge.c')
-rw-r--r--src/mga_merge.c27
1 files changed, 16 insertions, 11 deletions
diff --git a/src/mga_merge.c b/src/mga_merge.c
index 53b81be..73b085a 100644
--- a/src/mga_merge.c
+++ b/src/mga_merge.c
@@ -940,23 +940,28 @@ MGASaveScreenMerged(ScreenPtr pScreen, int mode)
if (on) {
/* SetTimdeSinceLastInputEvent();*/
-
+
/* power on Dac1 */
- reg = inMGAdac(0x1E);
- outMGAdac(0x1E, reg | 1);
+ reg = inMGAdac(MGA1064_MISC_CTL);
+ reg |= MGA1064_MISC_CTL_DAC_EN;
+ outMGAdac(MGA1064_MISC_CTL, reg);
+
/* power on Dac2 */
- reg = inMGAdac(0xA0);
- outMGAdac(0xA0, reg | 1);
-
+ reg = inMGAdac(MGA1064_PWR_CTL);
+ reg |= MGA1064_PWR_CTL_DAC2_EN;
+ outMGAdac(MGA1064_PWR_CTL, reg);
} else {
/* power off Dac1 */
- reg = inMGAdac(0x1E);
- outMGAdac(0x1E, reg & ~1);
- /* power off Dac2 */
- reg = inMGAdac(0xA0);
- outMGAdac(0xA0, reg & ~1);
+ reg = inMGAdac(MGA1064_MISC_CTL);
+ reg &= ~MGA1064_MISC_CTL_DAC_EN;
+ outMGAdac(MGA1064_MISC_CTL, reg);
+ /* power off Dac2 */
+ reg = inMGAdac(MGA1064_PWR_CTL);
+ reg &= ~MGA1064_PWR_CTL_DAC2_EN;
+ outMGAdac(MGA1064_PWR_CTL, reg);
}
+
return TRUE;
}