Bug 57323 - libva-intel-driver-1.0.19 display corruption
Summary: libva-intel-driver-1.0.19 display corruption
Status: RESOLVED FIXED
Alias: None
Product: libva
Classification: Unclassified
Component: intel (show other bugs)
Version: unspecified
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: ykzhao
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-11-20 13:58 UTC by zaverel
Modified: 2012-12-28 01:14 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
Xorg.0.log (39.86 KB, text/plain)
2012-11-23 13:22 UTC, zaverel
Details
sample from vdr recording (1.60 MB, text/plain)
2012-11-23 13:30 UTC, zaverel
Details
libva-1.1.0.patch (2.28 KB, patch)
2012-12-13 14:46 UTC, zaverel
Details | Splinter Review

Description zaverel 2012-11-20 13:58:30 UTC
Hello,

with latest libva-intel-driver-1.0.19 video display is not good

http://imageshack.us/photo/my-images/132/bugvaapi.png/

This with mplayer-vaapi , xbmc-vaapi  and xine-lib-vaapi

With previously libva-intel-driver-1.0.18-r1 display is good for all three softwares.




Intel Core i3 3220T (Ivy Bridge hd graphics 2500)
kernel 3.6.6-gentoo
libva-1.1.0
xf86-video-intel-9999 (latest cvs)
libdrm-2.4.40
ffmpeg-1.0



 vainfo
libva info: VA-API version 0.33.0
libva info: va_getDriverName() returns 0
libva info: Trying to open /usr/lib64/va/drivers/i965_drv_video.so
libva info: Found init function __vaDriverInit_0_33
libva info: va_openDriver() returns 0
vainfo: VA-API version: 0.33 (libva 1.1.0)
vainfo: Driver version: Intel i965 driver - 1.0.18
vainfo: Supported profile and entrypoints
      VAProfileMPEG2Simple            : VAEntrypointVLD
      VAProfileMPEG2Main              : VAEntrypointVLD
      VAProfileH264Baseline           : VAEntrypointVLD
      VAProfileH264Baseline           : VAEntrypointEncSlice
      VAProfileH264Main               : VAEntrypointVLD
      VAProfileH264Main               : VAEntrypointEncSlice
      VAProfileH264High               : VAEntrypointVLD
      VAProfileH264High               : VAEntrypointEncSlice
      VAProfileVC1Simple              : VAEntrypointVLD
      VAProfileVC1Main                : VAEntrypointVLD
      VAProfileVC1Advanced            : VAEntrypointVLD
      VAProfileJPEGBaseline           : VAEntrypointVLD


i don't think that's normal.

i try libva and libva-intel-driver from staging and it's the same corrupted display.

I also delate liva ,libva-intel-driver , ffmpeg anrecompile all but with no change


See you
Comment 1 zaverel 2012-11-23 13:22:18 UTC
Created attachment 70476 [details]
Xorg.0.log
Comment 2 zaverel 2012-11-23 13:30:01 UTC
Created attachment 70477 [details]
sample from vdr recording
Comment 3 zaverel 2012-11-23 13:32:23 UTC
lspci -vxxx -s 0:02.0
00:02.0 VGA compatible controller: Intel Corporation Xeon E3-1200 v2/3rd Gen Core processor Graphics Controller (rev 09) (prog-if 00 [VGA controller])
        Subsystem: Micro-Star International Co., Ltd. Device 2111
        Flags: bus master, fast devsel, latency 0, IRQ 44
        Memory at f7800000 (64-bit, non-prefetchable) [size=4M]
        Memory at e0000000 (64-bit, prefetchable) [size=256M]
        I/O ports at f000 [size=64]
        Expansion ROM at <unassigned> [disabled]
        Capabilities: [90] MSI: Enable+ Count=1/1 Maskable- 64bit-
        Capabilities: [d0] Power Management version 2
        Capabilities: [a4] PCI Advanced Features
        Kernel driver in use: i915
00: 86 80 52 01 07 04 90 00 09 00 00 03 00 00 00 00
10: 04 00 80 f7 00 00 00 00 0c 00 00 e0 00 00 00 00
20: 01 f0 00 00 00 00 00 00 00 00 00 00 62 14 11 21
30: 00 00 00 00 90 00 00 00 00 00 00 00 0b 01 00 00
40: 09 00 0c 01 92 80 80 e2 d0 00 50 14 00 00 00 00
50: 41 02 00 00 11 00 00 00 00 00 00 00 01 00 a0 cf
60: 00 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00
70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
90: 05 d0 01 00 0c f0 e0 fe e1 41 00 00 00 00 00 00
a0: 00 00 00 00 13 00 06 03 00 00 00 00 00 00 00 00
b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
d0: 01 a4 22 00 00 00 00 00 00 00 00 00 00 00 00 00
e0: 00 00 00 00 00 00 00 00 00 80 00 00 00 00 00 00
f0: 00 00 00 00 00 00 00 00 00 00 09 00 18 70 fd cc
Comment 4 zaverel 2012-11-23 13:34:55 UTC
I attach a sample from vdr but the probleme is for all video .avi , mpeg2 ,mp4 ... in sd and hd
Comment 5 ykzhao 2012-12-13 03:55:58 UTC
Hi, Zaverel
    Will you please attach one video stream which will have the issue of display corruption? 
    I also try the driver on my Ivb machine and it can work well.
   

BTW: Does it work well if you use the following command?
    mplayer -vo X11 ***.mv

Thanks.
Comment 6 zaverel 2012-12-13 12:31:23 UTC
Hello,

I already upload a sample here : 00001.ts

But it's all video that don't work with vaapi.

mplayer -x11 00001.ts  => play only sound 

xine --video=x11 00001.ts  => play video+audio

mplayer and xine work good with xv

See you.
Comment 7 zaverel 2012-12-13 14:43:01 UTC
hi,

on gentoo ,compile of libva-intel-driver-1.0.18 is done with libva-1.1.0.patch (attached)

Without that patch compile is broken.



libva-intel-driver-1.0.19 has no patch and maybe that the probleme.

see you
Comment 8 zaverel 2012-12-13 14:46:23 UTC
Created attachment 71449 [details] [review]
libva-1.1.0.patch

11 Oct 2012; Alexis Ballier <aballier@gentoo.org>
  libva-intel-driver-1.0.18-r1.ebuild, +files/libva-1.1.0.patch:
  fix build with libva-1.1.0
Comment 9 Mr45 2012-12-13 17:08:33 UTC
Hi,

I'm having the same problem with i3-3220T (HD2500) and Q77 chipset. I'm using Openelec (XBMC). With 1.0.18 driver playback is fine, with 1.0.19 (and no other changes) I'm getting 2-3 seconds of corrupted playback and then dmesg shows GPU hung. It affects all vaapi accelerated playback. There is no problem with i3-3225 (HD4000). I've seen others report it too https://github.com/OpenELEC/OpenELEC.tv/issues/1472

Regards
Comment 10 ykzhao 2012-12-14 00:42:22 UTC
(In reply to comment #8)
> Created attachment 71449 [details] [review] [review]
> libva-1.1.0.patch
> 
> 11 Oct 2012; Alexis Ballier <aballier@gentoo.org>
>   libva-intel-driver-1.0.18-r1.ebuild, +files/libva-1.1.0.patch:
>   fix build with libva-1.1.0

Can the video clip be played back after applying this patch?
Comment 11 haihao 2012-12-14 03:15:35 UTC
>>> vainfo: Driver version: Intel i965 driver - 1.0.18

You are using 1.0.18, could you double check it is an issue of 1.0.19 ?
Comment 12 Mr45 2012-12-14 08:35:53 UTC
(In reply to comment #7)
> hi,
> 
> on gentoo ,compile of libva-intel-driver-1.0.18 is done with
> libva-1.1.0.patch (attached)
> 
> Without that patch compile is broken.
> 
> 
> 
> libva-intel-driver-1.0.19 has no patch and maybe that the probleme.
> 
> see you

I've used similar patch on 1.0.18 too, otherwise it wouldn't compile.
This patch seems to be for 1.0.18 only, on 1.0.19 it fails:
i965_drv_video.c
2 out of 2 hunks FAILED
intel_driver.c
1 out of 1 hunk FAILED
I doubt it's needed for 1.0.19 anyway, whatever it fixed in 1.0.18 is is already fixed in 1.0.19.

I've searched web and it looks like only people with i3-3220(T) report this kind of problem and it applys to any VAAPI accelerated playback, any h264, mpeg2 etc. file.

Regards
Comment 13 zaverel 2012-12-14 14:47:12 UTC
Hello,

like said mr45 libva-intel-driver-1.0.18 doesn't compile without  libva-1.1.0.patch.
That patch come from official gentoo.

libva-intel-driver-1.0.18 patched is the latest working version at least for 
 i3-3220T (HD2500) and b75 chipset for me and  Q77 for mr45.

libva-intel-driver-1.0.19 compile without patch but don't work good.


I just try  libva and libva-intel-driver from master and staging but no change.


See you
Comment 14 haihao 2012-12-20 05:34:58 UTC
I can't reproduce this issue on an Ivy bridge machine which has the same graphics (pci id 0x152) as yours machine.  What is the command when you run mplayer -vaapi ?
Comment 15 zaverel 2012-12-20 20:19:21 UTC
Hello,

I just start mplayer -vo vaapi video.avi

but now i found the bug 

http://cgit.freedesktop.org/vaapi/intel-driver/commit/?id=ffe25a063e23222cd72fbe4ae3eb0409618c77dd

in i965_defines.h 

define GEN7_PS_MAX_THREADS_SHIFT 23 => work

define GEN7_PS_MAX_THREADS_SHIFT 24 => don't work

so i revert the commit and that work now.
At least for my i3-3220T (hd2500)


this with libva-intel-driver-1.0.19 

and libva ,libva-intel-driver from staging branch


See you
Comment 16 ykzhao 2012-12-21 01:15:57 UTC
Thanks for your finding.
It will be nice that it can work after you revert the mentioned patch.
Comment 17 haihao 2012-12-28 01:09:19 UTC
The commit is right,  it reveals another bug in the driver.
Comment 18 haihao 2012-12-28 01:14:52 UTC
commit a140c632046e50a41bf75da097834fd9954b9561
Author: Xiang, Haihao <haihao.xiang@intel.com>
Date:   Fri Dec 21 10:25:57 2012 +0800

    Render: Update the maximum number of WM threads
    
    The number is stolen from Mesa.
    
    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=57323
    Signe-off-by: Xiang, Haihao <haihao.xiang@intel.com>
    Tested-by: zaverel <zaverel@free.fr>


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.