Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 434860 - x11-drivers/xf86-video-intel-2.20.7 USE=-uxa - segmentation faults
Summary: x11-drivers/xf86-video-intel-2.20.7 USE=-uxa - segmentation faults
Status: RESOLVED OBSOLETE
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo X packagers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-09-13 04:23 UTC by Eugene Rosenzweig
Modified: 2012-09-19 13:44 UTC (History)
2 users (show)

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


Attachments
Xorg log for the 2.20.7 without uxa, contains segfault backtrace (Xorg.0.log.1,23.21 KB, text/plain)
2012-09-13 04:27 UTC, Eugene Rosenzweig
Details
Xorg log for the 2.20.7 without uxa, contains segfault backtrace, built with -ggdb and splitdebug (Xorg.0.log.old,23.21 KB, text/plain)
2012-09-13 15:25 UTC, Eugene Rosenzweig
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Eugene Rosenzweig 2012-09-13 04:23:36 UTC
I have had a lot of trouble in xorg on my dell inspiron over last six months or so with random segmentation faults (under certain gui operations). In the last couple of months they have disappeared but today after upgrading to 2.20.7 the consistent segfaults were back. Rolling back to 2.20.6 fixed the problems. That was with USE="dri glamor sna -uxa xvmc". Enabling uxa use flag, which is new to 2.20.7 has fixed the segmentation faults with 2.20.7 Originally I did not enable the uxa flag because I didn't know what it was and wikipedia-ing it said that UXA was deprecated in favour of SNA.

Reproducible: Always

Steps to Reproduce:
1. startx
2. start Opera

Actual Results:  
X crashes back to console


Portage 2.1.11.16 (default/linux/amd64/10.0, gcc-4.6.3, glibc-2.15-r2, 3.5.1-r3 x86_64)
=================================================================
System uname: Linux-3.5.1-r3-x86_64-Intel-R-_Core-TM-2_CPU_L7400_@_1.50GHz-with-gentoo-2.2
Timestamp of tree: Wed, 12 Sep 2012 12:30:01 +0000
app-shells/bash:          4.2_p37
dev-lang/python:          2.7.3-r2, 3.2.3-r1
dev-util/cmake:           2.8.8-r3
dev-util/pkgconfig:       0.27.1
sys-apps/baselayout:      2.2
sys-apps/openrc:          0.10.5
sys-apps/sandbox:         2.6
sys-devel/autoconf:       2.13, 2.69
sys-devel/automake:       1.9.6-r3, 1.11.6
sys-devel/binutils:       2.22.90
sys-devel/gcc:            4.6.3
sys-devel/gcc-config:     1.7.3
sys-devel/libtool:        2.4.2
sys-devel/make:           3.82-r3
sys-kernel/linux-headers: 3.5 (virtual/os-headers)
sys-libs/glibc:           2.15-r2
Repositories: gentoo x-portage-overlay
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=core2 -O2 -fomit-frame-pointer -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -pipe"
DISTDIR="/usr/portage/distfiles"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles news parallel-fetch protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
FFLAGS="-O2 -pipe"
LANG="en_AU.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LINGUAS="en"
MAKEOPTS="-j1"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/portage-overlay"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X alsa amd64 bzip2 dbus gpm idn ipv6 jpeg lzma mmx multilib nptl nptlonly pam sse sse2 sse3 ssl ssse3 threads threadsafe tiff truetype udev unicode xcb xml xorg zlib" ALSA_CARDS="snd-hda-intel" ALSA_PCM_PLUGINS="*" CURL_SSL="openssl" ELIBC="glibc" GRUB_PLATFORMS="pc" INPUT_DEVICES="keyboard mouse evdev synaptics" KERNEL="linux" LINGUAS="en" USERLAND="GNU" VIDEO_CARDS="intel fbdev i915 i965"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON
Comment 1 Eugene Rosenzweig 2012-09-13 04:27:02 UTC
Created attachment 323640 [details]
Xorg log for the 2.20.7 without uxa, contains segfault backtrace
Comment 2 Reinis Danne 2012-09-13 06:51:41 UTC
SNA has not got as much testing as UXA, but it is in active development and all the issues are quickly resolved if reported.

Please recompile xf86-video-intel with debugging symbols enabled (add -ggdb to CFLAGS; http://www.gentoo.org/proj/en/qa/backtraces.xml) and reproduce the segfault. Then using addr2line get line numbers (if they are not in the backtrace) for the backtrace in your new log file (give it the numbers after + sign in backtrace), e.g. if the current backtrace was with debugging symbols enabled:
$ addr2line -e /usr/lib64/xorg/modules/drivers/intel_drv.so 0x456e9 0x8329c 0x7e5a1 0x57802 0x45321

If you have splitdebug feature enabled then change
/usr/lib64/xorg/modules/drivers/intel_drv.so
for
/usr/lib64/debug/usr/lib64/xorg/modules/drivers/intel_drv.so.debug
in the above command.

Then post the Xorg.0.log and the addr2line command you used together with its output.
Comment 3 Reinis Danne 2012-09-13 06:58:33 UTC
Also add information about the intel card and windows manager you are using.
Comment 4 Eugene Rosenzweig 2012-09-13 15:05:55 UTC
Windows manager is:
x11-wm/jwm-2.1.0  USE="jpeg truetype -bidi -debug -png -xinerama -xpm"

The graphics subsystem on the laptop (relevant lspci -nnk output):
00:00.0 Host bridge [0600]: Intel Corporation Mobile 945GM/PM/GMS, 943/940GML and 945GT Express Memory Controller Hub [8086:27a0] (rev 03)
        Subsystem: Dell Device [1028:01bd]
        Kernel driver in use: agpgart-intel
00:02.0 VGA compatible controller [0300]: Intel Corporation Mobile 945GM/GMS, 943/940GML Express Integrated Graphics Controller [8086:27a2] (rev 03)
        Subsystem: Dell Device [1028:01bd]
        Kernel driver in use: i915
00:02.1 Display controller [0380]: Intel Corporation Mobile 945GM/GMS/GME, 943/940GML Express Integrated Graphics Controller [8086:27a6] (rev 03)
        Subsystem: Dell Device [1028:01bd]

or from lshw:
        *-display:0
             description: VGA compatible controller
             product: Mobile 945GM/GMS, 943/940GML Express Integrated Graphics Controller
             vendor: Intel Corporation
             physical id: 2
             bus info: pci@0000:00:02.0
             version: 03
             width: 32 bits
             clock: 33MHz
             capabilities: msi pm vga_controller bus_master cap_list rom
             configuration: driver=i915 latency=0
             resources: irq:16 memory:eff00000-eff7ffff ioport:eff8(size=8) memory:d0000000-dfffffff memory:efec0000-efefffff
        *-display:1 UNCLAIMED
             description: Display controller
             product: Mobile 945GM/GMS/GME, 943/940GML Express Integrated Graphics Controller
             vendor: Intel Corporation
             physical id: 2.1
             bus info: pci@0000:00:02.1
             version: 03
             width: 32 bits
             clock: 33MHz
             capabilities: pm bus_master cap_list
             configuration: latency=0
             resources: memory:eff80000-efffffff
Comment 5 Eugene Rosenzweig 2012-09-13 15:25:39 UTC
Created attachment 323674 [details]
Xorg log for the 2.20.7 without uxa, contains segfault backtrace, built with -ggdb and splitdebug

addr2line -e /usr/lib64/debug/usr/lib64/xorg/modules/drivers/intel_drv.so.debug 0x45321 0x57802 0x7e5a1 0x8329c 0x456e9
/var/tmp/portage/x11-drivers/xf86-video-intel-2.20.7/work/xf86-video-intel-2.20.7/src/sna/sna_composite.c:991
/var/tmp/portage/x11-drivers/xf86-video-intel-2.20.7/work/xf86-video-intel-2.20.7/src/sna/sna_render.c:1366
/var/tmp/portage/x11-drivers/xf86-video-intel-2.20.7/work/xf86-video-intel-2.20.7/src/sna/gen3_render.c:2417
/var/tmp/portage/x11-drivers/xf86-video-intel-2.20.7/work/xf86-video-intel-2.20.7/src/sna/gen3_render.c:2869
/var/tmp/portage/x11-drivers/xf86-video-intel-2.20.7/work/xf86-video-intel-2.20.7/src/sna/sna_composite.c:543
Comment 6 Reinis Danne 2012-09-13 16:12:20 UTC
Did you restart X after recompiling intel driver and before reproducing the crash? Please doublecheck that addresses in your trace are from the recompiled driver.

Do you have any local patches applied to xf86-video-intel?
Comment 7 Eugene Rosenzweig 2012-09-14 06:08:18 UTC
Did it again today, rebooted after making the debug emerge and yes, the output seems to be correct, same addresses as I posted last time. No local patches applied to the package.
Comment 8 Reinis Danne 2012-09-14 06:57:06 UTC
Well, this trace seems to be incorrect since the line numbers doesn't make sense (by upstream). Try running X under gdb and get backtrace. You can connect to your computer from another one trough ssh and attach to running X:
# gdb attach $(ps -C Xorg -o pid=)
gdb stops the running process when attaching so you have to continue:
(gdb) continue
Reproduce the crash and get backtrace:
(gdb) bt full
You might need to copy more than one screen of gdb output to get all intel driver related info.

Or probably easier is to get core dump and from that backtrace as described here: http://www.gentoo.org/proj/en/qa/backtraces.xml
Comment 9 Reinis Danne 2012-09-14 08:29:07 UTC
Also please attach here full build log for xf86-video-intel.

Upstream asked for full debug information. To get that change xf86-video-intel ebuild locally to add debug use flag:
-IUSE="glamor +sna uxa xvmc"
+IUSE="debug glamor +sna uxa xvmc"

and in src_configure to use it:
 
 src_configure() {
 	XORG_CONFIGURE_OPTIONS=(
+		$(use_enable debug debug full)
 		$(use_enable dri)
 		$(use_enable glamor)
 		$(use_enable sna)

and then compile with debug enabled:
USE="debug" emerge -1 xf86-video-intel

Then reproduce the crash and send compressed Xorg log to chris at chris-wilson.co.uk

Note: debug flag will make quite big Xorg log files so you don't want to keep it enabled normally.
Comment 10 Eugene Rosenzweig 2012-09-14 12:21:02 UTC
Sent full Xorg log to upstream
Comment 11 Reinis Danne 2012-09-14 13:17:21 UTC
Fixed in
http://cgit.freedesktop.org/xorg/driver/xf86-video-intel/commit/?id=8e9d64203428b344433ac8f86dc1f06d2c32529a

Will be in next release. If you want to test you can try to apply the patch locally.
Comment 12 Eugene Rosenzweig 2012-09-19 13:44:41 UTC
The patch fixes the particular crash and there is a new driver version out with the patch incorporated. I am still experiencing crashes with the new driver in same configuration, will lodge a separate bug report?