Bug 92168

Summary: 1.17.2 broke glamor for xf86-video-ati
Product: xorg Reporter: Dimitar Kosev <buboleck>
Component: Server/Acceleration/glamorAssignee: Xorg Project Team <xorg-team>
Status: RESOLVED FIXED QA Contact: Xorg Project Team <xorg-team>
Severity: major    
Priority: medium CC: atoth
Version: unspecified   
Hardware: x86-64 (AMD64)   
OS: Linux (All)   
URL: https://bugs.gentoo.org/show_bug.cgi?id=554606
Whiteboard:
i915 platform: i915 features:
Attachments:
Description Flags
Xorg log from the crash (Starting KDE from KDM)
none
Xorg log with the same setup starting Fluxbox from KDM)
none
working Xorg log file 1.17.1-r1
none
failing Xorg log file 1.17.2 none

Description Dimitar Kosev 2015-09-28 18:24:30 UTC
After installing xorg-server 1.17.2 KDM failed to load KDE. Checking the logs I saw that X fails to load glamor and the ati drivers:

EE) 
(EE) Backtrace:
(EE) 0: /usr/bin/X (xorg_backtrace+0x42) [0x58aa22]
(EE) 1: /usr/bin/X (0x400000+0x18ece9) [0x58ece9]
(EE) 2: /lib64/libc.so.6 (0x7f307a1c3000+0x354d0) [0x7f307a1f84d0]
(EE) 3: /lib64/libc.so.6 (0x7f307a1c3000+0x933e0) [0x7f307a2563e0]
(EE) 4: /usr/lib64/dri/radeonsi_dri.so (0x7f3074946000+0x146c4e) [0x7f3074a8cc4e]
(EE) 5: /usr/lib64/dri/radeonsi_dri.so (0x7f3074946000+0x1d151f) [0x7f3074b1751f]
(EE) 6: /usr/lib64/dri/radeonsi_dri.so (0x7f3074946000+0x147eb0) [0x7f3074a8deb0]
(EE) 7: /usr/lib64/dri/radeonsi_dri.so (0x7f3074946000+0x14805a) [0x7f3074a8e05a]
(EE) 8: /usr/lib64/xorg/modules/libglamoregl.so (0x7f30758a0000+0x21df8) [0x7f30758c1df8]
(EE) 9: /usr/lib64/xorg/modules/libglamoregl.so (0x7f30758a0000+0x1cf15) [0x7f30758bcf15]
(EE) 10: /usr/lib64/xorg/modules/libglamoregl.so (0x7f30758a0000+0x1d4ca) [0x7f30758bd4ca]
(EE) 11: /usr/lib64/xorg/modules/libglamoregl.so (0x7f30758a0000+0x195a1) [0x7f30758b95a1]
(EE) 12: /usr/lib64/xorg/modules/libglamoregl.so (0x7f30758a0000+0x1a0f2) [0x7f30758ba0f2]
(EE) 13: /usr/bin/X (0x400000+0x11488a) [0x51488a]
(EE) 14: /usr/bin/X (0x400000+0x10a50a) [0x50a50a]
(EE) 15: /usr/bin/X (0x400000+0x3735e) [0x43735e]
(EE) 16: /usr/bin/X (0x400000+0x3b315) [0x43b315]
(EE) 17: /lib64/libc.so.6 (__libc_start_main+0xf5) [0x7f307a1e4ad5]
(EE) 18: /usr/bin/X (0x400000+0x2622e) [0x42622e]
(EE) 
(EE) Segmentation fault at address 0x10
(EE) 
Fatal server error:

I'm using Gentoo, I was advised to file bug here too. Please let me know what additional information I can provide and I will collect it.
Comment 1 Matt Turner 2015-09-28 18:38:26 UTC
Thanks :)

(The downstream bug says he could reproduce the segfault with mesa-10.6.[1-3])
Comment 2 Attila Tóth 2015-09-28 19:57:30 UTC
(In reply to Matt Turner from comment #1)
> Thanks :)
> 
> (The downstream bug says he could reproduce the segfault with
> mesa-10.6.[1-3])

Let me join.
I see this happening on a system using Ati FirePro 5950M and on another with Ati FirePro V4800.
The symptom can be triggered using a range of mesa versions - the latest I've tried was 11.0.
It only occurs after bumping xorg-seever to 1.17.2 and I don't experience it running xorg version 1.17.1.

Thanks:
Dw.
Comment 3 Michel Dänzer 2015-09-29 07:57:43 UTC
Please attach the full Xorg.0.log file.
Comment 4 Dimitar Kosev 2015-09-30 09:04:11 UTC
Created attachment 118532 [details]
Xorg log from the crash (Starting KDE from KDM)
Comment 5 Dimitar Kosev 2015-09-30 09:05:56 UTC
Created attachment 118533 [details]
Xorg log with the same setup starting Fluxbox from KDM)
Comment 6 Michel Dänzer 2015-09-30 09:23:58 UTC
Can you bisect xserver and/or attach a gdb backtrace of the crash?
Comment 7 Dimitar Kosev 2015-09-30 16:08:32 UTC
If you tell me how to do it I can try.
Comment 8 Michel Dänzer 2015-10-01 07:37:54 UTC
For getting a gdb backtrace, see http://wiki.x.org/wiki/Development/Documentation/ServerDebugging/ .

For bisecting, search for "git bisect howto".
Comment 9 Matt Turner 2015-10-06 19:12:29 UTC
https://bugs.gentoo.org/show_bug.cgi?id=554606#c11 (same commentor as comment #2 here) says that 1.17.1-r1 works and 1.17.2-r1 fails. In addition to the changes from 1.17.1 -> 1.17.2 (of which there are a few glamor commits), we also added this patch [1].

Attila, could you try plain xorg-server-1.17.2 (without the -r1)? That will let us determine whether the patch at [1] is at fault.

[1] https://gitweb.gentoo.org/repo/gentoo.git/tree/x11-base/xorg-server/files/xorg-server-1.17.2-uninit-clientsWritable.patch
Comment 10 Attila Tóth 2015-10-08 06:29:53 UTC
(In reply to Matt Turner from comment #9)
> https://bugs.gentoo.org/show_bug.cgi?id=554606#c11 (same commentor as
> comment #2 here) says that 1.17.1-r1 works and 1.17.2-r1 fails. In addition
> to the changes from 1.17.1 -> 1.17.2 (of which there are a few glamor
> commits), we also added this patch [1].
> 
> Attila, could you try plain xorg-server-1.17.2 (without the -r1)? That will
> let us determine whether the patch at [1] is at fault.
> 
> [1]
> https://gitweb.gentoo.org/repo/gentoo.git/tree/x11-base/xorg-server/files/
> xorg-server-1.17.2-uninit-clientsWritable.patch

I didn't have time to test yesterday. I hope I can spend some time on this issue during the weekend. Let me report back later.
According to the log attached I may have a different issue compared to Dimitar, because in my case Xorg cannot even detect my card and dies early during launch. I will attach my version of failing Xorg as well.

Thx: Dw.
Comment 11 Attila Tóth 2015-10-12 00:24:04 UTC
Created attachment 118828 [details]
working Xorg log file 1.17.1-r1
Comment 12 Attila Tóth 2015-10-12 00:24:38 UTC
Created attachment 118829 [details]
failing Xorg log file 1.17.2
Comment 13 Attila Tóth 2015-10-12 00:28:44 UTC
(In reply to Matt Turner from comment #9)
> https://bugs.gentoo.org/show_bug.cgi?id=554606#c11 (same commentor as
> comment #2 here) says that 1.17.1-r1 works and 1.17.2-r1 fails. In addition
> to the changes from 1.17.1 -> 1.17.2 (of which there are a few glamor
> commits), we also added this patch [1].
> 
> Attila, could you try plain xorg-server-1.17.2 (without the -r1)? That will
> let us determine whether the patch at [1] is at fault.
> 
> [1]
> https://gitweb.gentoo.org/repo/gentoo.git/tree/x11-base/xorg-server/files/
> xorg-server-1.17.2-uninit-clientsWritable.patch

It fails with 1.17.2. In my case Xorg dies early with "(EE) No devices detected". So this might be a different problem compared to Dimitar's.

Please note, that the working log contains this line after probing the card:
(WW) Falling back to old probe method for modesetting
(II) [KMS] Kernel modesetting enabled.

While failing version says:
(II) modeset(G0): using drv /dev/dri/card0
(EE) No devices detected.

Do I have a configuration problem?

Thanks: Dw.
Comment 14 Michel Dänzer 2015-10-13 09:47:23 UTC
(In reply to Attila Tóth from comment #13)
> It fails with 1.17.2. In my case Xorg dies early with "(EE) No devices
> detected". So this might be a different problem compared to Dimitar's.

Looks like it, please file your own report. Can you bisect?
Comment 15 Attila Tóth 2015-10-13 15:02:29 UTC
(In reply to Michel Dänzer from comment #14)
> (In reply to Attila Tóth from comment #13)
> > It fails with 1.17.2. In my case Xorg dies early with "(EE) No devices
> > detected". So this might be a different problem compared to Dimitar's.
> 
> Looks like it, please file your own report. Can you bisect?

I haven't lost my bisect virginity, yet. I do my first bisect and get back.
Comment 16 Dimitar Kosev 2015-10-31 08:55:00 UTC
Hello guys,

It seems this issue is now resolved. Yesterday I saw some new xorg-server packages with a fix for a crash because of xproto. I updated two systems to xorg-server 1.17.4. mesa 11.0.4, one with xproto 7.0.28 (the problematic one) and one with 7.0.27, both are so far working fine.
Comment 17 Matt Turner 2015-10-31 22:17:56 UTC
We believe this was due to the xserver not being compatible with the changes in xproto-7.0.28. xserver-1.17.4 is compatible.

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.