Crash in memcpy () when starting to play videos (Intel 915GM)

Bug #220019 reported by Milan Bouchet-Valat
This bug report is a duplicate of:  Bug #212799: [hardy] Xv causes SIGSEGV in memcpy(). Edit Remove
20
Affects Status Importance Assigned to Milestone
xf86-video-intel
Fix Released
Unknown
xorg (Ubuntu)
Invalid
Undecided
Unassigned
Hardy
Invalid
Undecided
Unassigned
Intrepid
Invalid
Undecided
Unassigned
xserver-xorg-video-intel (Ubuntu)
Fix Released
High
Unassigned
Hardy
Confirmed
Undecided
Unassigned
Intrepid
Fix Released
High
Unassigned

Bug Description

Binary package hint: xserver-xorg

This bug is occurring in Hardy, xserver-xorg version 1:7.3+10ubuntu10, regardless of compiz being activated or not, with Totem as well as with MPlayer. I have an Intel 915GM card using the i810 server.

Randomly, opening a video makes X crash before any image is displayed. X restarts and I'm back to GDM. No specific video will trigger this, and later I'll be able to play the same video file without trouble. I could notice the crash is almost always occurring when Kdenlive (video editing app) has been running for a while; but else the bug can happen at anytime, in an unpredictable way.

Attached are the different log files, and here's the most relevant part of Xorg.0.log.old (that of the crash):
Backtrace:
0: /usr/bin/X(xf86SigHandler+0x7e) [0x80c780e]
1: [0xb7f9f420]
2: /usr/bin/X [0x80da805]
3: /usr/lib/xorg/modules/extensions//libextmod.so(XvdiPutImage+0x178) [0xb7c08608]
4: /usr/lib/xorg/modules/extensions//libextmod.so [0xb7c0b476]
5: /usr/bin/X [0x81506de]
6: /usr/bin/X(Dispatch+0x2cf) [0x808d8df]
7: /usr/bin/X(main+0x48b) [0x807471b]
8: /lib/tls/i686/cmov/libc.so.6(__libc_start_main+0xe0) [0xb7d31450]
9: /usr/bin/X(FontFileCompleteXLFD+0x201) [0x8073a91]

Fatal server error:
Caught signal 11. Server aborting

Revision history for this message
Milan Bouchet-Valat (nalimilan) wrote :
Revision history for this message
Milan Bouchet-Valat (nalimilan) wrote :
Revision history for this message
Milan Bouchet-Valat (nalimilan) wrote :
Revision history for this message
Milan Bouchet-Valat (nalimilan) wrote :
Revision history for this message
Milan Bouchet-Valat (nalimilan) wrote :
Revision history for this message
Herwig Stuetz (hungryhugo) wrote :

Just want to say "me too" only without kdenlive.

Revision history for this message
ejandi (ejandi-gmail) wrote :

xserver crashes subsequently when using my system. sometimes when i am about to play videos or music files. sometimes when just doing something with the system like copying a file. it freezes. not only that i can't even logout when it happens i have to power down the system. the worst is that it occured just now is about 15mins. i use an intel graphics card 950.

Revision history for this message
Milan Bouchet-Valat (nalimilan) wrote :

ejandi: how can you be sure this is the same bug? The symptoms are really different. Have you looked at Xorg.0.log?

Revision history for this message
Vincent Dupont (vincent-touffi) wrote :

I have the same problem with kde and kaffeine when I am watching TV. X crashes when I reduce a window.

Revision history for this message
Milan Bouchet-Valat (nalimilan) wrote :

Please, ejandi and Vincent, have a look at your /var/log/Xorg.0.log.old file and search for a backtrace to see if its the same as mine. Else you're not sure of anything.

I've been able to get a trace using gdb. Though I cannot be sure it is for the same bug (the crash occurred as usual when starting a video), but this will surely help. The crash occurs in the intel driver and is from libc6 memcpy (). Is that compatible with the backtrace I found in Xorg.0.log.old?

Revision history for this message
Vincent Dupont (vincent-touffi) wrote : Re: X Intel server random crash in memcpy () when starting to play videos (Intel 915GM)

Here is the backtrace I found in my /var/log/Xorg.0.log.old :

Backtrace:
0: /usr/bin/X(xf86SigHandler+0x7e) [0x80c780e]
1: [0xb7f0c420]
2: /usr/bin/X [0x80da805]
3: /usr/lib/xorg/modules/extensions//libextmod.so(XvdiPutImage+0x178) [0xb7b73608]
4: /usr/lib/xorg/modules/extensions//libextmod.so [0xb7b76476]
5: /usr/bin/X [0x81506de]
6: /usr/bin/X(Dispatch+0x2cf) [0x808d8df]
7: /usr/bin/X(main+0x48b) [0x807471b]
8: /lib/tls/i686/cmov/libc.so.6(__libc_start_main+0xe0) [0xb7c9c450]
9: /usr/bin/X(FontFileCompleteXLFD+0x201) [0x8073a91]

Fatal server error:
Caught signal 11. Server aborting

Revision history for this message
Milan Bouchet-Valat (nalimilan) wrote :

Looks like it's the same bug... Welcome to the club!

Revision history for this message
Timo Aaltonen (tjaalton) wrote :

no need to keep open for xorg.

Changed in xorg:
status: New → Invalid
Bryce Harrington (bryce)
Changed in xserver-xorg-video-intel:
importance: Undecided → High
status: New → Triaged
Bryce Harrington (bryce)
Changed in xserver-xorg-video-intel:
importance: Undecided → Unknown
status: New → Unknown
Changed in xserver-xorg-video-intel:
status: Unknown → Confirmed
Revision history for this message
Bryce Harrington (bryce) wrote :

Hi, I've reported this bug upstream here, could you please subscribe to this bug in case they need more information?

 https://bugs.freedesktop.org/show_bug.cgi?id=15925

Upstream is recommending trying with the 2.3.1 -intel driver.

Revision history for this message
Milan Bouchet-Valat (nalimilan) wrote :

It appears to have been fixed upstream, as far as I can tell. Is there any chance we get this in Hardy at some time? (We cannot be sure, be it may affect a fair number of users - for me, no problem now.)

Vincent: could you install the Debian package from http://packages.debian.org/sid/xserver-xorg-video-intel and see whether it fixes your bug too?

Revision history for this message
Vincent Dupont (vincent-touffi) wrote :

I have installed the Debian package and it fixes the bug too.

Changed in xserver-xorg-video-intel:
status: Confirmed → Fix Released
Revision history for this message
unggnu (unggnu) wrote :

Would either of you mind trying out the 'rac763634' git driver at this page: http://people.ubuntu.com/~bryce/bisect/ ?

If that version works, please try some of the older ones to see where it switches from working to failing; this will help us in narrowing down at what point it started working.

Changed in xserver-xorg-video-intel:
status: Triaged → Incomplete
Revision history for this message
unggnu (unggnu) wrote :

Now I am able to reproduce it myself. I had this some time ago but I couldn't nail it down and it was very rare while it seems to happen mostly with one video.

Xorg.0.log.old extract:
[...]
Backtrace:
0: /usr/bin/X(xf86SigHandler+0x7e) [0x80c780e]
1: [0xffffe400]
2: /usr/bin/X [0x80da805]
3: /usr/lib/xorg/modules/extensions//libextmod.so(XvdiPutImage+0x178) [0xb7c33608]
4: /usr/lib/xorg/modules/extensions//libextmod.so [0xb7c36476]
5: /usr/bin/X [0x81506de]
6: /usr/bin/X(Dispatch+0x2cf) [0x808d8df]
7: /usr/bin/X(main+0x48b) [0x807471b]
8: /lib/tls/i686/cmov/libc.so.6(__libc_start_main+0xe0) [0xb7d5c450]
9: /usr/bin/X(FontFileCompleteXLFD+0x201) [0x8073a91]

I guess it has something to do with higher resolution videos but I have to made some more tests.
To confirm it just download the new, free and great video Big Buck Bunny in 1280x800 http://blender.waag.org/big_buck_bunny_720p_stereo.ogg.torrent . Everytime I open this, close it and open a different video afterwards I got this crash. If I open the same video again X doesn't crash. I have tested it in Totem and VLC.
If you don't have any other video just download the 854x640 resolution version http://blender.waag.org/big_buck_bunny_480p_stereo.ogg.torrent . If I use this version X doesn't crash until I open the higher resolution one and then the 854x640 again.
That's why I am think the issue is video resolution related.

I have tried to use the bisect versions but with rac763634 and rf4cfc98a vesa is used instead and my screen is garbage. I am going to check it with manual set -intel driver soon. I have tested the current Debian SID driver which works fine but it is no proof since it uses Textured video instead of overlay.

Revision history for this message
unggnu (unggnu) wrote :

The bisect driver works when I specify -intel manually. All driver I have tested haven't this problem but they all seem to use textured video. The first ones even doesn't work under compiz and the video output is garbage.
Is there any possibility to disable textured video in the upstream driver without changing source code or just use overlay?

Changed in xserver-xorg-video-intel:
status: Incomplete → In Progress
Revision history for this message
unggnu (unggnu) wrote :

It definitely has something to do with video resolution. I have experimented a little bit with FFMPEG and it seems that every video with a resolution higher than 1024x512 crashes on my system if another video is opened afterwards. But if I change the both axis it works up to 512x1040. If one size is decreased considerable the other could be increased but I haven't found a system.
Btw. even the 1920x1080 video plays fine except of performance issues and could be reopened without problems until another video is started

Revision history for this message
unggnu (unggnu) wrote :

It is possible to use Overlay video with newer driver through mplayer -vo xv:port=<n> where <n> is the port number you get from xvinfo for the video overlay adaptor.
With this I was able to test bisect and it seems that all versions have the same problem except of the last one rac763634. But it doesn't look like that this patch could make it into Hardy since it based on code which was later added to the Intel driver.

Revision history for this message
Karl Frisk (karl-frisk) wrote :

i also experience this bug with an 945 chipset.

it is a very annoying bug because with the vlc-mozilla plugin it can cause crashes just because you surf the wrong webpage...

when will there be a fix for ubuntu? why is the 2.3.1 driver not in the hardy-repos?

Revision history for this message
unggnu (unggnu) wrote :

This issue should be fixed in Intrepid with Intel driver 2.3.1. For Hardy there is an unofficial package http://people.ubuntu.com/~bryce/Testing/intel/hardy-i386/xserver-xorg-video-intel_2.3.1-1ubuntu1~bwh3_i386.deb (AMD64 http://people.ubuntu.com/~bryce/Testing/intel/hardy-amd64/xserver-xorg-video-intel_2.3.1-1ubuntu1~bwh3_amd64.deb) but I guess that it doesn't make it a and SRU (https://wiki.ubuntu.com/StableReleaseUpdates).

If you want to try the new -intel driver for Hardy you have to remove the old i810 driver and then install the new one.
sudo apt-get remove xserver-xorg-video-i810 xserver-xorg-video-all

If you want to reset everything do the follow commands.
sudo apt-get remove xserver-xorg-video-intel
sudo apt-get install xserver-xorg-video-all

Revision history for this message
unggnu (unggnu) wrote :

Ok, marking as fixed released since the fix was confirmed in a duplicate. Feel free to open it again if it still happens with current Intrepid. I guess there will be no fix for Hardy but there is a workaround with the new driver package.

Changed in xserver-xorg-video-intel:
status: In Progress → Fix Released
Revision history for this message
Milan Bouchet-Valat (nalimilan) wrote :

IMHO it could be good to get this in Hardy at some time, this but is serious for users with this card. I'm not very concerned for myself, but LTS could justify that.

Revision history for this message
unggnu (unggnu) wrote :

The developers have to decide this but I personally didn't run in this problem consciously until the Big Buck Bunny project and I have watched many videos. Since it only happens with very high resolution videos (much higher than DVD) and only if you watch more than one video at a session there is no sever impact imho and there is an easy workaround.
The commit is very huge. Maybe a simple fix could be extracted but I guess there are things that are more important to spend time one.
Of course if someone could create a simple fix it wouldn't hurt.
Just for the records https://wiki.ubuntu.com/StableReleaseUpdates .

Revision history for this message
Rowd (rodmg4) wrote :

The problem persist for me with the intrepid intel driver, but only when viewing a flash video (flv) file in full screen after seeing a high resolution video in full screen.
Only the 2.3.1 driver form Debian apparently fixes the problem, but the performance is very slow with compositing enabled, because this driver uses textured video, I think...

I tried using overlay video with the Debian driver trough mplayer, and it had the same problem with the flash video.

Maybe the bug is not yet completely fixed.

(sorry about my bad English, I'm not a native speaker...)

Revision history for this message
unggnu (unggnu) wrote :

@Rowd
I guess your issue is a different one so I would create a new bug report. Please attach your /var/log/Xorg.0.log there and try to get a full backtrace like described in this howto https://wiki.ubuntu.com/X/Backtracing.
Are you sure that you had the correct adaptor number while testing Overlay with mplayer? If you use the wrong one mplayer normally uses textured video with the Debian Sid driver. An easy check is to enabling compiz, open the video and then press shift +alt + cursor up. If the video is scaled down texture video is used. If you only see a part of the video in the small player overlay is used.

Revision history for this message
Milan Bouchet-Valat (nalimilan) wrote :

I (and others) got this crash simply watching videos in Firefox, not with very HD movies.

Revision history for this message
unggnu (unggnu) wrote :

A link to a site which causes this problem would be great. Marking as confirmed for now. Maybe one of the devs can mark it fixed released for Intrepid and confirmed for Hardy.

Changed in xserver-xorg-video-intel:
status: Fix Released → Confirmed
Bryce Harrington (bryce)
Changed in xorg:
status: New → Invalid
Changed in xserver-xorg-video-intel:
status: Confirmed → Fix Released
status: New → Confirmed
Revision history for this message
Bryce Harrington (bryce) wrote :

Agreed with unggnu's comment #26 - large diffs are less likely to be accepted by the SRU team, but I've left the Hardy task as Confirmed in case someone would like to do it. A minimal patch would need to be extracted and tested to ensure it fixes the issue. Unggnu suspected that it was fixed by commit f425181695b1b3864373e1919cf651229f19fa69.

Alternatively (and perhaps more effectively), you may wish to simply request a backport of the driver - see https://help.ubuntu.com/community/UbuntuBackports#How%20to%20request%20new%20packages

Revision history for this message
NeLaS (organelas) wrote :

I'm having the same issue. I can play any video files, but whenever I play a PAL format file (720x576, 25fps, quicktimeDV, OpenMovieEditor export), the next video crashes the X server (tried with avi uncompressed, avi xvid and mov). I tested the buckbunny movie (1280 x 720, 24fps, theora) and It also sets X to crash whenever I try to play another video afterwards, except the PAL file above (both videos work after each other)... weird.

Messing with the framerate of other movies changed nothing.

I uploaded a video sample (PAL, quicktimeDV), in case you want to test it http://organelas.googlepages.com/mo.dv (1.4mb)

Some of my info
Hardy, 2.6.24-19-rt

lspci:
Intel Corporation Mobile 945GM/GMS/GME, 943/940GML Express Integrated Graphics Controller (rev 03)

Xorg.0.log.old:
Backtrace:
0: /usr/bin/X(xf86SigHandler+0x7e) [0x80c780e]
1: [0xb7f27420]
2: /usr/bin/X [0x80da805]
3: /usr/lib/xorg/modules/extensions//libextmod.so(XvdiPutImage+0x178) [0xb7b91608]
4: /usr/lib/xorg/modules/extensions//libextmod.so [0xb7b94476]
5: /usr/bin/X [0x81506ee]
6: /usr/bin/X(Dispatch+0x2cf) [0x808d8df]
7: /usr/bin/X(main+0x48b) [0x807471b]
8: /lib/tls/i686/cmov/libc.so.6(__libc_start_main+0xe0) [0xb7cba450]
9: /usr/bin/X(FontFileCompleteXLFD+0x201) [0x8073a91]

Fatal server error:
Caught signal 11. Server aborting

Revision history for this message
unggnu (unggnu) wrote :

Did you try the new driver from post 23?

Revision history for this message
NeLaS (organelas) wrote :

Hey unggnu, I didn't have time to install the new driver yesterday.

I just did and it solves the problem!

Revision history for this message
Alan Pope 🍺🐧🐱 🦄 (popey) wrote :

I installed the new driver on my AMD64 machine and now can't get Miro to crash in the way I described in bug #223579.

Works for me.

Revision history for this message
unggnu (unggnu) wrote :

It looks like that the potential fix for Bug 212799 also fixes this problem so marking as a duplicate.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.