Bug 66111 - [IVB]igt/kms_flip failed to set mode on [CRTC:7], err = -22 with VGA/DP
Summary: [IVB]igt/kms_flip failed to set mode on [CRTC:7], err = -22 with VGA/DP
Status: CLOSED FIXED
Alias: None
Product: DRI
Classification: Unclassified
Component: DRM/Intel (show other bugs)
Version: unspecified
Hardware: All Linux (All)
: high major
Assignee: Intel GFX Bugs mailing list
QA Contact: Intel GFX Bugs mailing list
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-06-24 07:40 UTC by lu hua
Modified: 2017-10-06 14:45 UTC (History)
2 users (show)

See Also:
i915 platform:
i915 features:


Attachments
dmesg (30.09 KB, text/plain)
2013-06-24 07:40 UTC, lu hua
no flags Details
dmesg (51.94 KB, text/plain)
2013-06-25 02:43 UTC, lu hua
no flags Details
dmesg with patch (5.68 KB, text/plain)
2013-06-26 03:17 UTC, lu hua
no flags Details

Description lu hua 2013-06-24 07:40:53 UTC
Created attachment 81305 [details]
dmesg

System Environment:
--------------------------
Arch:           x86_64
Platform:      Ivybridge
Kernel:    (drm-intel-fixes) 19b2dbde5732170a03bd82cc8bd442cf88d856f7

Bug detailed description:
-----------------------------
When run kms_flip subcase with VGA/DP, failed to set mode.
It happens on ivybridge with drm-intel-fixes kernel, works well on drm-intel-next-queued kernel. 
It also works well with HDMI.
I test it on igt commit:43a086269795c5b41bdab0dc2c456be0de97e762, It also has this issue.
Test it on drm-intel-fixes kernel commit:8abbbaf6adb46157b6bd416f7616b555cc6a332f, It also happens.

output:
Using monotonic timestamps
running testcase: absolute-wf_vblank
Beginning absolute-wf_vblank on crtc 3, connector 9
  2048x1152 60 2048 2184 2400 2752 1152 1155 1160 1195 0x6 0x48 197000
.............................................................
absolute-wf_vblank on crtc 3, connector 9: PASSED

Beginning absolute-wf_vblank on crtc 5, connector 9
  2048x1152 60 2048 2184 2400 2752 1152 1155 1160 1195 0x6 0x48 197000
.............................................................
absolute-wf_vblank on crtc 5, connector 9: PASSED

Beginning absolute-wf_vblank on crtc 7, connector 9
  2048x1152 60 2048 2184 2400 2752 1152 1155 1160 1195 0x6 0x48 197000
failed to set mode (2048x1152@60Hz): Invalid argument

Reproduce steps:
----------------------------
1. ./kms_flip --run-subtest absolute-wf_vblank
Comment 1 Chris Wilson 2013-06-24 08:08:08 UTC
Another expected failure for overdriving the third pipe.
Comment 2 Chris Wilson 2013-06-24 11:08:39 UTC
commit 6de9736394242f207a43e828a8236e4f63c16e03
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date:   Mon Jun 24 12:03:54 2013 +0100

    tests/kms_flip: Suppress failure from setting mode
    
    We may fail to set a mode if it fails some hidden constraints, such as
    bandwidth on the third pipe. This is expected, so skip testing such
    modes.
    
    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=66111
    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Comment 3 lu hua 2013-06-25 02:43:16 UTC
The output shows pass and return value is 0. But "<3>[  230.406125] [drm:intel_crtc_set_config] *ERROR* failed to set mode on [CRTC:7], err = -22" still exists in dmesg. 
output 
Using monotonic timestamps
running testcase: absolute-wf_vblank
Beginning absolute-wf_vblank on crtc 3, connector 22
  2560x1600 60 2560 2608 2640 2720 1600 1603 1609 1646 0x9 0x48 268500
.............................................................
absolute-wf_vblank on crtc 3, connector 22: PASSED

Beginning absolute-wf_vblank on crtc 5, connector 22
  2560x1600 60 2560 2608 2640 2720 1600 1603 1609 1646 0x9 0x48 268500
.............................................................
absolute-wf_vblank on crtc 5, connector 22: PASSED

Beginning absolute-wf_vblank on crtc 7, connector 22
  2560x1600 60 2560 2608 2640 2720 1600 1603 1609 1646 0x9 0x48 268500

run: dmesg -r | egrep "<[1-3]>" |grep drm
<3>[  230.406125] [drm:intel_crtc_set_config] *ERROR* failed to set mode on [CRTC:7], err = -22
Comment 4 lu hua 2013-06-25 02:43:50 UTC
Created attachment 81381 [details]
dmesg
Comment 5 Chris Wilson 2013-06-25 06:28:10 UTC
The kernel is reporting that userspace is doing something broken. Userspace sees the error and skips the test.
Comment 6 Daniel Vetter 2013-06-25 09:07:49 UTC
Patch to tune down the dmesg output:

https://patchwork.kernel.org/patch/2775471/
Comment 7 lu hua 2013-06-26 03:17:14 UTC
(In reply to comment #6)
> Patch to tune down the dmesg output:
> 
> https://patchwork.kernel.org/patch/2775471/

Test with this patch.It has another issue.
 dmesg -r | egrep "<[1-3]>" |grep drm
<3>[   65.605165] [drm:intel_pipe_config_compare] *ERROR* mismatch in adjusted_mode.flags (expected 1, found 0)
<3>[   70.975957] [drm:intel_pipe_config_compare] *ERROR* mismatch in adjusted_mode.flags (expected 1, found 0)
Comment 8 lu hua 2013-06-26 03:17:43 UTC
Created attachment 81436 [details]
dmesg with patch
Comment 9 Daniel Vetter 2013-06-26 09:22:25 UTC
(In reply to comment #7)
> (In reply to comment #6)
> > Patch to tune down the dmesg output:
> > 
> > https://patchwork.kernel.org/patch/2775471/
> 
> Test with this patch.It has another issue.
>  dmesg -r | egrep "<[1-3]>" |grep drm
> <3>[   65.605165] [drm:intel_pipe_config_compare] *ERROR* mismatch in
> adjusted_mode.flags (expected 1, found 0)
> <3>[   70.975957] [drm:intel_pipe_config_compare] *ERROR* mismatch in
> adjusted_mode.flags (expected 1, found 0)

That's just the adjuste_mode flag mismatch bug which we're already tracking in bug #65287
Comment 10 lu hua 2013-07-01 08:54:53 UTC
(In reply to comment #3)
> The output shows pass and return value is 0. But "<3>[  230.406125]
> [drm:intel_crtc_set_config] *ERROR* failed to set mode on [CRTC:7], err =
> -22" still exists in dmesg. 
> output 
> Using monotonic timestamps
> running testcase: absolute-wf_vblank
> Beginning absolute-wf_vblank on crtc 3, connector 22
>   2560x1600 60 2560 2608 2640 2720 1600 1603 1609 1646 0x9 0x48 268500
> .............................................................
> absolute-wf_vblank on crtc 3, connector 22: PASSED
> 
> Beginning absolute-wf_vblank on crtc 5, connector 22
>   2560x1600 60 2560 2608 2640 2720 1600 1603 1609 1646 0x9 0x48 268500
> .............................................................
> absolute-wf_vblank on crtc 5, connector 22: PASSED
> 
> Beginning absolute-wf_vblank on crtc 7, connector 22
>   2560x1600 60 2560 2608 2640 2720 1600 1603 1609 1646 0x9 0x48 268500
> 
> run: dmesg -r | egrep "<[1-3]>" |grep drm
> <3>[  230.406125] [drm:intel_crtc_set_config] *ERROR* failed to set mode on
> [CRTC:7], err = -22


It happens with DP, If attach HDMI, it works well.
Comment 11 Daniel Vetter 2013-07-01 08:59:08 UTC
Are you sure you've tested -nightly? That ERROR message has really been changed to a debug output, so if you still see it you're booting the wrong kernel ...
Comment 12 lu hua 2013-07-02 07:31:30 UTC
(In reply to comment #11)
> Are you sure you've tested -nightly? That ERROR message has really been
> changed to a debug output, so if you still see it you're booting the wrong
> kernel ...

I tested it on drm-intel-fixes kernel.It works well on -nightly kernel.
Comment 13 Daniel Vetter 2013-07-02 08:46:49 UTC
We are around the merge window again, which means -fixes doesn't contain all the fixes ;-)

The new -fixes should have the fix.
Comment 14 lu hua 2013-07-15 06:29:43 UTC
Verified.Fixed.
Comment 15 Elizabeth 2017-10-06 14:45:40 UTC
Closing old verified.


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.