Bug 17235 - [G45] system sometimes freezes at starting Xorg, on Gigabyte EG45M-DS2H with VGA
Summary: [G45] system sometimes freezes at starting Xorg, on Gigabyte EG45M-DS2H with VGA
Status: RESOLVED FIXED
Alias: None
Product: xorg
Classification: Unclassified
Component: Driver/intel (show other bugs)
Version: 7.3 (2007.09)
Hardware: All Linux (All)
: high critical
Assignee: Wang Zhenyu
QA Contact: Xorg Project Team
URL:
Whiteboard:
Keywords:
: 18957 (view as bug list)
Depends on:
Blocks: intel-2.5 18858
  Show dependency treegraph
 
Reported: 2008-08-21 00:57 UTC by Tomoya Simono
Modified: 2009-08-09 19:12 UTC (History)
9 users (show)

See Also:
i915 platform:
i915 features:


Attachments
Xorg boot log with debugprint (case 1) (9.95 KB, text/plain)
2008-08-21 01:03 UTC, Tomoya Simono
no flags Details
Xorg boot log with debugprint (case 2) (18.96 KB, text/plain)
2008-08-21 01:06 UTC, Tomoya Simono
no flags Details
Xorg Configuration file (757 bytes, text/plain)
2008-08-21 01:08 UTC, Tomoya Simono
no flags Details
Debugprint patch for xorg-video-intel-2.4.1 (2.85 KB, text/plain)
2008-08-21 01:17 UTC, Tomoya Simono
no flags Details
Xorg Log with xf86-video-intel-2.4-branch (case 1) (11.02 KB, text/plain)
2008-09-17 01:49 UTC, Tomoya Simono
no flags Details
Xorg Log with xf86-video-intel-2.4-branch (case 2) (16.95 KB, text/plain)
2008-09-17 01:50 UTC, Tomoya Simono
no flags Details
Xorg Log with Option "NoAccel" "true" (fail case 1-1) (11.06 KB, text/plain)
2008-09-24 20:48 UTC, Tomoya Simono
no flags Details
Xorg Log with Option "NoAccel" "true" (fail case 1-2) (11.12 KB, text/plain)
2008-09-24 20:54 UTC, Tomoya Simono
no flags Details
Xorg Log with Option "NoAccel" "true" (fail case 2) (14.76 KB, text/plain)
2008-09-24 20:56 UTC, Tomoya Simono
no flags Details
Xorg Log with Option "NoAccel" "true" (success case) (26.59 KB, text/plain)
2008-09-24 20:57 UTC, Tomoya Simono
no flags Details
xorg.conf with Option "NoAccel" "true" (864 bytes, text/plain)
2008-09-24 20:59 UTC, Tomoya Simono
no flags Details
Xorg Log with Option "EXANoComposite" "true" (fail case 1-1) (10.99 KB, text/plain)
2008-09-24 21:03 UTC, Tomoya Simono
no flags Details
Xorg Log with Option "EXANoComposite" "true" (fail case 1-2) (11.05 KB, text/plain)
2008-09-24 21:06 UTC, Tomoya Simono
no flags Details
Xorg Log with Option "EXANoComposite" "true" (fail case 2) (16.88 KB, text/plain)
2008-09-24 21:08 UTC, Tomoya Simono
no flags Details
Xorg Log with Option "EXANoComposite" "true" (success case) (29.57 KB, text/plain)
2008-09-24 21:10 UTC, Tomoya Simono
no flags Details
xorg.conf with Option "EXANoComposite" "true" (864 bytes, text/plain)
2008-09-24 21:11 UTC, Tomoya Simono
no flags Details
Xorg boot log with recent environment (case 1) (16.08 KB, text/plain)
2008-11-20 21:50 UTC, Tomoya Simono
no flags Details
Xorg boot log with recent environment (case 2) (20.56 KB, text/plain)
2008-11-20 21:52 UTC, Tomoya Simono
no flags Details
system freeze after "Output TV has no monitor section" without "ModeDebug" option (120.54 KB, text/plain)
2008-11-28 01:29 UTC, lisa
no flags Details
freeze after "0x10000000: end of aperture" with "ModeDebug" option on (191.29 KB, text/plain)
2008-11-28 01:30 UTC, lisa
no flags Details
Xorg boot log with debugprint (case 2) (21.53 KB, text/plain)
2008-11-30 21:30 UTC, Tomoya Simono
no flags Details
Xorg boot log with debugprint (case 3) (16.39 KB, text/plain)
2008-11-30 21:31 UTC, Tomoya Simono
no flags Details
Xorg boot log with debugprint (success) (65.40 KB, text/plain)
2008-11-30 21:32 UTC, Tomoya Simono
no flags Details
Debugprint patch for xorg-video-intel-2.5.1 (6.34 KB, text/plain)
2008-11-30 21:33 UTC, Tomoya Simono
no flags Details
Disable VGA once at EnterVT (1.19 KB, patch)
2008-12-16 22:11 UTC, Wang Zhenyu
no flags Details | Splinter Review
new patch to disable vga plane (1.74 KB, patch)
2009-08-09 19:12 UTC, Wang Zhenyu
no flags Details | Splinter Review

Description Tomoya Simono 2008-08-21 00:57:06 UTC
[Overview]
  On Intel G45 mother board, My Linux Box was freeze and no responding sometimes.

[My Environment]
  I use Fedora9, kernel version is 2.6.26.2, xorg-video-intel version is 2.4.1.
(There isn't official package, because official (older) kernel & xorg-video-intel packages
 didn't work with G45.)

[Step to Reproduce]
  1) Install kernel-2.6.26.2-14.fc9, and xorg-video-intel-2.4.1
     (I arranged from xorg-x11-drv-i810-2.4.0-2.fc10)

  2) Exec "startx"

  3) Freeze and no responding. (Occur probability is about 5%-20%.)

[Actual Results]
  There is no key echo, can't switchVT, no ping reply.
If freeze occurred, I must reset my Linux Box, No other ways.

[Additional Information]
  I read xorg-video-intel-2.4.1 source code, and some debugprint added,
then watched Xorg's behavior.
  Debugprint indicates, Xorg was freezed in function i830_crtc_dpms().


Thank you very much.
Comment 1 Tomoya Simono 2008-08-21 01:03:01 UTC
Created attachment 18432 [details]
Xorg boot log with debugprint (case 1)

This is debugprint log in freeze case 1.

This case's call stack is below.

Breakpoint 1, i830_crtc_dpms (crtc=0x9c0e270, mode=3) at i830_display.c:788
788	    ScrnInfoPtr pScrn = crtc->scrn;
(gdb) bt
#0  i830_crtc_dpms (crtc=0x9c0e270, mode=3) at i830_display.c:788
#1  0x0025fe26 in i830_crtc_prepare (crtc=0x9c0e270) at i830_display.c:1024
#2  0x080e4e0a in xf86CrtcSetMode (crtc=0x9c0e270, mode=0x2b8d80, 
    rotation=<value optimized out>, x=0, y=0) at xf86Crtc.c:327
#3  0x00260f4d in i830GetLoadDetectPipe (output=0x9c0bf08, mode=0x2b8d80, 
    dpms_mode=0xbfb2c528) at i830_display.c:1844
#4  0x0025b20b in i830_crt_detect (output=0x9c0bf08) at i830_crt.c:355
#5  0x080e5550 in xf86ProbeOutputModes (scrn=0x9c0ac18, maxX=8192, maxY=8192)
    at xf86Crtc.c:1378
#6  0x080e60b2 in xf86InitialConfiguration (scrn=0x9c0ac18, canGrow=0)
    at xf86Crtc.c:2037
#7  0x00269510 in I830PreInit (pScrn=0x9c0ac18, flags=<value optimized out>)
    at i830_driver.c:1649
#8  0x080a3fef in InitOutput (pScreenInfo=0x8215080, argc=4, argv=0xbfb2c9a4)
    at xf86Init.c:749
#9  0x0806b479 in main (argc=4, argv=0xbfb2c9a4, envp=0xbfb2c9b8) at main.c:358
Comment 2 Tomoya Simono 2008-08-21 01:06:13 UTC
Created attachment 18434 [details]
 Xorg boot log with debugprint (case 2) 

This Xorg boot log is freeze case 2.

This case's call stack is below. (different from case 1)


Breakpoint 1, i830_crtc_dpms (crtc=0x9c0e270, mode=3) at i830_display.c:788
788	    ScrnInfoPtr pScrn = crtc->scrn;
(gdb) bt
#0  i830_crtc_dpms (crtc=0x9c0e270, mode=3) at i830_display.c:788
#1  0x080e521a in xf86SetDesiredModes (scrn=0x9c0ac18) at xf86Crtc.c:2190
#2  0x00266aae in I830EnterVT (scrnIndex=0, flags=0) at i830_driver.c:3388
#3  0x002680cc in I830ScreenInit (scrnIndex=0, pScreen=0x9c3a418, argc=4, 
    argv=0xbfb2c9a4) at i830_driver.c:3136
#4  0x0806acdf in AddScreen (pfnInit=0x266e60 <I830ScreenInit>, argc=4, 
    argv=0xbfb2c9a4) at main.c:743
#5  0x080a3886 in InitOutput (pScreenInfo=0x8215080, argc=4, argv=0xbfb2c9a4)
    at xf86Init.c:1051
#6  0x0806b479 in main (argc=4, argv=0xbfb2c9a4, envp=0xbfb2c9b8) at main.c:358
Comment 3 Tomoya Simono 2008-08-21 01:08:56 UTC
Created attachment 18435 [details]
Xorg Configuration file

This is my xorg.conf.
Comment 4 Tomoya Simono 2008-08-21 01:17:07 UTC
Created attachment 18436 [details]
Debugprint patch for xorg-video-intel-2.4.1

This is debugprint patch for xorg-video-intel-2.4.1.
I used this for watching Xorg behavior.
Comment 5 Michael Fu 2008-08-21 20:30:42 UTC
do you have the model of the intel G45 board?
Comment 6 Tomoya Simono 2008-08-21 20:43:03 UTC
Yes, I have.
My motherboard name is "Gigabyte EG45M-DS2H".
Comment 7 Andrew McNabb 2008-09-10 14:50:38 UTC
I'm having the same problem with a Gigabyte GA-EG45M-DS2H motherboard and with a Gigabyte GA-EG43M-S2H board.  The one is a G45 and the other is a G43.  I have tried a number of Fedora Rawhide packages, including xorg-x11-drv-i810-2.4.2-1.

I created a Fedora bug at: https://bugzilla.redhat.com/show_bug.cgi?id=461171 which has my Xorg.0.log.
Comment 8 Wang Zhenyu 2008-09-11 19:41:43 UTC
Could you try with current 2.4 branch?
Comment 9 Andrew McNabb 2008-09-12 07:12:07 UTC
Unfortunately, I haven't been able to get X to start at all with recent versions of the Intel driver.  I have a Fedora bug for this at:

https://bugzilla.redhat.com/show_bug.cgi?id=461829

Once I get things basically working, I'll try to get more information about this bug.  Thanks.
Comment 10 Wang Zhenyu 2008-09-15 23:52:32 UTC
Any news? Could you tell me what's the output type you're using when saw this problem? Does VGA work?

Andrew, could you try to remove Virtual size setting in xorg.conf and try again?
Comment 11 Chris Jones 2008-09-16 03:04:33 UTC
I am seeing occasional machine hangs on the DS2H gigabyte board mentioned here, when starting X.

I am running:

ii  xserver-xorg-video-intel                   2:2.4.1-1ubuntu4                      X.Org X server -- Intel i8xx, i9xx display d

on Ubuntu Intrepid, with HDMI output to a Sony 40" TV.
Comment 12 Andrew McNabb 2008-09-16 06:56:24 UTC
On my computer with a G43 board (GA-EG43M-S2H), there is no Virtual size setting.  On my computer with a G45 board (GA-EG45M-DS2H), there is a Virtual size setting, but I had hangs before I added it.  Unfortunately, it's going to be tough for me to try things and make changes until Fedora bug 461829 is fixed ("Intel driver: Couldn't bind memory for BO front buffer").
Comment 13 Tomoya Simono 2008-09-17 01:49:16 UTC
Created attachment 18943 [details]
Xorg Log with xf86-video-intel-2.4-branch (case 1)

Thank you your helps.
I tried current xf86-video-intel-2.4-branch, but, freeze still occurred.

Environment:
  MB: EG45M-DS2H
  OS: Fedora 9 (i386)
  kernel: 2.6.26.3-29.fc9.i686
  Xserver: xorg-x11-server-1.5.0-1
  Xdriver: current xf86-video-intel-2.4-branch
Comment 14 Tomoya Simono 2008-09-17 01:50:44 UTC
Created attachment 18944 [details]
 Xorg Log with xf86-video-intel-2.4-branch (case 2)
Comment 15 Wang Zhenyu 2008-09-18 19:44:09 UTC
Does "NoAccel" or "EXANoComposite" option work around the problem?
Comment 16 Tomoya Simono 2008-09-19 00:04:21 UTC
No, It doesn't.
I tried Option "NoAccel" and "EXANoComposite", but freezes still occurred.
Comment 17 Michael Fu 2008-09-24 06:30:00 UTC
(In reply to comment #10)
> Any news? Could you tell me what's the output type you're using when saw this
> problem? Does VGA work?
> 
> Andrew, could you try to remove Virtual size setting in xorg.conf and try
> again?
> 

Tomoya, would you please tell zhenyu the output you used when this bug happen?
Comment 18 Tomoya Simono 2008-09-24 20:48:20 UTC
Created attachment 19167 [details]
Xorg Log with Option "NoAccel" "true" (fail case 1-1)

These are logs with Option "NoAccel" "true".
Comment 19 Tomoya Simono 2008-09-24 20:54:41 UTC
Created attachment 19168 [details]
Xorg Log with Option "NoAccel" "true" (fail case 1-2)
Comment 20 Tomoya Simono 2008-09-24 20:56:01 UTC
Created attachment 19169 [details]
Xorg Log with Option "NoAccel" "true" (fail case 2)
Comment 21 Tomoya Simono 2008-09-24 20:57:19 UTC
Created attachment 19170 [details]
Xorg Log with Option "NoAccel" "true" (success case)
Comment 22 Tomoya Simono 2008-09-24 20:59:57 UTC
Created attachment 19171 [details]
xorg.conf with Option "NoAccel" "true"

I used this xorg.conf when "NoAccel" tests.
Comment 23 Tomoya Simono 2008-09-24 21:03:50 UTC
Created attachment 19172 [details]
Xorg Log with Option "EXANoComposite" "true" (fail case 1-1)

And, These are logs with Option "EXANoComposite" "true".
Comment 24 Tomoya Simono 2008-09-24 21:06:33 UTC
Created attachment 19173 [details]
Xorg Log with Option "EXANoComposite" "true" (fail case 1-2)
Comment 25 Tomoya Simono 2008-09-24 21:08:34 UTC
Created attachment 19174 [details]
Xorg Log with Option "EXANoComposite" "true" (fail case 2)
Comment 26 Tomoya Simono 2008-09-24 21:10:30 UTC
Created attachment 19175 [details]
Xorg Log with Option "EXANoComposite" "true" (success case)
Comment 27 Tomoya Simono 2008-09-24 21:11:55 UTC
Created attachment 19176 [details]
xorg.conf with Option "EXANoComposite" "true"

I used this xorg.conf when "EXANoComposite" tests.
Comment 28 Michael Fu 2008-09-25 21:03:43 UTC
(In reply to comment #17)
> (In reply to comment #10)
> > Any news? Could you tell me what's the output type you're using when saw this
> > problem? Does VGA work?
> > 
> > Andrew, could you try to remove Virtual size setting in xorg.conf and try
> > again?
> > 
> 
> Tomoya, would you please tell zhenyu the output you used when this bug happen?
> 

from the log, Tomoya is using VGA.
Comment 29 Wang Zhenyu 2008-09-25 21:42:21 UTC
Could you try current master tip? gigabyte G43 works fine here for me.
Comment 30 Wang Zhenyu 2008-09-27 20:10:31 UTC
Could you also try patch on #17756?
Comment 31 liuhaien 2008-09-27 20:30:32 UTC
(In reply to comment #29)
> Could you try current master tip? gigabyte G43 works fine here for me.
> 

I have tested master tip on our G45,this issue still exists.
Comment 32 Gordon Jin 2008-10-04 23:49:31 UTC
*** Bug 17905 has been marked as a duplicate of this bug. ***
Comment 33 Wang Zhenyu 2008-10-06 20:49:43 UTC
I've tested with same G45 as Haien, and can't produce this bug. I use all master tips.
Comment 34 Gordon Jin 2008-10-06 23:12:38 UTC
(In reply to comment #33)
> I've tested with same G45 as Haien, and can't produce this bug. I use all
> master tips.

Then how about Q3 release?
It may not matter to choose xf86-video-intel master or 2.4/2.5, but for kernel/drm part, we should use mainline kernel instead of drm master.

Comment 35 Wang Zhenyu 2008-10-07 00:49:31 UTC
(In reply to comment #34)
> (In reply to comment #33)
> > I've tested with same G45 as Haien, and can't produce this bug. I use all
> > master tips.
> 
> Then how about Q3 release?
> It may not matter to choose xf86-video-intel master or 2.4/2.5, but for
> kernel/drm part, we should use mainline kernel instead of drm master.
> 

Haien followed my testing with his harddisk restored, which can't produce now either.
He will provide further result later I think.
Comment 36 Wang Zhenyu 2008-10-08 18:39:44 UTC
I want to close this as we can't see this problem with current master or 2.5-branch builds, which contains recent series of G45 fixes. So reopen this if you can still produce with git master or 2.5-branch. Thanks.
Comment 37 martin 2008-10-09 10:15:57 UTC
I originally filed bug 17905 which was closed as a duplicate of this one. I can still repro my bug, however, my backtrace/xorg.log is slightly different and also my bug happens _every_ time I login so I will not reopen this one.

Instead I will reopen bug 17905, please have a look at it.
Comment 38 Tomoya Simono 2008-10-09 19:07:11 UTC
Thanks your works.


I tested DG45M-DS2H and DG45ID with xf86-video-intel-2.5-branch.

[result]
   DG45M-DS2H(DVI): success 100/100, fail  0/100.
   DG45M-DS2H(VGA): success  39/50 , fail 11/50.
   DG45ID(VGA):     success 100/100, fail  0/100.

This result means, DG45M-DS2H still freezing with newest xf86-video-intel(2.5) too.
But, DG45ID was not encount freeze, it works fine.
Comment 39 Wang Zhenyu 2008-10-09 23:30:14 UTC
Could you try my last patch on #17892 for VGA? Could  you describe your testing method? So we can try steps to trigger this.
Comment 40 Tomoya Simono 2008-10-13 21:14:25 UTC
Thanks Zhenyu.  I applied your #17892 patch.

[Environment]
  MB: DG45M-DS2H
  CPU: Core 2 Duo E8400
  Monitor: DELL 17" LFP (VGA connection)
  OS: Fedora 9 i386
  Kernel: 2.6.26.3-29.fc9.i686
  Xorg: xorg-x11-server-Xorg-1.5.0.1.fc9.i386
  libdrm: (from git) libdrm-2.4.0
  Driver: (from git) xf86-video-intel-2.5-branch + #17892 patch

[Test method]
  (Pre1) Edit /boot/grub/grub.conf, set boot default to single-usermode.
  (Pre2) Enable sshd service, and open sshd port.

  (1) Test PC startup in single-usermode. Exec "/etc/rc.d/rc 3".
  (2) SSH login from other PC to test PC.
  (3) Try startx, "startx -- -keeptty -verbose 7".
  (4) Startx usually success(about 75-80%), but sometimes fail(about 20-25%).
  (5) Count "fail" if test PC was freezed (it don't respond).
  (6) Count "fail(case 1) if test PC was freeze near after "Output VGA using initial mode 1280x1024".
  (7) Count "fail(case 2) if test PC was freeze near after "0x10000000:            end of aperture".

  (Post1) If startx succeed, I input "Ctrl+C" to abort Xorg for next test.
  (Post2) If test PC was freezed, I reboot test PC for next test. 

 My method is too complex, because if I try normal boot, PC was freeze complete silentry at "fail" case.

[Recent test result]
  I tried to startx 100 times with #17892 patch.
    Success:      75/100 (75%)
    Fail(Case 1)  5/100  (5%)
    Fail(Case 2) 20/100 (20%)

[Before test result(#38)]
  I tried to startx 50 times with vanilla xf86-video-intel-2.5-branch(2008-10-09 version).
    Success:      39/50 (78%)
    Fail(Case 1)  6/50 (12%)
    Fail(Case 2)  5/50 (10%)

I think it has some difference, with/without #17892 patch.
Comment 41 Gordon Jin 2008-10-14 06:18:03 UTC
I think this bug should be reopened.
Comment 42 Gordon Jin 2008-10-14 20:20:32 UTC
Could you test with git://git.kernel.org/pub/scm/linux/kernel/git/anholt/drm-intel drm-intel-next branch and xf86-video-intel master branch?
There're new G45 fixes and hope that could fix this problem as well.
Comment 43 Gordon Jin 2008-10-16 06:09:17 UTC
The patches on drm-intel-next are very likely to fix this issue. So please give it a try, or say you won't be able to test it so we won't be pending on your response. Thanks!
Comment 44 Tomoya Simono 2008-10-17 02:08:46 UTC
Thanks your works!  And sorry to your waiting.
I tried drm-intel-next and xf86-video-intel master branch.

# I switched from Fedora 9 to Fedora 10 Beta,
# because newest drm-intel-next is part of kernel-2.6.27,
# and kernel-2.6.27 packages is not exist in Fedora 9 repo.

[Environment]
  MB: DG45M-DS2H
  CPU: Core 2 Duo E8400
  Monitor: DELL 17" LFP (VGA connection)
  OS: Fedora 10 Beta i386
  Kernel: (from Koji) 2.6.27.2-23.rc1.fc10.i686
  Xorg: xorg-x11-server-Xorg-1.5.2-4.fc10.i386
  libdrm: libdrm-2.4.0-0.21.fc10.i386
  Driver: (from git) xf86-video-intel-master-branch (@2008/10/17)

[Test method]
  Same to #40.

[Recent test result]
  I tried to startx 100 times with drm-intel-next and xf86-video-intel master branch.
    Success:      68/100 (68%)
    Fail(Case 1) 24/100 (24%)
    Fail(Case 2)  8/100  (8%)

I hope this result is useful information for you...
Comment 45 Wang Zhenyu 2008-10-23 22:33:55 UTC
Although Gem work and recent fixes are in linus's git tree and in 2.6.28-rc1, I think it will still be good for us to know test result with anholt's drm-intel-next tree.
Comment 46 Gordon Jin 2008-11-17 01:07:48 UTC
Tomoya, I'm getting confused. Is the kernel you tested in comment#44 2.6.27.2-23.rc1.fc10 or drm-intel-next?
Comment 47 Tomoya Simono 2008-11-20 21:47:46 UTC
Gordon, I tested with 2.6.27.2-23.rc1.fc10 in comment#44.
Sorry to causing your confuse.

And, I tried same test with recent environment.
With newest drm-intel-next, libdrm, mesa, xf86-video-intel.

[Environment]
  MB: DG45M-DS2H
  CPU: Core 2 Duo E8400
  Memory: 2GB
  Monitor: DELL 17" LFP (VGA connection)
  OS: Fedora 10 Preview i386
  Kernel: drm-intel-next(2.6.28-rc4) (with git in 2008/11/20)
  Xorg:   xorg-x11-server-Xorg-1.5.3-5.fc10.i386
  libdrm: mesa/drm(2.4.1) (with git in 2008/11/20)
  mesa:   mesa/mesa(7.3.0) (with git in 2008/11/20)
  Driver: xf86-video-intel-2.5.1-release (it looks same as git in 2008/11/20)

[Test method]
  Same to comment#40.

[Recent test result]
  I tried to startx 100 times with recent environment.
    Success:      73/100 (73%)
    Fail(Case 1) 15/100 (15%)
    Fail(Case 2) 12/100  (12%)
Comment 48 Tomoya Simono 2008-11-20 21:50:28 UTC
Created attachment 20486 [details]
Xorg boot log with recent environment (case 1)
Comment 49 Tomoya Simono 2008-11-20 21:52:46 UTC
Created attachment 20487 [details]
Xorg boot log with recent environment (case 2)
Comment 50 Michael Fu 2008-11-21 00:00:28 UTC
(In reply to comment #47)
> Gordon, I tested with 2.6.27.2-23.rc1.fc10 in comment#44.
> Sorry to causing your confuse.
> 
> And, I tried same test with recent environment.
> With newest drm-intel-next, libdrm, mesa, xf86-video-intel.
> 
> [Environment]
>   MB: DG45M-DS2H
>   CPU: Core 2 Duo E8400
>   Memory: 2GB
>   Monitor: DELL 17" LFP (VGA connection)
>   OS: Fedora 10 Preview i386
>   Kernel: drm-intel-next(2.6.28-rc4) (with git in 2008/11/20)
>   Xorg:   xorg-x11-server-Xorg-1.5.3-5.fc10.i386
>   libdrm: mesa/drm(2.4.1) (with git in 2008/11/20)
>   mesa:   mesa/mesa(7.3.0) (with git in 2008/11/20)
>   Driver: xf86-video-intel-2.5.1-release (it looks same as git in 2008/11/20)
> 
> [Test method]
>   Same to comment#40.
> 
> [Recent test result]
>   I tried to startx 100 times with recent environment.
>     Success:      73/100 (73%)
>     Fail(Case 1) 15/100 (15%)
>     Fail(Case 2) 12/100  (12%)
> 

do you have exactly failed case 1? the current driver code path on G45 system shouldn't call i830GetLoadDetectPipe  at all...would you please double check? thanks.
Comment 51 lisa 2008-11-28 01:26:32 UTC
hi, all, this problem happens to my G43 board too: system freezed when I startx. I use VGA output.

This happens both on latest Fedora 10 and my RHEL5.3. I haven't checked Fedora 10's sourcecodes yet but on RHEL5.3 I patch the fixes you mentioned above (so it includes: Sep 26th Zhenyu's fix for G4x, Oct 1st Olivier's fix for plane/pipe/vga, and Oct.12th Zhenyu's fix for crt probe). Please correct me if I missed sth, thanks!

I got 2 different failed case too 
1)one is after "Output TV has no monitor section" 
2)another at: "0x10000000:            end of aperture"  (like Tomoya)
I pasted the logs and hope it can help solve the problem.
Comment 52 lisa 2008-11-28 01:29:02 UTC
Created attachment 20652 [details]
system freeze after "Output TV has no monitor section" without "ModeDebug" option

Logs from patched RHEL5.3 on G43. Xorg.conf has no "ModeDebug" option.
Comment 53 lisa 2008-11-28 01:30:54 UTC
Created attachment 20653 [details]
freeze after "0x10000000:            end of aperture" with "ModeDebug" option on

Another log from G43 on patched RHEL5.3.
Comment 54 Gordon Jin 2008-11-29 21:17:07 UTC
(In reply to comment #51)
> hi, all, this problem happens to my G43 board too: system freezed when I
> startx. I use VGA output.
> 
> This happens both on latest Fedora 10 and my RHEL5.3. I haven't checked Fedora
> 10's sourcecodes yet but on RHEL5.3 I patch the fixes you mentioned above (so
> it includes: Sep 26th Zhenyu's fix for G4x, Oct 1st Olivier's fix for
> plane/pipe/vga, and Oct.12th Zhenyu's fix for crt probe). Please correct me if
> I missed sth, thanks!

Lisa, the key patch is "Fix stolen memory counting on G4X." http://git.kernel.org/?p=linux/kernel/git/anholt/drm-intel.git;a=commit;h=2052746fc8397130c120f0194a89938b0b62b6cb.

Please check if your distribution has included it. If yes, Zhenyu you need take true high priority.
Comment 55 lisa 2008-11-30 17:12:56 UTC
Thanks,Gordon.
The patches from Eric (both about 2D and intel-agp) were already included in my RHEL5.3 codes, i already double checked it. Is there anything else i can try? Zhenyu, any comments on it?  thanks!
Comment 56 Tomoya Simono 2008-11-30 21:29:19 UTC
Thank you Michael.
Today, I ran startx test with comment#40 method 100 times.

Recent test result:
  I tried to startx 100 times in comment#47 environment.
    Success:      70/100 (70%)
    Fail(Case 1)  0/100  (0%)
    Fail(Case 2) 10/100 (10%)
    Fail(Case 3) 20/100 (20%)

This result means:
 (1) Now, Don't occur fail case 1. (Always bypass i830GetLoadDetectPipe())
    I can't found fail case 1 in startx 100 times test.
    I think, case 1 was resolved.  Thank you very much!!

 (2) Still occur fail case 2.
    Fail case 2 was still occured.
    I try to add debug print, it said, case 2 was occured in i830_crtc_dpms().

 (3) New fail case 3 was found.
    Unfortunately, I found new fail case, "Case 3."
    It occures at I830AccelMethodInit()->RestoreHWState()->i830_crtc_dpms() timing.

Thanks!
Comment 57 Tomoya Simono 2008-11-30 21:30:18 UTC
Created attachment 20704 [details]
Xorg boot log with debugprint (case 2)
Comment 58 Tomoya Simono 2008-11-30 21:31:31 UTC
Created attachment 20705 [details]
Xorg boot log with debugprint (case 3)
Comment 59 Tomoya Simono 2008-11-30 21:32:24 UTC
Created attachment 20706 [details]
Xorg boot log with debugprint (success)
Comment 60 Tomoya Simono 2008-11-30 21:33:43 UTC
Created attachment 20707 [details]
Debugprint patch for xorg-video-intel-2.5.1
Comment 61 Wang Zhenyu 2008-12-08 18:18:03 UTC
This needs to be tested with current master, Keith's CRT patch might help this. But we'll try to produce it here.
Comment 62 Wang Zhenyu 2008-12-16 22:11:41 UTC
Created attachment 21227 [details] [review]
Disable VGA once at EnterVT

Please help to test with this patch.
Comment 63 Tomoya Simono 2008-12-17 22:07:47 UTC
Thank you Zhenyu, your patch is works fine!!


[Environment]
  MB: DG45M-DS2H
  CPU: Core 2 Duo E8400
  Memory: 2GB
  Monitor: DELL 17" LFP (VGA connection)
  OS: Fedora 10 i386
  Kernel: drm-intel-next(2.6.28-rc4) (with git in 2008/11/20)
  Xorg:   xorg-x11-server-Xorg-1.5.3-5.fc10.i386
  libdrm: mesa/drm(2.4.2) (with git in 2008/12/9)
  mesa:   mesa/mesa(7.3.0) (with git in 2008/11/20)
  Driver: xf86-video-intel master (with git in 2008/12/18) + comment#62 patch

[Recent test result]
  I tried to startx 100 times.
    Success:      98/100 (98%)
    Fail(Case 1)  0/100  (0%)
    Fail(Case 2)  2/100  (2%)
    Fail(Case 3)  0/100  (0%)

Fail case 3 was gone, and still fail case 2 occur, but it's rarely.

Thanks!!
Comment 64 Wang Zhenyu 2008-12-17 22:49:00 UTC
Actually my testing on G43 run about >350 times X cycles before hang at one point. This is really weird, but it looks this patch does help in some place...
Comment 65 Gordon Jin 2008-12-21 21:07:41 UTC
*** Bug 18957 has been marked as a duplicate of this bug. ***
Comment 66 Eric Anholt 2008-12-22 18:08:25 UTC
patch looks good to me
Comment 67 lisa 2008-12-25 18:14:04 UTC
The patch fixes my problem on G43 too. I am with RHEL 5.3. And now freezing problem only occurs once in about 100+ tries.  Thank you, Zhenyu.
Comment 68 Wang Zhenyu 2008-12-29 22:46:06 UTC
sigh, it looks I still can't find the root cause of this after trying out different methods and use display disabling order from spec. And my patch looks doesn't work that stable in DVI monitor usage. 

Tomoya, is it true Intel DG45 board doesn't have this issue from beginning?
Comment 69 Wang Zhenyu 2009-01-13 23:17:04 UTC
Ma Ling finally caught what's really going wrong with our driver. Now fix is pushed, please verify it. thanks.

commit db9f5915ce812144ffd9d2aa42e8ba856129c35e
Author: Ma Ling <ling.ma@intel.com>
Date:   Wed Jan 14 14:46:52 2009 +0800

    Disable VGA plane reliably

    This fixes #17235, VGA random hang on recent G45/43 board.
    From spec, SR01 bit 5 should be set before VGA plane disable through
    control register, otherwise we might get random crash and lockups.
Comment 70 lisa 2009-01-19 22:42:13 UTC
I already tried to patch the codes by Ma Ling: "Disable VGA plane reliably" onto RHEL5.3 env on G43 with VGA output. And after about 120+ times, and not got the X freeze problem till now.  I think the problem is fixed on my platform. Thanks, all! 
Comment 71 Wang Zhenyu 2009-08-09 19:12:01 UTC
Created attachment 28461 [details] [review]
new patch to disable vga plane 

Hi, friends, could you help to test this new patch for vga disabling? We've seen many broken cases caused by origin patch, so this just make sure origin problem is still got fixed.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.