Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 466768 - x11-base/xorg-server - X crashes with a segfault - (EE) 2: linux-gate.so.1 (__kernel_rt_sigreturn+0x0) [0xffffe40c] while processing input events.
Summary: x11-base/xorg-server - X crashes with a segfault - (EE) 2: linux-gate.so.1 (_...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal with 1 vote (vote)
Assignee: Gentoo X packagers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-04-22 08:42 UTC by Raymond Jennings
Modified: 2013-08-19 13:41 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge --info (einfo.txt,5.29 KB, text/plain)
2013-04-22 08:43 UTC, Raymond Jennings
Details
crash log (Xorg.0.log.old,60.38 KB, text/plain)
2013-06-26 07:10 UTC, Raymond Jennings
Details
gdb output (gdb-out2.log,33.21 KB, text/plain)
2013-07-19 10:51 UTC, aditsu
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Raymond Jennings 2013-04-22 08:42:19 UTC
Finally figured out why my desktop keeps rebooting.

Checked the gdm logs and found evidence of a segfault.


Reproducible: Always
Comment 1 Raymond Jennings 2013-04-22 08:43:22 UTC
Created attachment 346260 [details]
emerge --info
Comment 2 Raymond Jennings 2013-04-22 08:51:27 UTC
backtrace in gdm log:

(EE) 
(EE) Backtrace:
(EE) 0: /usr/bin/X (xorg_backtrace+0x4a) [0x81de95a]
(EE) 1: /usr/bin/X (0x8048000+0x19a6c6) [0x81e26c6]
(EE) 2: /lib/libpthread.so.0 (0xb76ea000+0xfc10) [0xb76f9c10]
(EE) 3: /usr/bin/X (mieqProcessDeviceEvent+0x10f) [0x81bebff]
(EE) 4: /usr/bin/X (mieqProcessInputEvents+0x106) [0x81bee56]
(EE) 5: /usr/bin/X (ProcessInputEvents+0x15) [0x80c01a5]
(EE) 6: /usr/bin/X (xf86Wakeup+0x4ad) [0x80c0c7d]
(EE) 7: /usr/bin/X (WakeupHandler+0x6b) [0x80836bb]
(EE) 8: /usr/bin/X (WaitForSomething+0x193) [0x81dbdb3]
(EE) 9: /usr/bin/X (0x8048000+0x36cff) [0x807ecff]
(EE) 10: /usr/bin/X (0x8048000+0x24e85) [0x806ce85]
(EE) 11: /lib/libc.so.6 (__libc_start_main+0xf4) [0xb744a854]
(EE) 12: /usr/bin/X (0x8048000+0x25269) [0x806d269]
(EE) 
(EE) Segmentation fault at address 0xa8
Comment 3 Jeroen Roovers (RETIRED) gentoo-dev 2013-04-24 16:03:55 UTC
Why would an X crash cause a reboot (unless something more serious is going on)?

Please reopen this bug report when you have analysed the problem further and have attached more information.
Comment 4 Raymond Jennings 2013-04-24 17:03:02 UTC
Just the desktop, not the entire computer.  As in gdm catches the termination and restarts the display with a fresh login.

I said "reboot" as a figure of speech, sorry for the confusion.
Comment 5 Jeroen Roovers (RETIRED) gentoo-dev 2013-04-24 17:28:16 UTC
1) Please attach the relevant /var/log/Xorg.?.log to this bug report.
Comment 6 Raymond Jennings 2013-04-25 00:48:33 UTC
afraid it already rotated off of my system.

I'll reopen when it happens again.
Comment 7 Raymond Jennings 2013-06-26 07:10:45 UTC
Created attachment 351986 [details]
crash log
Comment 8 Raymond Jennings 2013-06-26 07:11:00 UTC
happened again
Comment 9 aditsu 2013-07-19 06:38:02 UTC
I'm having a similar problem, but it only seems to happen when using the touch screen. Here's my backtrace from Xorg.0.log.old:

[622368.754] (EE) Backtrace:
[622368.754] (EE) 0: /usr/bin/X (xorg_backtrace+0x34) [0x5960e4]
[622368.754] (EE) 1: /usr/bin/X (0x400000+0x199e99) [0x599e99]
[622368.754] (EE) 2: /lib64/libpthread.so.0 (0x7f68c33a5000+0x10bf0) [0x7f68c33b5bf0]
[622368.754] (EE) 3: /usr/bin/X (0x400000+0x5609b) [0x45609b]
[622368.755] (EE) 4: /usr/bin/X (0x400000+0x561e5) [0x4561e5]
[622368.755] (EE) 5: /usr/bin/X (0x400000+0x12156d) [0x52156d]
[622368.755] (EE) 6: /usr/bin/X (0x400000+0x121d3e) [0x521d3e]
[622368.755] (EE) 7: /usr/bin/X (0x400000+0x1222a0) [0x5222a0]
[622368.755] (EE) 8: /usr/bin/X (0x400000+0x1248f8) [0x5248f8]
[622368.755] (EE) 9: /usr/bin/X (0x400000+0x14828a) [0x54828a]
[622368.755] (EE) 10: /usr/bin/X (mieqProcessDeviceEvent+0x1b9) [0x577099]
[622368.755] (EE) 11: /usr/bin/X (0x400000+0x653ee) [0x4653ee]
[622368.755] (EE) 12: /usr/bin/X (0x400000+0x4b0cd) [0x44b0cd]
[622368.755] (EE) 13: /usr/bin/X (0x400000+0x4b48d) [0x44b48d]
[622368.755] (EE) 14: /usr/bin/X (ProcAllowEvents+0xab) [0x44b57b]
[622368.755] (EE) 15: /usr/bin/X (0x400000+0x3af1e) [0x43af1e]
[622368.755] (EE) 16: /usr/bin/X (0x400000+0x29964) [0x429964]
[622368.755] (EE) 17: /lib64/libc.so.6 (__libc_start_main+0xed) [0x7f68c205560d]
[622368.755] (EE) 18: /usr/bin/X (0x400000+0x29cad) [0x429cad]
[622368.755] (EE) 
[622368.755] (EE) Segmentation fault at address 0x88
[622368.755] (EE) 
Fatal server error:
[622368.755] (EE) Caught signal 11 (Segmentation fault). Server aborting

I recompiled xorg-server with FEATURES="nostrip" and -ggdb in CFLAGS and CXXFLAGS, but I'm still not getting more symbols in the backtrace, I'd appreciate some guidance.
Also, I was having these crashes with xorg-server-1.13.4, then I upgraded to 1.14.2 and nothing seemed to change. This backtrace is from 1.14.2.
Comment 10 Chí-Thanh Christopher Nguyễn gentoo-dev 2013-07-19 10:17:37 UTC
If you can, ssh into the computer and attach gdb to the X server. The stack trace that is dumped to Xorg.0.log is not always very informative.

http://www.x.org/wiki/Development/Documentation/ServerDebugging/
Comment 11 aditsu 2013-07-19 10:22:36 UTC
(In reply to Chí-Thanh Christopher Nguyễn from comment #10)
> If you can, ssh into the computer and attach gdb to the X server.

Thanks, I actually tried that, and this is what I got:

Program received signal SIGSEGV, Segmentation fault.
0x000000000045609b in xi2mask_isset_for_device (mask=0xa0, 
    dev=0x8173c0 <xi_all_devices>, event_type=21)
    at /var/tmp/portage/x11-base/xorg-server-1.14.2/work/xorg-server-1.14.2/dix/inpututils.c:1027
1027    /var/tmp/portage/x11-base/xorg-server-1.14.2/work/xorg-server-1.14.2/dix/inpututils.c: No such file or directory.
(gdb) 
Continuing.

Program received signal SIGABRT, Aborted.
0x00007f7b9b21ac15 in raise () from /lib64/libc.so.6
(gdb) 
Continuing.

Program terminated with signal SIGABRT, Aborted.
The program no longer exists.


It's possible that kdm restarted it, or maybe I need to add some options
Comment 12 Chí-Thanh Christopher Nguyễn gentoo-dev 2013-07-19 10:23:53 UTC
At the gdb prompt following SIGSEGV, enter
(gdb) bt
so that it outputs the stack trace.
Comment 13 aditsu 2013-07-19 10:25:36 UTC
(In reply to Chí-Thanh Christopher Nguyễn from comment #12)
> At the gdb prompt following SIGSEGV, enter
> (gdb) bt
> so that it outputs the stack trace.

That would probably work if the program still existed. But, continuing from that output:

The program no longer exists.
(gdb) bt
No stack.
(gdb) 
No stack.
(gdb) 
No stack.
(gdb) backtrace
No stack.
(gdb) 
No stack.
(gdb) 
No stack.
(gdb) quit
Comment 14 Chí-Thanh Christopher Nguyễn gentoo-dev 2013-07-19 10:27:14 UTC
At the first (gdb) prompt the program still exists, at the second it does not exist any more.
Comment 15 aditsu 2013-07-19 10:29:14 UTC
Does enter repeat the last command? That would be horrible, but would explain some things...
Comment 16 aditsu 2013-07-19 10:51:45 UTC
Created attachment 353636 [details]
gdb  output

Oh my, enter does repeat the last command, and that was the problem. Here's the gdb output including full backtrace.
Comment 17 Chí-Thanh Christopher Nguyễn gentoo-dev 2013-07-19 12:17:52 UTC
So this appears to be in touch code. Possibly one of the patches mentioned here
http://thread.gmane.org/gmane.comp.freedesktop.xorg.devel/36386
might help fix this problem. In particular
> Xi: if we delivered a TouchEnd to a passive grab, end it
looks related. The patches can all be found at:
http://cgit.freedesktop.org/~whot/xserver/log/?h=server-1.14-touch-fixes
Comment 18 Chí-Thanh Christopher Nguyễn gentoo-dev 2013-08-02 23:13:43 UTC
The touch fixes are now in xorg-server-1.14.2.901
Please test and reopen of the issue still exists with that version.
Comment 19 aditsu 2013-08-03 09:35:02 UTC
(In reply to Chí-Thanh Christopher Nguyễn from comment #18)
> The touch fixes are now in xorg-server-1.14.2.901
> Please test and reopen of the issue still exists with that version.

Thanks, I actually contacted the author and he confirmed those patches should fix the problem and advised me to get the latest code from master. I installed xorg-server-9999 and have been using it for about a week, no crashes so far. I'll also switch to 1.14.2.901 and test.
On the other hand, I think the OP is having a slightly different problem, but I guess that could have been fixed too.
Comment 20 aditsu 2013-08-19 13:36:32 UTC
Tested with xorg-server-1.14.2.901 for a few days, it's rock solid so far.
Comment 21 Chí-Thanh Christopher Nguyễn gentoo-dev 2013-08-19 13:41:56 UTC
Marking as fixed per comment 20.
Reporter: if you still see this problem with >=xorg-server-1.14.2.901, please reopen this bug.