Bug 77908 - [IVB Bisected]Subcases dpms-vs-vblank-race-interruptible and modeset-vs-vblank-race of kms_flip fail
Summary: [IVB Bisected]Subcases dpms-vs-vblank-race-interruptible and modeset-vs-vblan...
Status: CLOSED FIXED
Alias: None
Product: DRI
Classification: Unclassified
Component: DRM/Intel (show other bugs)
Version: unspecified
Hardware: Other All
: high normal
Assignee: Ville Syrjala
QA Contact: Intel GFX Bugs mailing list
URL:
Whiteboard:
Keywords:
: 75593 (view as bug list)
Depends on:
Blocks:
 
Reported: 2014-04-25 02:30 UTC by Guo Jinxian
Modified: 2017-09-04 10:18 UTC (History)
2 users (show)

See Also:
i915 platform:
i915 features:


Attachments
dmesg (124.66 KB, text/plain)
2014-04-25 02:30 UTC, Guo Jinxian
no flags Details
dmesg (125.34 KB, text/plain)
2014-05-09 05:52 UTC, Guo Jinxian
no flags Details

Description Guo Jinxian 2014-04-25 02:30:40 UTC
Created attachment 97929 [details]
dmesg

System Environment:
--------------------------
Platform: IVB
kernel:   (drm-intel-fixes) 58b87a391d67e35e3aa1fc6c80890b491d73ad46

Bug detailed description:
----------------------------
Subcases dpms-vs-vblank-race-interruptible and modeset-vs-vblank-race of kms_flip fail on latest -fixes(58b87a391d67e35e3aa1fc6c80890b491d73ad46).

It's a regression bug:
good commit: b6842feb63a23a6a988f4e1ffb93408d8ff6931e
bad commit:  58b87a391d67e35e3aa1fc6c80890b491d73ad46

we will bisect it later

output on -fixes kernel:
./kms_flip --run-subtest modeset-vs-vblank-race
IGT-Version: 1.6-g78e4c2b (x86_64) (Linux: 3.15.0-rc2_drm-intel-fixes_58b87a_20140424_debug+ x86_64)
Using monotonic timestamps
Beginning modeset-vs-vblank-race on crtc 5, connector 16
  1920x1200 60 1920 1968 2000 2080 1200 1203 1209 1235 0x9 0x48 154000
Test assertion failure function run_test_step, file kms_flip.c:901:
Last errno: 22, Invalid argument
Failed assertion: __wait_for_vblank(TEST_VBLANK_BLOCK, o->pipe, 1, 0, &reply) == 0
Subtest modeset-vs-vblank-race: FAIL


Reproduce steps:
---------------------------- 

1. ./kms_flip --run-subtest dpms-vs-vblank-race-interruptible
   or
   ./kms_flip --run-subtest modeset-vs-vblank-race
Comment 1 Daniel Vetter 2014-04-28 13:19:20 UTC
Ping for bisect result ...
Comment 2 Daniel Vetter 2014-04-28 13:20:09 UTC
Also does this issue only happen on HDMI?
Comment 3 Guo Jinxian 2014-04-30 03:41:30 UTC
This bug has been fixes before.
The merge base 691e6415c891b8b2b082a120b896b443531c4d45 is bad.
This means the bug has been fixed between 691e6415c891b8b2b082a120b896b443531c4d45 and [b6842feb63a23a6a988f4e1ffb93408d8ff6931e].

(In reply to comment #2)
> Also does this issue only happen on HDMI?

DP also fails

./kms_flip --run-subtest dpms-vs-vblank-race-interruptible
IGT-Version: 1.6-gc1404e0 (x86_64) (Linux: 3.15.0-rc2_drm-intel-fixes_7f1950_20140429_debug+ x86_64)
Using monotonic timestamps
Beginning dpms-vs-vblank-race-interruptible on crtc 5, connector 26
  1920x1080 60 1920 2008 2052 2200 1080 1084 1089 1125 0x5 0x48 148500
Test assertion failure function run_test_step, file kms_flip.c:901:
Last errno: 22, Invalid argument
Failed assertion: __wait_for_vblank(TEST_VBLANK_BLOCK, o->pipe, 1, 0, &reply) == 0
Subtest dpms-vs-vblank-race-interruptible: FAIL
Comment 4 Guo Jinxian 2014-04-30 04:08:34 UTC
This commit below fixed the bug. Reset to b6842feb63a23a6a988f4e1ffb93408d8ff6931e and reverted commit b6842feb63a23a6a988f4e1ffb93408d8ff6931e, the test result was failed.

commit b6842feb63a23a6a988f4e1ffb93408d8ff6931e
Author: Ville Syrjälä <ville.syrjala@linux.intel.com>
Date:   Thu Mar 27 11:08:45 2014 +0200

    drm/i915: Allow user modes to exceed DVI 165MHz limit

    In commit
     commit 6375b768a9850b6154478993e5fb566fa4614a9c
     Author: Ville Syrjälä <ville.syrjala@linux.intel.com>
     Date:   Mon Mar 3 11:33:36 2014 +0200

        drm/i915: Reject >165MHz modes w/ DVI monitors

    the driver started to filter out display modes which exceed the
    single-link DVI 165Mz dotclock limits when the monitor doesn't report
    itself as being HDMI compliant. The intent was to filter out all
    EDID derived modes that require dual-link DVI to operate since we
    don't support dual-link.

    However the patch went a bit too far and also causes the driver to reject
    such modes even when specified by the user. Normally we don't check the
    sink limitations when setting a mode from the user. This allows the user
    to specify any mode whether the sink reports to support it or not. This
    can be useful since often the sinks support more modes than they report
    in the EDID.

    So relax the checks a bit, and apply the single-link DVI dotclock limit
    only when filtering the mode list, and ignore the limit when setting
    a user specified mode.

    Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=72961
    Tested-by: Nicholas Vinson <nvinson@comcast.net>
    Cc: stable@vger.kernel.org [3.14]
    Reviewed-by: Daniel Vetter <daniel@ffwll.ch>
    Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
    Signed-off-by: Jani Nikula <jani.nikula@intel.com>

:040000 040000 e5dd0a22c4ec8df198400605e960f8c683e732ed 4e2a40b8ecf829d92060ba7561ae6a7f7981878c M      drivers
Comment 5 Jani Nikula 2014-04-30 07:22:29 UTC
(In reply to comment #4)
> This commit below fixed the bug. Reset to
> b6842feb63a23a6a988f4e1ffb93408d8ff6931e and reverted commit
> b6842feb63a23a6a988f4e1ffb93408d8ff6931e, the test result was failed.
> 
> commit b6842feb63a23a6a988f4e1ffb93408d8ff6931e
> Author: Ville Syrjälä <ville.syrjala@linux.intel.com>
> Date:   Thu Mar 27 11:08:45 2014 +0200
> 
>     drm/i915: Allow user modes to exceed DVI 165MHz limit

That this would fix the bug seems a bit surprising to me, reassign to Ville, any thoughts?
Comment 6 Ville Syrjala 2014-05-06 15:57:36 UTC
The patches to fix these are sitting in Daniel's topic/drm-vblank-rework branch, so no suprise that -fixes is broken. The tests aren't entirely reliable and can succeed even if the kernel is still broken.
Comment 7 Guo Jinxian 2014-05-09 05:51:42 UTC
SNB has this issue too

./kms_flip --run-subtest modeset-vs-vblank-race-interruptible
IGT-Version: 1.6-g8741c22 (x86_64) (Linux: 3.15.0-rc3_drm-intel-fixes_e4c610_20140509+ x86_64)
Using monotonic timestamps
Beginning modeset-vs-vblank-race-interruptible on crtc 5, connector 21
  1920x1200 60 1920 1968 2000 2080 1200 1203 1209 1235 0x9 0x40 154000
...........
modeset-vs-vblank-race-interruptible on crtc 5, connector 21: PASSED

Beginning modeset-vs-vblank-race-interruptible on crtc 8, connector 21
  1920x1200 60 1920 1968 2000 2080 1200 1203 1209 1235 0x9 0x40 154000
Test assertion failure function run_test_step, file kms_flip.c:873:
Last errno: 22, Invalid argument
Failed assertion: __wait_for_vblank(TEST_VBLANK_BLOCK, o->pipe, 1, 0, &reply) == 0
Subtest modeset-vs-vblank-race-interruptible: FAIL
Comment 8 Guo Jinxian 2014-05-09 05:52:10 UTC
Created attachment 98728 [details]
dmesg
Comment 9 Daniel Vetter 2014-05-15 16:14:08 UTC
Ok, this should work on -nightly, but is know to be broken on -fixes.

If -nigthly doesn't work, please reopen this bug.
Comment 10 Daniel Vetter 2014-05-19 08:36:33 UTC
*** Bug 75593 has been marked as a duplicate of this bug. ***
Comment 11 Guo Jinxian 2014-06-18 07:49:20 UTC
Verified on latest -nightly
[root@x-ivb6 tests]# ./kms_flip --run-subtest dpms-vs-vblank-race-interruptible
IGT-Version: 1.7-g1b1f4b1 (x86_64) (Linux: 3.15.0-rc8_drm-intel-nightly_fff6c5_20140618+ x86_64)
Using monotonic timestamps
Beginning dpms-vs-vblank-race-interruptible on crtc 6, connector 29
  1920x1200 60 1920 1968 2000 2080 1200 1203 1209 1235 0x9 0x48 154000
.........
dpms-vs-vblank-race-interruptible on crtc 6, connector 29: PASSED

Beginning dpms-vs-vblank-race-interruptible on crtc 10, connector 29
  1920x1200 60 1920 1968 2000 2080 1200 1203 1209 1235 0x9 0x48 154000
.........
dpms-vs-vblank-race-interruptible on crtc 10, connector 29: PASSED

Beginning dpms-vs-vblank-race-interruptible on crtc 14, connector 29
  1920x1200 60 1920 1968 2000 2080 1200 1203 1209 1235 0x9 0x48 154000
.........
dpms-vs-vblank-race-interruptible on crtc 14, connector 29: PASSED

Subtest dpms-vs-vblank-race-interruptible: SUCCESS
[root@x-ivb6 tests]# ./kms_flip --run-subtest modeset-vs-vblank-race
IGT-Version: 1.7-g1b1f4b1 (x86_64) (Linux: 3.15.0-rc8_drm-intel-nightly_fff6c5_20140618+ x86_64)
Using monotonic timestamps
Beginning modeset-vs-vblank-race on crtc 6, connector 29
  1920x1200 60 1920 1968 2000 2080 1200 1203 1209 1235 0x9 0x48 154000
.........
modeset-vs-vblank-race on crtc 6, connector 29: PASSED

Beginning modeset-vs-vblank-race on crtc 10, connector 29
  1920x1200 60 1920 1968 2000 2080 1200 1203 1209 1235 0x9 0x48 154000
.........
modeset-vs-vblank-race on crtc 10, connector 29: PASSED

Beginning modeset-vs-vblank-race on crtc 14, connector 29
  1920x1200 60 1920 1968 2000 2080 1200 1203 1209 1235 0x9 0x48 154000
.........
modeset-vs-vblank-race on crtc 14, connector 29: PASSED

Subtest modeset-vs-vblank-race: SUCCESS
Comment 12 Jari Tahvanainen 2017-09-04 10:18:45 UTC
Closing 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.