Bug 470725

Summary: intel: suspend to RAM / resume fails if desktop effects are enabled (965GM)
Product: [openSUSE] openSUSE 11.1 Reporter: Forgotten User ZhJd0F0L3x <forgotten_ZhJd0F0L3x>
Component: X.OrgAssignee: Forgotten User Wum0mkMcd8 <forgotten_Wum0mkMcd8>
Status: RESOLVED DUPLICATE QA Contact: E-mail List <xorg-maintainer-bugs>
Severity: Major    
Priority: P3 - Medium CC: forgotten_a525umNONh, gothica, kent.liu, marc.ruehrschneck, quanxian.wang, sndirsch, youquan.song
Version: Final   
Target Milestone: Final   
Hardware: Other   
OS: Other   
Whiteboard:
Found By: Development Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Attachments: logfile afer crash

Description Forgotten User ZhJd0F0L3x 2009-01-29 18:47:13 UTC
00:02.0 VGA compatible controller: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller (rev 0c)

xorg-x11-driver-video-7.4-28.2

after suspend to RAM and resume, the X display is locked up, then the x server terminates and I am back at the login screen. Also the console is broken, I can no longer switch to a text console.

If I disable 3D effects in KDE4 systemsettings module, everything works fine.
Note that I don't have to configure anything in xorg.conf, just disable it in KDE.

(adding Pavel and Rafael, as we will be probably getting more reports of this type)
Comment 1 Rafael Wysocki 2009-01-29 21:51:55 UTC
This most probably is an upstream problem with the Intel graphics driver and Xorg.  I'd had related problems on my production box until I disabled DRI in the Xorg config.

We need to involve some Intel graphics developers here, if possible.
Comment 2 Rafael Wysocki 2009-01-29 21:53:15 UTC
Ah, most probably libdrm is also a part of the equation.
Comment 3 Stefan Dirsch 2009-01-29 22:05:34 UTC
Thanks for the report, seife. This is an interesting issue. I'll digg into this ASAP when trying to reproduce it on my Sony laptop with GM45 chipset.
Comment 4 Stefan Dirsch 2009-01-31 12:28:11 UTC
Seife, could it be that you're using XAA due to EXA's bad 2D performance? It's a known issue with XAA that Xserver terminates after resume from suspend-to-ram/suspend-to-disk.
Comment 5 Forgotten User ZhJd0F0L3x 2009-02-02 10:57:01 UTC
I don't think so:
seife@stoetzler:~> grep EXA /var/log/Xorg.0.log
(==) intel(0): Using EXA for acceleration
(II) EXA(0): Offscreen pixmap area of 55296000 bytes
(II) EXA(0): Driver registered support for the following operations:
Comment 6 Stefan Dirsch 2009-02-02 11:02:54 UTC
Indeed you're using EXA.
Comment 7 Stefan Dirsch 2009-02-02 11:31:40 UTC
Well, suspend-to-ram does not work at all for me.

# powersave -u
method return sender=:1.0 -> dest=:1.126 reply_serial=2
   int32 127
linux-kl68:~ #

Machine is 10.10.100.116
Comment 9 Stefan Dirsch 2009-02-02 11:57:00 UTC
Ok. I can suspend-to-ram with 's2ram --force', but display remains black after resume. So similar or even worse issue on my Sony Vaio VGN-Z540 here.
Comment 10 Rafael Wysocki 2009-02-02 14:15:22 UTC
What graphics?
Comment 11 Stefan Dirsch 2009-02-02 14:25:58 UTC
GM45.
Comment 12 Rafael Wysocki 2009-02-03 08:18:40 UTC
Is that reported as Intel Corporation Mobile 945GM/GMS/GME by lspci?
Comment 13 Stefan Dirsch 2009-02-03 08:26:39 UTC
GM45 != 945GM. GM45 belongs to 965 family.
Comment 16 Rafael Wysocki 2009-02-03 16:05:21 UTC
Has suspend to RAM ever worked on this machine?
Comment 17 Stefan Dirsch 2009-02-04 17:51:13 UTC
Seife, could you add Xorg.0.log.old right after the crash occured? Thanks.
Comment 18 Forgotten User ZhJd0F0L3x 2009-02-04 18:08:07 UTC
For me it's no longer readily reproducible (although I don't think that there was anything in yesterday's update to FACTORY that would have fixed it, i.e. no new kernel or X server). I'll scream as soon as it happens again.
Comment 19 Forgotten User ZhJd0F0L3x 2009-02-04 18:19:57 UTC
And yes, on my machine (HP2510p) suspend to RAM always worked fine, even in the old days when we still used VBE_POST|VBE_MODE ;)
Comment 20 Forgotten User ZhJd0F0L3x 2009-02-05 21:33:03 UTC
Created attachment 270606 [details]
logfile afer crash

It happened again, although a bit differently. This is what happened:
- I made sure 3d effects was enabled.
- Yesterday evening, I suspended and resumed just fine, but the machine locked up hard shortly afterwards (a few minutes). Hard reboot.
- 3D was still enabled.
- This morning, suspend to ram, resume in the office. 3D still active
- This evening, I pulled the machine out of the port replicator and wanted to suspend, but I noticed that 3D was disabled (probably by powerdevil, because I was no longer on AC power. I disabled the "disable 3D on battery" function, but powerdevil often does not really do what you tell it.
- So I wanted to enable 3D again in the KDE control panel (which was telling me "Desktop effects [X]" even though they clearly werent). So I unchecked and checked the checkbox, clicked "apply" and boom - X server locked up.
After ~5 seconds, it terminated, KDM restarted it and I was at the login screen.
Console is broken now.

I'm attaching the logfile, but there is nothing useful in it (same as last time). It is the correct logfile, as I can tell from the timestamp at the beginning.
Comment 21 Forgotten User ZhJd0F0L3x 2009-02-05 21:36:15 UTC
I found this in kdm.log, at the right place (before the start of the now running X server):

Xorg: intel_bufmgr_fake.c:769: drm_intel_bufmgr_fake_contended_lock_take: Assertion `_fence_test(bufmgr_fake, block->fence)' failed.

Does this help?
Comment 22 Forgotten User ZhJd0F0L3x 2009-02-05 21:45:30 UTC
I found 3 of those intel_bufmgr_fake.c messages in kdm.log and that is the number of such crashes that I remember. So it looks related. Unfortunately there are no timestamps in kdm.log :-(

In syslog, there is only:
Feb  5 21:49:42 stoetzler kernel: [82697.721807] [drm:i915_getparam] *ERROR* Unknown parameter 5
Feb  5 21:49:52 stoetzler kdm[2911]: X server for display :0 terminated unexpectedly
Comment 23 Stefan Dirsch 2009-02-06 05:02:12 UTC
(In reply to comment #21)
> Xorg: intel_bufmgr_fake.c:769: drm_intel_bufmgr_fake_contended_lock_take:
> Assertion `_fence_test(bufmgr_fake, block->fence)' failed.

That's it. It's in libdrm.

(In reply to comment #22)
> In syslog, there is only:
> Feb  5 21:49:42 stoetzler kernel: [82697.721807] [drm:i915_getparam] *ERROR*
> Unknown parameter 5

Ignore this one. This way it's tested if the kernel supports GEM.
Comment 24 Stefan Dirsch 2009-02-06 05:07:15 UTC
Possibly fixed with libdrm in X11:XOrg:testing project. Other packages in this project need to be installed as well if you want to verify that.
Comment 25 Forgotten User ZhJd0F0L3x 2009-02-06 09:03:14 UTC
I installed libdrm-2.4.4 and rpm did not complain. So I don't think I really need other packages, right? (I did not reboot the machine yet ;)
Comment 26 Stefan Dirsch 2009-02-06 09:05:57 UTC
Rebooting shouldn't be required. Ok. could be that libdrm is backward compatible to some extent.
Comment 27 Forgotten User ZhJd0F0L3x 2009-02-08 22:13:13 UTC
new libdrm-2.4.4 and friends (xorg-driver-video, Mesa) did not help:

Xorg: intel_bufmgr_fake.c:769: drm_intel_bufmgr_fake_contended_lock_take: Assertion `_fence_test(bufmgr_fake, block->fence)' failed.

after returning from resume. Xorg.0.log.old again contains nothing useful.
Comment 28 Forgotten User ZhJd0F0L3x 2009-02-08 23:11:24 UTC
The new libdrm / driver / Mesa combo is even worse.
Everytime I start xine, it crashes:


seife@stoetzler:~> grep Xorg.*1365: /var/log/kdm.log
Xorg: intel_bufmgr_fake.c:1365: drm_intel_fake_bo_exec: Assertion `ret == 0' failed.
Xorg: intel_bufmgr_fake.c:1365: drm_intel_fake_bo_exec: Assertion `ret == 0' failed.
Xorg: intel_bufmgr_fake.c:1365: drm_intel_fake_bo_exec: Assertion `ret == 0' failed.
Xorg: intel_bufmgr_fake.c:1365: drm_intel_fake_bo_exec: Assertion `ret == 0' failed.
Xorg: intel_bufmgr_fake.c:1365: drm_intel_fake_bo_exec: Assertion `ret == 0' failed.
Xorg: intel_bufmgr_fake.c:1365: drm_intel_fake_bo_exec: Assertion `ret == 0' failed.
Xorg: intel_bufmgr_fake.c:1365: drm_intel_fake_bo_exec: Assertion `ret == 0' failed.

So I had to revert to the old libdrm-2.4.1
Comment 29 Marc Ruehrschneck 2009-02-10 09:19:16 UTC
Kent recommends to report this issue to freedesktop also.
Comment 30 Stefan Dirsch 2009-03-01 02:38:52 UTC
With the latest updates in X11:XOrg (xorg-server 1.6, xf86-video-intel 2.6.2, libdrm 2.4.5, Mesa 7.3) suspend/hibernate no longer works at all. After resume the screen remains black, you can still control the backlight, but can't switch to Linux console any longer, neither kill the Xserver with Ctrl-Alt-BS. All you can do is a cold reboot. Great stuff, this new X. This is on 945GM and openSUSE 11.1 running KDE3.
Comment 31 Stefan Dirsch 2009-03-01 02:39:32 UTC
(In reply to comment #30)
> With the latest updates in X11:XOrg (xorg-server 1.6, xf86-video-intel 2.6.2,
> libdrm 2.4.5, Mesa 7.3) suspend/hibernate no longer works at all. After resume
> the screen remains black, you can still control the backlight, but can't switch
> to Linux console any longer, neither kill the Xserver with Ctrl-Alt-BS. All you
> can do is a cold reboot. Great stuff, this new X. This is on 945GM and openSUSE
> 11.1 running KDE3.

No Desktop effects, no compiz.
Comment 32 Stefan Dirsch 2009-03-01 02:45:36 UTC
I've been stupid. I was using XAA. After switching back to EXA resuming from suspend/hibernate works fine again.
Comment 33 Stefan Dirsch 2009-03-09 15:04:28 UTC
Is this still an issue with the latest packages from X11:XOrg buildservice project?
Comment 34 Forgotten User ZhJd0F0L3x 2009-03-09 17:08:53 UTC
It doesn't seem so (although my latest update was mid of last week, after the xrandr fix, but it seems to work pretty well now). I can reopen this if it happens again.
Comment 35 Stefan Dirsch 2009-03-09 17:13:29 UTC
Ok. Let's close it as fixed for now. Thanks for testing. BTW, next update might be surprising for you. empty xorg.conf should be enough for intel now. At least it's for me on 945GM.
Comment 39 Stefan Dirsch 2009-05-06 08:37:00 UTC
*** Bug 500994 has been marked as a duplicate of this bug. ***
Comment 40 Stefan Dirsch 2009-05-21 11:37:27 UTC

*** This bug has been marked as a duplicate of bug 500994 ***
Comment 41 Pavel pavel 2009-05-21 13:31:47 UTC
For me on openSUSE 11.1 with latest updates from X11:Xorg xserver still crashes...
Comment 42 Stefan Dirsch 2009-05-21 14:01:22 UTC
This is a duplicate! Please do not reopen.

*** This bug has been marked as a duplicate of bug 500994 ***