Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 277627 - =media-video/mplayer-1.0_rc2_p20090731 and x11-drivers/nvidia-drivers segfaults
Summary: =media-video/mplayer-1.0_rc2_p20090731 and x11-drivers/nvidia-drivers segfaults
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Doug Goldstein (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-07-13 10:02 UTC by Alex Efros
Modified: 2012-06-19 04:05 UTC (History)
3 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alex Efros 2009-07-13 10:02:40 UTC
After updating nvidia-drivers from 180.29 to 180.60 mplayer start crashing:
mplayer[14669]: segfault at 6eecfef8 ip b75572cc sp bfffd7d0 error 4 in libGL.so.180.60[b751d000+8d000]

As workaround, this will fix issue:
# eselect opengl set xorg-x11

Re-emerging mplayer doesn't helps (I hasn't tried to emerge it without "opengl" USE-flag - that may be another workaround).

I'm using hardened, but I don't think this issue has anything with it - I've tried to relax paxctl on mplayer and chpax on libGL.so.180.60 without any effect, previous nvidia-drivers works just fine, and there nothing from grsec/pax in kernel logs when mplayer dies.

That may or may not be important: I'm building mplayer with "custom-cflags" USE-flag because without it mplayer fail to build on my system.

Reproducible: Always

Steps to Reproduce:
1. emerge =media-video/mplayer-1.0_rc2_p20090322 =x11-drivers/nvidia-drivers-180.60
2. eselect opengl set nvidia
3. mplayer somefile.avi

Actual Results:  
mplayer crash

Expected Results:  
mplayer shouldn' crash :)

Portage 2.1.6.13 (hardened/x86, gcc-3.4.6, glibc-2.9_p20081201-r2, 2.6.28-hardened-r9 i686)
=================================================================
System uname: Linux-2.6.28-hardened-r9-i686-Intel-R-_Core-TM-2_CPU_6600_@_2.40GHz-with-glibc2.3.2
Timestamp of tree: Sun, 12 Jul 2009 21:30:01 +0000
app-shells/bash:     3.2_p39
dev-java/java-config: 2.1.8-r1
dev-lang/python:     2.5.4-r3
sys-apps/baselayout: 1.12.11.1
sys-apps/sandbox:    1.6-r2
sys-devel/autoconf:  2.13, 2.63
sys-devel/automake:  1.5, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.2
sys-devel/binutils:  2.18-r3
sys-devel/gcc-config: 1.4.1
sys-devel/libtool:   1.5.26
virtual/os-headers:  2.6.27-r2
ACCEPT_KEYWORDS="x86"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-march=prescott -O2 -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /service /usr/inferno/keydb /usr/inferno/lib /usr/inferno/services /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/config /var/log /var/qmail/alias /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/udev/rules.d"
CXXFLAGS="-march=prescott -O2 -pipe"
DISTDIR="/usr/portage-distfiles"
EMERGE_DEFAULT_OPTS="--with-bdeps=y"
FEATURES="distlocks fixpackages parallel-fetch protect-owned sandbox sfperms strict unmerge-orphans userfetch userpriv usersandbox"
GENTOO_MIRRORS="http://ftp.lug.ro/gentoo/ http://mirror.qubenet.net/mirror/gentoo/"
LANG="ru_RU.UTF-8"
LDFLAGS="-Wl,-O1"
LINGUAS="en ru"
MAKEOPTS="-j3"
PKGDIR="/usr/portage-packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/portage/local/layman/powerman /usr/portage/local/layman/sunrise /usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X Xaw3d a52 aac acpi aim alsa apache2 arts asf avi bash-completion berkdb bitmap-fonts bzip2 cdr cracklib crypt cscope curl dbus dga divx4linux dlloader dts dvd dvdr dvdread encode fastcgi ffmpeg flac flash gd gdbm gif gnutls gpgme gtk gtk2 hardened hddtemp icq idn imagemagick imap imlib irc jabber javascript jpeg kdeenablefinal lm_sensors lzo mad mailbox mbox midi mmx mng motif mp3 mpeg msn mysql ncurses nls nptl nptlonly ogg opengl oss pam pcre perl pic png pwdb qt quicktime rcc readline rss rtc samba sdl spell sse sse2 ssl ssse3 svg sysfs tcltk tcpd tiff truetype truetype-fonts type1-fonts unicode urandom vim-pager vim-syntax vim-with-x vorbis win32codecs x86 xinetd xorg xv xvid yahoo zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1 	emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m 	maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="     log_config vhost_alias     autoindex alias rewrite dir deflate filter mime negotiation     auth_basic authn_file authz_host authz_user authz_groupfile     cgi actions headers env setenvif     " ELIBC="glibc" INPUT_DEVICES="keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en ru" LIRC_DEVICES="serial" USERLAND="GNU" VIDEO_CARDS="vesa fbdev nv nvidia"
Unset:  CPPFLAGS, CTARGET, FFLAGS, INSTALL_MASK, LC_ALL, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Samuli Suominen (RETIRED) gentoo-dev 2009-08-03 21:10:00 UTC
Try 20090731 with more recent nvidia drivers.
Comment 2 Alex Efros 2009-08-03 23:06:21 UTC
I've tried media-video/mplayer-1.0_rc2_p20090731 with both latest stable (x11-drivers/nvidia-drivers-180.60) and unstable beta (x11-drivers/nvidia-drivers-190.18). No luck - still got segfault:

kern.info: mplayer[7971]: segfault at 2a269598 ip 550232cc sp 5ffd67f0 error 4 in libGL.so.180.60[54fe9000+8d000]
kern.info: mplayer[5085]: segfault at 2da09598 ip 52a3830c sp 5eeb4d50 error 4 in libGL.so.190.18[52a0f000+93000]

Both still works ok with `eselect opengl set xorg-x11`.
Comment 3 Samuli Suominen (RETIRED) gentoo-dev 2009-10-26 23:44:34 UTC
Please try, mplayer-1.0_rc4_p20091026.
Comment 4 Alex Efros 2009-10-27 11:56:50 UTC
Just tried media-video/mplayer-1.0_rc4_p20091026 - no luck:
kern.info: mplayer[23766]: segfault at 27011590 ip 4e0ea2cc sp 5d871bc0 error 4 in libGL.so.180.60[4e0b0000+8d000]
kern.info: mplayer[23868]: segfault at 6eec3590 ip b6b122cc sp bfffe3c0 error 4 in libGL.so.180.60[b6ad8000+8d000]
kern.info: mplayer[23942]: segfault at 225c1590 ip 4bd4a2cc sp 58ae2790 error 4 in libGL.so.180.60[4bd10000+8d000]
Comment 5 Doug Goldstein (RETIRED) gentoo-dev 2009-11-03 03:47:38 UTC
please attach the output of emerge -pv mplayer
Comment 6 Alex Efros 2009-11-03 12:26:48 UTC
home ~ # ACCEPT_KEYWORDS=~x86 emerge -pv mplayer

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild     U ] media-libs/x264-0.0.20091021 [0.0.20081006] USE="pic%* threads -debug" 0 kB
[ebuild     U ] media-video/mplayer-1.0_rc4_p20091026-r1 [1.0_rc2_p20090731] USE="X a52 aac alsa ass cddb cdio dga dirac dts dv dvd dvdnav enca encode faac faad gif iconv jpeg live lzo mad mmx mng mp3 network opengl osdmenu oss png quicktime rar real rtc samba schroedinger sdl shm speex sse sse2 ssse3 theora toolame%* tremor truetype twolame%* unicode vorbis win32codecs x264 xscreensaver xv xvid -3dnow -3dnowext -aalib (-altivec) -bidi -bindist -bl -bs2b% -cdparanoia -cpudetection -custom-cpuopts -debug -directfb -doc -dvb -dxr3 -esd -fbcon -ftp -ggi -gmplayer -ipv6 -jack -joystick -ladspa -libcaca -lirc -md5sum -mmxext -nas -nut% -openal -opencore-amr% -pnm -pulseaudio -pvr -radio -svga -teletext -tga -v4l -v4l2 (-vdpau) -vidix -xanim -xinerama -xvmc -zoran (-custom-cflags%*) (-mp2%*)" VIDEO_CARDS="-mga (-nvidia) -s3virge -tdfx (-vesa%*)" 0 kB

Total: 2 packages (2 upgrades), Size of downloads: 0 kB
Comment 7 Doug Goldstein (RETIRED) gentoo-dev 2009-11-28 04:53:39 UTC
Have you tried the upgrade as requested?
Comment 8 Alex Efros 2009-11-29 12:28:46 UTC
(In reply to comment #7)
> Have you tried the upgrade as requested?
> 

As I said in comment #4 I've tried that upgrade. Or you speaking about something else?
Comment 9 Alex Efros 2009-11-29 14:57:23 UTC
btw, there one more workaround related to this issue:
while mplayer (and things like glxgears) just segfaults when opengl set to nvidia,
the vmware need opengl set to nvidia to support 3D acceleration.

this small script will help to have both opengl set to xorg-x11 (to keep
mplayer working) and 3D acceleration in vmware:


$ cat ~/bin/vmware 
#!/bin/bash
export opengl_prev=$(eselect opengl list | grep '*' | awk '{print $2}')
if [ "x$opengl_prev" != "xnvidia" ]; then
    sudo eselect opengl set nvidia
    bash -c '
        until pidof vmware-unity-helper &>/dev/null; do sleep 1; done
        sudo eselect opengl set $opengl_prev
        ' &
fi
exec /opt/vmware/workstation/bin/vmware "$@"


You'll also need to allow eselect executed without password by user with sudo,
so append these lines (with your username) to sudo configuration:
# visudo
powerman ALL= NOPASSWD: /usr/bin/eselect opengl set nvidia
powerman ALL= NOPASSWD: /usr/bin/eselect opengl set xorg-x11
Comment 10 Doug Goldstein (RETIRED) gentoo-dev 2012-06-19 04:05:03 UTC
This issue actually ties back to the X11 / mesa OpenGL headers differing from the Khornos group spec which the NVIDIA drivers actually conform to.

Newer versions of mesa do a better job but not 100%. The mplayer guys have added some work arounds as well.

Please retest and reopen if it still is bad.