Bug 59119 - G450 problem restoring non standard text mode
G450 problem restoring non standard text mode
Status: CLOSED RAWHIDE
Product: Red Hat Linux
Classification: Retired
Component: XFree86 (Show other bugs)
7.2
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Mike A. Harris
David Lawrence
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2002-01-31 06:02 EST by Rudolf Ulc
Modified: 2007-04-18 12:39 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2002-02-01 01:36:14 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Patch for XFree86-4.1.0-15.src.rpm (1.44 KB, patch)
2002-02-01 01:36 EST, Rudolf Ulc
no flags Details | Diff

  None (edit)
Description Rudolf Ulc 2002-01-31 06:02:03 EST
Description of Problem:

The mga driver in XFree86-4.1 does not restore text mode properly,
when returning to nonstandard text mode (/etc/lilo.conf vga=7),
instead of restoring the clock that was when X started. 

Version-Release number of selected component (if applicable):
XFree86-4.1.0 (XFree86-4.2.0 in rawhide ?).

How Reproducible:

Steps to Reproduce:
1. Matrox G450, XWindow 4.1.0
2. /etc/lilo/conf with line vga=7
3. startx
4. Ctrl-Alt-F1 -> for my monitor ADI 6P - refresh out of range for XWindow 
resolution 1280x1024 or vrefresh 167 Hz for XWindow resolution 1024x768 etc.

Patch:
diff -uNr xc.orig/programs/Xserver/hw/xfree86/drivers/mga/mga.h 
xc/programs/Xserver/hw/xfree86/drivers/mga/mga.h
--- xc.orig/programs/Xserver/hw/xfree86/drivers/mga/mga.h	Fri May  4 
21:05:41 2001
+++ xc/programs/Xserver/hw/xfree86/drivers/mga/mga.h	Mon Jan 28 18:59:46 2002
@@ -117,6 +117,7 @@
     unsigned char *     DacRegs;
     unsigned long	crtc2[0x58];
     unsigned char	dac2[0x21];
+    Bool		PIXPLLC_Saved;
     CARD32		Option;
     CARD32		Option2;
     CARD32		Option3;
diff -uNr xc.orig/programs/Xserver/hw/xfree86/drivers/mga/mga_dacG.c 
xc/programs/Xserver/hw/xfree86/drivers/mga/mga_dacG.c
--- xc.orig/programs/Xserver/hw/xfree86/drivers/mga/mga_dacG.c	Fri Apr  6 
18:51:19 2001
+++ xc/programs/Xserver/hw/xfree86/drivers/mga/mga_dacG.c	Mon Jan 28 
18:57:22 2002
@@ -212,6 +212,7 @@
 
 	if(MGAISG450(pMga)) {
 		G450SetPLLFreq(pScrn, f_out);
+		pReg->PIXPLLC_Saved = FALSE; 
 		return;
 	}
 
@@ -672,7 +673,7 @@
 		  (i == 0x1c) ||
 		  ((i >= 0x1f) && (i <= 0x29)) ||
 		  ((i >= 0x30) && (i <= 0x37)) ||
-		  (MGAISG450(pMga) &&
+		  (MGAISG450(pMga) && !mgaReg->PIXPLLC_Saved &&
 		   ((i == 0x2c) || (i == 0x2d) || (i == 0x2e) ||
 		    (i == 0x4c) || (i == 0x4d) || (i == 0x4e))))
 		 continue; 
@@ -794,6 +795,8 @@
 	for (i = 0; i < DACREGSIZE; i++)
 		mgaReg->DacRegs[i] = inMGAdac(i);
 
+	mgaReg->PIXPLLC_Saved = TRUE;
+	
 	mgaReg->Option = pciReadLong(pMga->PciTag, PCI_OPTION_REG);
 
 	mgaReg->Option2 = pciReadLong(pMga->PciTag, PCI_MGA_OPTION2);
diff -uNr xc.orig/programs/Xserver/hw/xfree86/drivers/mga/mga.h 
xc/programs/Xserver/hw/xfree86/drivers/mga/mga.h
--- xc.orig/programs/Xserver/hw/xfree86/drivers/mga/mga.h	Fri May  4 
21:05:41 2001
+++ xc/programs/Xserver/hw/xfree86/drivers/mga/mga.h	Mon Jan 28 18:59:46 2002
@@ -117,6 +117,7 @@
     unsigned char *     DacRegs;
     unsigned long	crtc2[0x58];
     unsigned char	dac2[0x21];
+    Bool		PIXPLLC_Saved;
     CARD32		Option;
     CARD32		Option2;
     CARD32		Option3;

Additional Information:
This patch is from 
http://www.xfree86.org/pipermail/xpert/2002-January/014666.html
Comment 1 Mike A. Harris 2002-01-31 11:26:06 EST
The patch doesn't apply cleanly.  Please attach all patches as bugzilla
file attachments so that whitespace changes do not get mixed into the
patch.

Thanks
Comment 2 Rudolf Ulc 2002-02-01 01:36:09 EST
Created attachment 44236 [details]
Patch for XFree86-4.1.0-15.src.rpm
Comment 3 Mike A. Harris 2002-02-02 06:14:12 EST
Patch modified to work with XFree86 4.2.0 and applied to 4.2.0
build.  Will appear in rawhide shortly.
Comment 4 Need Real Name 2002-04-08 10:27:44 EDT
This is also a problem with the MGA 200 card, tried vga=7 and
"video=matrox:vesa:0x0x1B8". no luck, still a problem. output from messages:

Apr  4 10:08:35 lxready gnome-name-server[1630]: input condition is: 0x11, exiting
Apr  4 10:08:35 lxready gdm(pam_unix)[1412]: session closed for user readyp
Apr  4 10:08:36 lxready kernel: bridge-eth0: clear IFF_PROMISC
Apr  4 10:08:36 lxready gdm[1412]: gdm_slave_xioerror_handler: Fatal X error -
Restarting :0
Apr  4 10:08:52 lxready gdm(pam_unix)[5456]: session opened for user readyp by
(uid=0)
Apr  4 10:08:56 lxready gnome-name-server[5584]: starting
Apr  4 10:08:56 lxready gnome-name-server[5584]: name server starting


Just got 4.2 from xfee86.org and testing

Note You need to log in before you can comment on or make changes to this bug.