Bug 93477 - loop in pipe configuration computation
Summary: loop in pipe configuration computation
Status: CLOSED FIXED
Alias: None
Product: DRI
Classification: Unclassified
Component: DRM/Intel (show other bugs)
Version: DRI git
Hardware: Other All
: medium normal
Assignee: Maarten Lankhorst
QA Contact: Intel GFX Bugs mailing list
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-12-22 20:17 UTC by Chris Wilson
Modified: 2017-07-24 22:43 UTC (History)
1 user (show)

See Also:
i915 platform: HSW
i915 features: display/atomic


Attachments
dmesg (69.93 KB, text/plain)
2015-12-22 20:21 UTC, Chris Wilson
no flags Details
drm.debug=0x1f dmesg (97.32 KB, text/plain)
2016-04-26 13:04 UTC, Chris Wilson
no flags Details

Description Chris Wilson 2015-12-22 20:17:43 UTC
[  233.751747] ------------[ cut here ]------------
[  233.751759] WARNING: CPU: 2 PID: 3737 at drivers/gpu/drm/i915/intel_display.c:12407 intel_atomic_check+0xe9c/0x1100()
[  233.751761] loop in pipe configuration computation
[  233.751764] CPU: 2 PID: 3737 Comm: Xorg Tainted: G        W       4.4.0-rc6+ #501
[  233.751766] Hardware name: Intel Corporation Shark Bay Client platform/Basking Ridge, BIOS HSWLPTU1.86C.0131.R01.1307040815 07/04/2013
[  233.751767]  ffffffff8179a8b0 ffff8800a1adfaa8 ffffffff8125b4e9 0000000000000000
[  233.751772]  ffff8800a1adfaf8 ffff8800a1adfae8 ffffffff8106c342 000008c8000007f8
[  233.751776]  ffff8800a1a03600 0000000000000001 ffff880148b7d000 ffff880148b4e000
[  233.751779] Call Trace:
[  233.751786]  [<ffffffff8125b4e9>] dump_stack+0x45/0x5c
[  233.751789]  [<ffffffff8106c342>] warn_slowpath_common+0x92/0xd0
[  233.751791]  [<ffffffff8106c3f6>] warn_slowpath_fmt+0x46/0x50
[  233.751794]  [<ffffffff813bb264>] ? intel_link_compute_m_n+0x54/0x70
[  233.751795]  [<ffffffff813bc11c>] intel_atomic_check+0xe9c/0x1100
[  233.751799]  [<ffffffff8133c7af>] drm_atomic_check_only+0x15f/0x5b0
[  233.751801]  [<ffffffff8133c2c9>] ? drm_atomic_set_crtc_for_connector+0x29/0xa0
[  233.751803]  [<ffffffff8133cc20>] drm_atomic_commit+0x20/0x70
[  233.751808]  [<ffffffff813183a7>] drm_atomic_helper_set_config+0x77/0xb0
[  233.751811]  [<ffffffff8132b508>] drm_mode_set_config_internal+0x68/0x100
[  233.751813]  [<ffffffff8132b8a8>] drm_mode_setcrtc+0xe8/0x510
[  233.751815]  [<ffffffff813217f5>] drm_ioctl+0x255/0x4f0
[  233.751818]  [<ffffffff811b85e9>] ? ext4_file_write_iter+0x159/0x370
[  233.751820]  [<ffffffff8132b7c0>] ? drm_crtc_check_viewport+0xa0/0xa0
[  233.751823]  [<ffffffff8115b2e3>] do_vfs_ioctl+0x83/0x4d0
[  233.751826]  [<ffffffff81075e07>] ? recalc_sigpending+0x17/0x30
[  233.751827]  [<ffffffff81076437>] ? __set_task_blocked+0x37/0x80
[  233.751830]  [<ffffffff8114e042>] ? __sb_end_write+0x22/0x30
[  233.751832]  [<ffffffff8107887f>] ? __set_current_blocked+0x3f/0x60
[  233.751834]  [<ffffffff8115b77c>] SyS_ioctl+0x4c/0x90
[  233.751836]  [<ffffffff81078add>] ? SyS_rt_sigprocmask+0x8d/0xb0
[  233.751840]  [<ffffffff8152e6d7>] entry_SYSCALL_64_fastpath+0x12/0x6a
[  233.751841] ---[ end trace c24109ba1fac09a5 ]---
[  233.753439] ------------[ cut here ]------------
[  233.753445] WARNING: CPU: 2 PID: 3737 at drivers/gpu/drm/i915/intel_display.c:12407 intel_atomic_check+0xe9c/0x1100()
[  233.753447] loop in pipe configuration computation
[  233.753448] CPU: 2 PID: 3737 Comm: Xorg Tainted: G        W       4.4.0-rc6+ #501
[  233.753450] Hardware name: Intel Corporation Shark Bay Client platform/Basking Ridge, BIOS HSWLPTU1.86C.0131.R01.1307040815 07/04/2013
[  233.753451]  ffffffff8179a8b0 ffff8800a1adfaa8 ffffffff8125b4e9 0000000000000000
[  233.753454]  ffff8800a1adfaf8 ffff8800a1adfae8 ffffffff8106c342 000008c8000007f8
[  233.753457]  ffff8800a148f000 0000000000000001 ffff880148b7d000 ffff880148b4e000
[  233.753460] Call Trace:
[  233.753463]  [<ffffffff8125b4e9>] dump_stack+0x45/0x5c
[  233.753466]  [<ffffffff8106c342>] warn_slowpath_common+0x92/0xd0
[  233.753467]  [<ffffffff8106c3f6>] warn_slowpath_fmt+0x46/0x50
[  233.753469]  [<ffffffff813bb264>] ? intel_link_compute_m_n+0x54/0x70
[  233.753470]  [<ffffffff813bc11c>] intel_atomic_check+0xe9c/0x1100
[  233.753472]  [<ffffffff8133c7af>] drm_atomic_check_only+0x15f/0x5b0
[  233.753474]  [<ffffffff8133c2c9>] ? drm_atomic_set_crtc_for_connector+0x29/0xa0
[  233.753476]  [<ffffffff8133cc20>] drm_atomic_commit+0x20/0x70
[  233.753479]  [<ffffffff813183a7>] drm_atomic_helper_set_config+0x77/0xb0
[  233.753481]  [<ffffffff8132b508>] drm_mode_set_config_internal+0x68/0x100
[  233.753482]  [<ffffffff8132b8a8>] drm_mode_setcrtc+0xe8/0x510
[  233.753484]  [<ffffffff813217f5>] drm_ioctl+0x255/0x4f0
[  233.753486]  [<ffffffff8132b7c0>] ? drm_crtc_check_viewport+0xa0/0xa0
[  233.753488]  [<ffffffff8115b2e3>] do_vfs_ioctl+0x83/0x4d0
[  233.753490]  [<ffffffff81075e07>] ? recalc_sigpending+0x17/0x30
[  233.753491]  [<ffffffff81076437>] ? __set_task_blocked+0x37/0x80
[  233.753493]  [<ffffffff8107887f>] ? __set_current_blocked+0x3f/0x60
[  233.753495]  [<ffffffff8115b77c>] SyS_ioctl+0x4c/0x90
[  233.753496]  [<ffffffff81078add>] ? SyS_rt_sigprocmask+0x8d/0xb0
[  233.753500]  [<ffffffff8152e6d7>] entry_SYSCALL_64_fastpath+0x12/0x6a
[  233.753501] ---[ end trace c24109ba1fac09a6 ]---
Comment 1 Chris Wilson 2015-12-22 20:21:31 UTC
Created attachment 120652 [details]
dmesg
Comment 2 Chris Wilson 2016-02-03 11:05:57 UTC
Still in

commit 02932377a975a59ccd83095816d5b23183107d79
Author: Matt Roper <matthew.d.roper@intel.com>
Date:   Tue Feb 2 17:54:55 2016 -0800

    drm-intel-nightly: 2016y-02m-03d-01h-54m-27s UTC integration manifest
Comment 3 Maarten Lankhorst 2016-04-26 07:23:56 UTC
Do you have a full log with drm.debug=0x1f?
Comment 4 Chris Wilson 2016-04-26 13:04:55 UTC
Created attachment 123272 [details]
drm.debug=0x1f dmesg
Comment 5 Maarten Lankhorst 2016-05-03 08:07:40 UTC
In intel_crt.c:

	if (HAS_PCH_LPT(dev))
		pipe_config->pipe_bpp = 24;

Can you make it a WARN_ON, see if it trips?
Comment 6 Chris Wilson 2016-05-03 08:30:54 UTC
diff --git a/drivers/gpu/drm/i915/intel_crt.c b/drivers/gpu/drm/i915/intel_crt.c
index a2a31fd..64fe69d 100644
--- a/drivers/gpu/drm/i915/intel_crt.c
+++ b/drivers/gpu/drm/i915/intel_crt.c
@@ -261,8 +261,13 @@ static bool intel_crt_compute_config(struct intel_encoder *encoder,
                pipe_config->has_pch_encoder = true;
 
        /* LPT FDI RX only supports 8bpc. */
-       if (HAS_PCH_LPT(dev))
+       if (HAS_PCH_LPT(dev)) {
+               if (pipe_config->bw_constrained && pipe_config->pipe_bpp < 24) {
+                       DRM_DEBUG_KMS("LPT only supports 24bpp\n");
+                       return false;
+               }
                pipe_config->pipe_bpp = 24;
+       }
 
        /* FDI must always be 2.7 GHz */
        if (HAS_DDI(dev))

makes it fail silently. This setup (using a 1080p mode on a forced VGA output) used to work on this machine for all intents and purposes.
Comment 7 Chris Wilson 2016-05-03 08:40:35 UTC
Replaced the modeline with the one from the edid (I guess I used cvt or gtf) and I can use the machine again. So what's the verdict on this where the setup used to work but now doesn't?
Comment 8 Jani Nikula 2016-05-03 09:56:33 UTC
Bisect would probably be helpful?
Comment 9 Maarten Lankhorst 2016-05-04 10:41:19 UTC
Did you generate the cvt line with -r ?
Comment 10 Chris Wilson 2016-05-04 11:37:08 UTC
It had been working for so long, I can't remember its origins.
Comment 11 Maarten Lankhorst 2016-10-12 11:11:38 UTC
commit f58a1acc7e4a1f37d26124ce4c875c647fbcc61f
Author: Daniel Vetter <daniel.vetter@ffwll.ch>
Date:   Tue May 3 10:33:01 2016 +0200

    drm/i915: Bail out of pipe config compute loop on LPT


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.