Bug 82749 - [all Bisected]igt/gem_wait/render_timeout fails
Summary: [all Bisected]igt/gem_wait/render_timeout fails
Status: CLOSED FIXED
Alias: None
Product: DRI
Classification: Unclassified
Component: DRM/Intel (show other bugs)
Version: unspecified
Hardware: Other All
: highest normal
Assignee: Chris Wilson
QA Contact: Intel GFX Bugs mailing list
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-08-18 07:41 UTC by Guo Jinxian
Modified: 2017-02-10 08:57 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
dmesg (68.52 KB, text/plain)
2014-08-18 07:41 UTC, Guo Jinxian
no flags Details

Description Guo Jinxian 2014-08-18 07:41:05 UTC
Created attachment 104799 [details]
dmesg

==System Environment==
--------------------------
Regression: Yes.
Good commit on drm-fixes:1b2c4869d8247f9e202fa8a73777c34adc62d409

Non-working platforms: PNV

==kernel==
--------------------------
origin/drm-intel-nightly: 186631131a9289dad22f51315d78b9b6ac5b425f(fails)
    drm-intel-nightly: 2014y-08m-15d-14h-55m-27s integration manifest
origin/drm-intel-next-queued: ecca3fd0ea82c45b558f68b1ff3bf6685b443ab1(works)
    drm/i915/bdw: Enable Logical Ring Contexts (hence, Execlists)
origin/drm-intel-fixes: 103ae732ad26141515f109c80b5c1ced16e457c3(works)
    drm/i915: Don't try to enable cursor from setplane when crtc is disabled
origin/drm-fixes: 251964845fbf539781dd2c6406cb2ba1bf9eddd0(fails)
    drm/doc: Refer to proper source file
origin/drm-next: 7963e9db1b1f842fdc53309baa8714d38e9f5681(works)
    Revert "drm: drop redundant drm_file->is_master"

==Bug detailed description==
-----------------------------
igt/gem_wait_render_timeout fails

Output:
[root@x-pnv2 tests]# ./gem_wait_render_timeout
IGT-Version: 1.7-g1bec6cb (i686) (Linux: 3.16.0_drm-intel-nightly_186631_20140818+ i686)
2048 iters is enough work
Finished with 220742365 time remaining
Test assertion failure function __real_main130, file gem_wait_render_timeout.c:223:
Failed assertion: timeout == 0
Last errno: 62, Timer expired
[root@x-pnv2 tests]# echo $?
99


Reproduce steps:
-------------------------
1. ./gem_wait_render_timeout
Comment 1 Chris Wilson 2014-08-18 07:46:57 UTC
That will be the struct timespec conversion. I'll fix this up with requests.
Comment 2 Guo Jinxian 2014-08-18 08:18:03 UTC
This bug is able to reproduce on BYT on latest -nihglty(186631131a9289dad22f51315d78b9b6ac5b425f) too

root@x-bytm02:/GFX/Test/Intel_gpu_tools/intel-gpu-tools/tests# ./gem_wait_render_timeout
IGT-Version: 1.7-g5c7bcb1 (x86_64) (Linux: 3.16.0_drm-intel-nightly_186631_20140818+ x86_64)
8192 iters is enough work
Finished with 330466078 time remaining
Test assertion failure function __real_main130, file gem_wait_render_timeout.c:223:
Failed assertion: timeout == 0
Last errno: 62, Timer expired
Comment 3 Guo Jinxian 2014-08-19 02:46:23 UTC
Test failed on IVB on latest -nightly(186631131a9289dad22f51315d78b9b6ac5b425f) too.

[root@x-ivb9 tests]# ./gem_wait_render_timeout
IGT-Version: 1.7-g1bec6cb (x86_64) (Linux: 3.16.0_drm-intel-nightly_186631_20140818_debug+ x86_64)
8192 iters is enough work
Finished with 760626512 time remaining
Test assertion failure function __real_main130, file gem_wait_render_timeout.c:223:
Failed assertion: timeout == 0
Last errno: 62, Timer expired
Comment 4 lu hua 2014-08-21 02:05:25 UTC
It impacts all platforms.
Comment 5 Guo Jinxian 2014-09-02 05:15:22 UTC
This failure still able to reproduce on ILK

[root@x-e6510 tests]# ./gem_wait_render_timeout
IGT-Version: 1.7-gf473a55 (i686) (Linux: 3.17.0-rc2_drm-intel-fixes_2a592b_20140902+ i686)
1024 iters is enough work
Finished with 929066159 time remaining
Test assertion failure function __real_main120, file gem_wait_render_timeout.c:213:
Failed assertion: timeout == 0
Last errno: 62, Timer expired
error: 896679 != 0
Comment 6 Chris Wilson 2014-09-06 12:21:20 UTC
Fixed in git://people.freedesktop.org/~ickle/linux-2.6 requests
Comment 7 Imre Deak 2014-09-19 15:55:32 UTC
Please retest with the branch in comment 6.
Comment 8 Guo Jinxian 2014-09-25 09:00:56 UTC
(In reply to comment #6)
> Fixed in git://people.freedesktop.org/~ickle/linux-2.6 requests

The kernel unable to boot, please refer to Bug 82750 for the failure.

commit 3a5e1e6176fb61735a98f16a80c756b3cc69f125
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date:   Sun Aug 24 19:34:16 2014 +0100

    drm/i915: Convert a couple more INTEL_INFO-esque macros to be pointer agnostic

    Just a couple more macros that assume that they were being passed a
    struct drm_device when they want a struct drm_i915_private. Use our
    magic macro to ease transitioning over to using drm_i915_privates

    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Comment 9 Guo Jinxian 2014-10-08 07:33:41 UTC
Test failed on BYT on latest -nightly(eabc0c8db15f9ba4d727aee5e0612a68cafe1ab5)

root@x-byt06:/GFX/Test/Intel_gpu_tools/intel-gpu-tools/tests# ./gem_wait --run-subtest render_timeout
IGT-Version: 1.8-g764772c (x86_64) (Linux: 3.17.0-rc7_drm-intel-nightly_eabc0c_20141006+ x86_64)
8192 iters is enough work
Finished with 111317851 time remaining
Test assertion failure function render_timeout, file gem_wait.c:200:
Failed assertion: timeout == 0
Last errno: 62, Timer expired
error: 513963 != 0
Subtest render_timeout: FAIL (15.448s)
root@x-byt06:/GFX/Test/Intel_gpu_tools/intel-gpu-tools/tests# echo $?
99
Comment 10 Guo Jinxian 2014-10-10 07:44:13 UTC
Cases below still fail


root@x-byt06:/GFX/Test/Intel_gpu_tools/intel-gpu-tools/tests# ./gem_wait --run-subtest invalid-flags
IGT-Version: 1.8-g7f82289 (x86_64) (Linux: 3.17.0_drm-intel-nightly_ea4bec_20141010+ x86_64)
Test assertion failure function invalid_flags, file gem_wait.c:230:
Failed assertion: ret != 0 && errno == EINVAL
Subtest invalid-flags: FAIL (0.000s)
root@x-byt06:/GFX/Test/Intel_gpu_tools/intel-gpu-tools/tests# ./gem_wait --run-subtest render_timeout
IGT-Version: 1.8-g7f82289 (x86_64) (Linux: 3.17.0_drm-intel-nightly_ea4bec_20141010+ x86_64)
8192 iters is enough work
Finished with 110706315 time remaining
Test assertion failure function render_timeout, file gem_wait.c:200:
Failed assertion: timeout == 0
Last errno: 62, Timer expired
error: 949723 != 0
Subtest render_timeout: FAIL (15.594s)
Comment 11 Daniel Vetter 2014-10-20 12:35:09 UTC
Clarify scope with renamed tests: This bug is _only_ about the render_timeout testcase. All the other new subtests are new, any issues with them should be filed as new bugs.
Comment 12 Guo Jinxian 2014-10-21 08:05:07 UTC
(In reply to Daniel Vetter from comment #11)
> Clarify scope with renamed tests: This bug is _only_ about the
> render_timeout testcase. All the other new subtests are new, any issues with
> them should be filed as new bugs.

igt/gem_wait/invalid-flags failure is tracking by bug 85280 now.
Comment 13 Daniel Vetter 2014-11-27 16:59:59 UTC
Is this still an issue on latest kernels?
Comment 14 Guo Jinxian 2014-11-28 08:13:28 UTC
(In reply to Daniel Vetter from comment #13)
> Is this still an issue on latest kernels?

Test still fails on latest -nightly(904b8529cd69f98b98d33b533a211003f99fb1cd)

root@x-bytm02:/GFX/Test/Intel_gpu_tools/intel-gpu-tools/tests# ./gem_wait --run-subtest render_timeout
IGT-Version: 1.8-gd807891 (x86_64) (Linux: 3.18.0-rc6_drm-intel-nightly_904b85_20141127+ x86_64)
8192 iters is enough work
Finished with 330928368 time remaining
Test assertion failure function render_timeout, file gem_wait.c:200:
Failed assertion: timeout == 0
Last errno: 62, Timer expired
error: 700747 != 0
Subtest render_timeout: FAIL (13.924s)
Comment 15 Daniel Vetter 2014-11-28 09:16:43 UTC
Hm, no bisect result.

On a hunch this regression is probably due to

commit 5ed0bdf21a85d78e04f89f15ccf227562177cbd9
Author: Thomas Gleixner <tglx@linutronix.de>
Date:   Wed Jul 16 21:05:06 2014 +0000

    drm: i915: Use nsec based interfaces
    
    Use ktime_get_raw_ns() and get rid of the back and forth timespec
    conversions.
    
    Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
    Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
    Signed-off-by: John Stultz <john.stultz@linaro.org>

Can you please test this commit + its parent to check whether that's right? Test results here on my machine are somehow strange so I'd like confirmation.
Comment 16 Daniel Vetter 2014-11-28 10:02:46 UTC
Please also test the following two patches (you need both, it's two bugs):

http://patchwork.freedesktop.org/patch/37743/
http://patchwork.freedesktop.org/patch/37744/
Comment 17 Guo Jinxian 2014-12-01 05:26:08 UTC
(In reply to Daniel Vetter from comment #15)
> Hm, no bisect result.
> 
> On a hunch this regression is probably due to
> 
> commit 5ed0bdf21a85d78e04f89f15ccf227562177cbd9
> Author: Thomas Gleixner <tglx@linutronix.de>
> Date:   Wed Jul 16 21:05:06 2014 +0000
> 
>     drm: i915: Use nsec based interfaces
>     
>     Use ktime_get_raw_ns() and get rid of the back and forth timespec
>     conversions.
>     
>     Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
>     Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
>     Signed-off-by: John Stultz <john.stultz@linaro.org>
> 
> Can you please test this commit + its parent to check whether that's right?
> Test results here on my machine are somehow strange so I'd like confirmation.
Yes, 5ed0bdf21a85d78e04f89f15ccf227562177cbd9 is the first bad commit. it's parents commit(f519b1a2e08c913375324a927992bb328387f169) is good commit. 

[root@x-hsw24 tests]# ./gem_wait --run-subtest render_timeout
IGT-Version: 1.8-gdbac905 (x86_64) (Linux: 3.16.0-rc5_kcloud_f519b1_20141201+ x86_64)
8192 iters is enough work
Finished with 815483789 time remaining
Subtest render_timeout: SUCCESS (10.395s)


[root@x-hsw24 tests]# ./gem_wait --run-subtest render_timeout
IGT-Version: 1.8-gdbac905 (x86_64) (Linux: 3.16.0-rc5_kcloud_5ed0bd_20141201+ x86_64)
8192 iters is enough work
Finished with 815166097 time remaining
Test assertion failure function render_timeout, file gem_wait.c:200:
Failed assertion: timeout == 0
Last errno: 62, Timer expired
error: 1170404 != 0
Subtest render_timeout: FAIL (10.392s)
Comment 18 Guo Jinxian 2014-12-01 05:34:29 UTC
(In reply to Daniel Vetter from comment #16)
> Please also test the following two patches (you need both, it's two bugs):
> 
> http://patchwork.freedesktop.org/patch/37743/
> http://patchwork.freedesktop.org/patch/37744/

The patch unable to patch on latest -nightly(0db9cf7742874ee2c09a35b640c1bb04cb379eb6). Could you help to update the patch? Thanks.
Comment 19 Jani Nikula 2014-12-08 12:36:37 UTC
commit 7bd0e226e313547add65c7e4b0ecf65cb981a3c6
Author: Daniel Vetter <daniel.vetter@ffwll.ch>
Date:   Thu Dec 4 11:12:54 2014 +0100

    drm/i915: compute wait_ioctl timeout correctly

commit 9cca30688043eb1b6569f794041dfeec218dffa5
Author: Daniel Vetter <daniel.vetter@ffwll.ch>
Date:   Fri Nov 28 10:29:55 2014 +0100

    drm/i915: Handle inaccurate time conversion issues
Comment 20 Guo Jinxian 2014-12-09 08:50:05 UTC
Verified on latest -nightly(34d267c2ba9c0845432baf959a2c4deed87f3ee4)

[root@x-hsw24 tests]# ./gem_wait --run-subtest render_timeout
IGT-Version: 1.8-g819e68f (x86_64) (Linux: 3.18.0_drm-intel-nightly_34d267_20141209+ x86_64)
8192 iters is enough work
Finished with 812905627 time remaining
Subtest render_timeout: SUCCESS (11.472s)
Comment 21 Jari Tahvanainen 2017-02-10 08:57:26 UTC
Closing (>2 years) old Verified+Fixed.


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.