Bug 108924 - [CI][BAT] igt@* - dmesg-warn / dmesg-fail - Missing case (intel_dig_port->tc_type == 0)
Summary: [CI][BAT] igt@* - dmesg-warn / dmesg-fail - Missing case (intel_dig_port->tc_...
Status: CLOSED FIXED
Alias: None
Product: DRI
Classification: Unclassified
Component: DRM/Intel (show other bugs)
Version: XOrg git
Hardware: Other All
: highest normal
Assignee: Imre Deak
QA Contact: Intel GFX Bugs mailing list
URL:
Whiteboard: ReadyForDev
Keywords:
: 109044 (view as bug list)
Depends on:
Blocks:
 
Reported: 2018-12-03 11:37 UTC by Martin Peres
Modified: 2018-12-28 08:33 UTC (History)
1 user (show)

See Also:
i915 platform: ICL
i915 features: display/Other


Attachments

Description Martin Peres 2018-12-03 11:37:59 UTC
https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_5237/fi-icl-u3/igt@kms_flip@basic-flip-vs-dpms.html

<4> [228.943635] ------------[ cut here ]------------
<4> [228.943637] Missing case (intel_dig_port->tc_type == 0)
<4> [228.943682] WARNING: CPU: 1 PID: 2861 at drivers/gpu/drm/i915/intel_ddi.c:3097 icl_program_mg_dp_mode+0xe6/0x180 [i915]
<4> [228.943684] Modules linked in: vgem snd_hda_codec_hdmi snd_hda_codec_realtek snd_hda_codec_generic i915 x86_pkg_temp_thermal coretemp snd_hda_intel btusb crct10dif_pclmul btrtl btbcm btintel crc32_pclmul snd_hda_codec snd_hwdep ghash_clmulni_intel snd_hda_core bluetooth snd_pcm cdc_ether usbnet mii e1000e i2c_i801 ecdh_generic prime_numbers
<4> [228.943702] CPU: 1 PID: 2861 Comm: kms_flip Tainted: G     U            4.20.0-rc4-CI-CI_DRM_5237+ #1
<4> [228.943704] Hardware name: Intel Corporation Ice Lake Client Platform/IceLake U DDR4 SODIMM PD RVP TLC, BIOS ICLSFWR1.R00.2402.AD3.1810170014 10/17/2018
<4> [228.943734] RIP: 0010:icl_program_mg_dp_mode+0xe6/0x180 [i915]
<4> [228.943736] Code: 48 89 df b9 01 00 00 00 5b 5d 41 5c 41 5d 41 5e 41 5f e9 7d 21 86 e1 48 c7 c6 8b f6 42 a0 48 c7 c7 57 f6 42 a0 e8 ea 6e ce e0 <0f> 0b 5b 5d 41 5c 41 5d 41 5e 41 5f c3 24 3f ba 01 00 00 00 be a0
<4> [228.943738] RSP: 0018:ffffc90000c73918 EFLAGS: 00010286
<4> [228.943741] RAX: 0000000000000000 RBX: ffff888493180000 RCX: 0000000000000000
<4> [228.943742] RDX: 0000000000000007 RSI: ffffffff820c70c8 RDI: 00000000ffffffff
<4> [228.943744] RBP: 00000000001687a0 R08: 0000000083422804 R09: 0000000000000000
<4> [228.943746] R10: 0000000000000000 R11: 0000000000000000 R12: ffff88849bd80008
<4> [228.943748] R13: 000000000a0038fe R14: 00000000001683a0 R15: 0000000000000000
<4> [228.943750] FS:  00007f5be38f2980(0000) GS:ffff8884afe80000(0000) knlGS:0000000000000000
<4> [228.943752] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
<4> [228.943754] CR2: 000056496e8026c8 CR3: 000000042b0bc005 CR4: 0000000000760ee0
<4> [228.943756] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
<4> [228.943757] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
<4> [228.943759] PKRU: 55555554
<4> [228.943760] Call Trace:
<7> [228.978627] [drm:verify_single_dpll_state.isra.101 [i915]] MG PLL 1
<7> [228.979646] [drm:intel_dump_pipe_config [i915]] [PLANE:35:plane 2A] disabled, scaler_id = -1
<7> [228.979671] [drm:intel_dump_pipe_config [i915]] [PLANE:42:plane 3A] disabled, scaler_id = -1
<7> [228.979695] [drm:intel_dump_pipe_config [i915]] [PLANE:49:plane 4A] disabled, scaler_id = -1
<7> [228.979720] [drm:intel_dump_pipe_config [i915]] [PLANE:56:plane 5A] disabled, scaler_id = -1
<7> [228.979744] [drm:intel_dump_pipe_config [i915]] [PLANE:63:plane 6A] disabled, scaler_id = -1
<7> [228.979768] [drm:intel_dump_pipe_config [i915]] [PLANE:70:plane 7A] disabled, scaler_id = -1
<7> [228.979819] [drm:intel_dump_pipe_config [i915]] [PLANE:77:cursor A] disabled, scaler_id = -1
<7> [228.979863] [drm:intel_atomic_check [i915]] New cdclk calculated to be logical 307200 kHz, actual 307200 kHz
<7> [228.979897] [drm:intel_atomic_check [i915]] New voltage level calculated to be logical 0, actual 0
<7> [228.979939] [drm:intel_find_shared_dpll [i915]] [CRTC:80:pipe A] allocated MG PLL 1
<7> [228.979977] [drm:intel_reference_shared_dpll [i915]] using MG PLL 1 for pipe A
<7> [228.980079] [drm:skl_compute_wm [i915]] [PLANE:28:plane 1A] ddb (0 - 992) -> (0 - 0)
<7> [228.980103] [drm:skl_compute_wm [i915]] [PLANE:77:cursor A] ddb (992 - 1024) -> (0 - 0)
<7> [229.011897] [drm:hsw_audio_codec_disable [i915]] Disable audio codec on pipe A
<7> [229.011948] [drm:intel_disable_pipe [i915]] disabling pipe A
<7> [229.046824] [drm:intel_power_well_disable [i915]] disabling DDI C IO
<7> [229.046859] [drm:intel_power_well_disable [i915]] disabling AUX C
<7> [229.046902] [drm:__intel_fbc_disable [i915]] Disabling FBC on pipe A
<7> [229.046943] [drm:intel_disable_shared_dpll [i915]] disable MG PLL 1 (active 1, on? 1) for crtc 80
<7> [229.046995] [drm:intel_disable_shared_dpll [i915]] disabling MG PLL 1
<7> [229.047042] [drm:intel_atomic_commit_tail [i915]] [ENCODER:187:DDI A]
<7> [229.047081] [drm:intel_atomic_commit_tail [i915]] [ENCODER:195:DDI B]
<7> [229.049483] [drm:intel_dump_pipe_config [i915]] planes on this crtc
<4> [229.051698] Hardware name: Intel Corporation Ice Lake Client Platform/IceLake U DDR4 SODIMM PD RVP TLC, BIOS ICLSFWR1.R00.2402.AD3.1810170014 10/17/2018
<4> [229.051729] RIP: 0010:icl_program_mg_dp_mode+0xe6/0x180 [i915]
<4> [229.051731] Code: 48 89 df b9 01 00 00 00 5b 5d 41 5c 41 5d 41 5e 41 5f e9 7d 21 86 e1 48 c7 c6 8b f6 42 a0 48 c7 c7 57 f6 42 a0 e8 ea 6e ce e0 <0f> 0b 5b 5d 41 5c 41 5d 41 5e 41 5f c3 24 3f ba 01 00 00 00 be a0
<4> [229.051733] RSP: 0018:ffffc90000c73918 EFLAGS: 00010286
<4> [229.051736] RAX: 0000000000000000 RBX: ffff888493180000 RCX: 0000000000000000
<4> [229.051737] RDX: 0000000000000007 RSI: ffffffff820c70c8 RDI: 00000000ffffffff
<4> [229.051739] RBP: 00000000001687a0 R08: 0000000083422804 R09: 0000000000000000
<4> [229.051741] R10: 0000000000000000 R11: 0000000000000000 R12: ffff88849bd80008
<4> [229.051743] R13: 000000000a0038fe R14: 00000000001683a0 R15: 0000000000000000
<4> [229.051745] FS:  00007f5be38f2980(0000) GS:ffff8884aff80000(0000) knlGS:0000000000000000
<4> [229.051747] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
<4> [229.051749] CR2: 000056496e7995f8 CR3: 000000042b0bc003 CR4: 0000000000760ee0
<4> [229.051750] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
<4> [229.051752] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
<4> [229.051754] PKRU: 55555554
<4> [229.051755] Call Trace:
<4> [229.051789]  intel_ddi_pre_enable+0x588/0x8d0 [i915]
<4> [229.051826]  intel_encoders_pre_enable.isra.13+0x61/0x80 [i915]
<4> [229.051860]  haswell_crtc_enable+0x8f/0x7f0 [i915]
<4> [229.051893]  ? icl_pll_get_hw_state+0x5f/0x280 [i915]
<4> [229.051924]  intel_update_crtc+0x54/0x2b0 [i915]
<4> [229.051955]  skl_update_crtcs+0x266/0x2b0 [i915]
<4> [229.051989]  intel_atomic_commit_tail+0x1ea/0xd60 [i915]
<4> [229.052022]  intel_atomic_commit+0x244/0x330 [i915]
<4> [229.052028]  drm_atomic_connector_commit_dpms+0xe0/0xf0
<4> [229.052034]  set_property_atomic+0xb5/0x140
<4> [229.052044]  drm_mode_obj_set_property_ioctl+0x10f/0x1d0
<4> [229.052048]  ? drm_connector_set_obj_prop+0x70/0x70
<4> [229.052051]  drm_connector_property_set_ioctl+0x39/0x60
<4> [229.052056]  drm_ioctl_kernel+0x81/0xf0
<4> [229.052061]  drm_ioctl+0x2de/0x390
<4> [229.052065]  ? drm_connector_set_obj_prop+0x70/0x70
<4> [229.052073]  ? __might_fault+0x39/0x90
<4> [229.052080]  do_vfs_ioctl+0xa0/0x6e0
<4> [229.052084]  ? lock_acquire+0xa6/0x1c0
<4> [229.052088]  ? __task_pid_nr_ns+0xb9/0x1f0
<4> [229.052093]  ksys_ioctl+0x35/0x60
<4> [229.052097]  __x64_sys_ioctl+0x11/0x20
<4> [229.052100]  do_syscall_64+0x55/0x190
<4> [229.052105]  entry_SYSCALL_64_after_hwframe+0x49/0xbe
<4> [229.052108] RIP: 0033:0x7f5be263c5d7
<4> [229.052112] RSP: 002b:00007fffc0406298 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
Comment 1 Martin Peres 2018-12-03 11:41:00 UTC
More tests are triggering this:

https://intel-gfx-ci.01.org/tree/drm-tip/drmtip_151/fi-icl-u3/igt@kms_flip@2x-flip-vs-dpms-off-vs-modeset.html

https://intel-gfx-ci.01.org/tree/drm-tip/drmtip_153/fi-icl-u3/igt@kms_flip@dpms-vs-vblank-race.html

https://intel-gfx-ci.01.org/tree/drm-tip/drmtip_152/fi-icl-u3/igt@kms_vblank@pipe-a-ts-continuation-idle.html

https://intel-gfx-ci.01.org/tree/drm-tip/drmtip_152/fi-icl-u3/igt@kms_plane@plane-position-hole-dpms-pipe-b-planes.html

https://intel-gfx-ci.01.org/tree/drm-tip/drmtip_152/fi-icl-u3/igt@kms_flip@2x-single-buffer-flip-vs-dpms-off-vs-modeset.html

https://intel-gfx-ci.01.org/tree/drm-tip/drmtip_152/fi-icl-u3/igt@kms_flip@bo-too-big.html

https://intel-gfx-ci.01.org/tree/drm-tip/drmtip_152/fi-icl-u3/igt@kms_plane@plane-position-hole-dpms-pipe-c-planes.html

https://intel-gfx-ci.01.org/tree/drm-tip/drmtip_151/fi-icl-u3/igt@kms_flip@2x-flip-vs-modeset-interruptible.html

https://intel-gfx-ci.01.org/tree/drm-tip/drmtip_151/fi-icl-u3/igt@kms_plane@plane-position-hole-dpms-pipe-a-planes.html

<4> [538.031523] ------------[ cut here ]------------
<4> [538.031525] Missing case (intel_dig_port->tc_type == 0)
<4> [538.031590] WARNING: CPU: 1 PID: 1158 at drivers/gpu/drm/i915/intel_ddi.c:3091 icl_program_mg_dp_mode+0xe6/0x180 [i915]
<4> [538.031592] Modules linked in: vgem snd_hda_codec_hdmi snd_hda_codec_realtek snd_hda_codec_generic x86_pkg_temp_thermal coretemp i915 crct10dif_pclmul crc32_pclmul ghash_clmulni_intel snd_hda_intel e1000e snd_hda_codec btusb btrtl btbcm snd_hwdep btintel snd_hda_core bluetooth snd_pcm i2c_i801 cdc_ether usbnet mii ecdh_generic prime_numbers
<4> [538.031619] CPU: 1 PID: 1158 Comm: kms_plane Tainted: G     U            4.20.0-rc4-gb3a448de6828-drmtip_151+ #1
<4> [538.031622] Hardware name: Intel Corporation Ice Lake Client Platform/IceLake U DDR4 SODIMM PD RVP TLC, BIOS ICLSFWR1.R00.2402.AD3.1810170014 10/17/2018
<4> [538.031636] RIP: 0010:icl_program_mg_dp_mode+0xe6/0x180 [i915]
<4> [538.031636] Code: 48 89 df b9 01 00 00 00 5b 5d 41 5c 41 5d 41 5e 41 5f e9 7d 33 63 d8 48 c7 c6 02 c0 65 c0 48 c7 c7 ce bf 65 c0 e8 fa c9 ab d7 <0f> 0b 5b 5d 41 5c 41 5d 41 5e 41 5f c3 24 3f ba 01 00 00 00 be a0
<4> [538.031636] RSP: 0018:ffffb3b2806c7918 EFLAGS: 00010286
<4> [538.031636] RAX: 0000000000000000 RBX: ffff9c0b54e00000 RCX: 0000000000000000
<4> [538.031636] RDX: 0000000000000007 RSI: ffffffff99087c2b RDI: 00000000ffffffff
<4> [538.031636] RBP: 00000000001687a0 R08: 000000000554024b R09: 0000000000000000
<4> [538.031636] R10: 0000000000000000 R11: 0000000000000000 R12: ffff9c0b62988008
<4> [538.031636] R13: 000000000a0038fe R14: 00000000001683a0 R15: 0000000000000000
<4> [538.031636] FS:  00007f899f724980(0000) GS:ffff9c0b6fe80000(0000) knlGS:0000000000000000
<4> [538.031636] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
<4> [538.031636] CR2: 000055660fe1c900 CR3: 00000004a8be8005 CR4: 0000000000760ee0
<4> [538.031636] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
<4> [538.031636] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
<4> [538.031636] PKRU: 55555554
<4> [538.031636] Call Trace:
<4> [538.031636]  intel_ddi_pre_enable+0x47b/0x7c0 [i915]
<4> [538.031636]  intel_encoders_pre_enable.isra.13+0x61/0x80 [i915]
<4> [538.031799]  haswell_crtc_enable+0x8f/0x7f0 [i915]
<4> [538.031799]  ? icl_pll_get_hw_state+0x5f/0x280 [i915]
<4> [538.031799]  intel_update_crtc+0x54/0x2b0 [i915]
<4> [538.031799]  skl_update_crtcs+0x266/0x2b0 [i915]
<4> [538.031799]  intel_atomic_commit_tail+0x1ea/0xd60 [i915]
<4> [538.031799]  intel_atomic_commit+0x244/0x330 [i915]
<4> [538.031799]  drm_atomic_connector_commit_dpms+0xe0/0xf0
<4> [538.031799]  set_property_atomic+0xb5/0x140
<4> [538.031799]  drm_mode_obj_set_property_ioctl+0x10f/0x1d0
<4> [538.031799]  ? drm_connector_set_obj_prop+0x70/0x70
<4> [538.031799]  drm_connector_property_set_ioctl+0x39/0x60
<4> [538.031799]  drm_ioctl_kernel+0x81/0xf0
<4> [538.031799]  drm_ioctl+0x2de/0x390
<4> [538.031799]  ? drm_connector_set_obj_prop+0x70/0x70
<4> [538.031799]  ? _raw_spin_unlock_irq+0x24/0x50
<4> [538.031799]  ? lockdep_hardirqs_on+0xe0/0x1b0
<4> [538.031799]  do_vfs_ioctl+0xa0/0x6e0
<4> [538.031799]  ? __schedule+0x36c/0xb50
<4> [538.031799]  ksys_ioctl+0x35/0x60
<4> [538.031799]  __x64_sys_ioctl+0x11/0x20
<4> [538.031799]  do_syscall_64+0x55/0x190
<4> [538.031799]  entry_SYSCALL_64_after_hwframe+0x49/0xbe
<4> [538.031799] RIP: 0033:0x7f899edd55d7
<4> [538.031799] Code: b3 66 90 48 8b 05 b1 48 2d 00 64 c7 00 26 00 00 00 48 c7 c0 ff ff ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 b8 10 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 8b 0d 81 48 2d 00 f7 d8 64 89 01 48
<4> [538.031799] RSP: 002b:00007ffe094c64a8 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
<4> [538.031799] RAX: ffffffffffffffda RBX: 00007f899f323598 RCX: 00007f899edd55d7
<4> [538.031799] RDX: 00007ffe094c64e0 RSI: 00000000c01064ab RDI: 0000000000000005
<4> [538.031799] RBP: 00007ffe094c64e0 R08: 00007ffe094c64e1 R09: 0000000000000000
<4> [538.031799] R10: 00007f899ee5dcc0 R11: 0000000000000246 R12: 00000000c01064ab
<4> [538.031799] R13: 0000000000000005 R14: 0000000000000000 R15: 0000000000000000
<4> [538.031799] irq event stamp: 1527490
<4> [538.031799] hardirqs last  enabled at (1527489): [<ffffffff980fef59>] console_unlock+0x3f9/0x5f0
<4> [538.031799] hardirqs last disabled at (1527490): [<ffffffff980019b0>] trace_hardirqs_off_thunk+0x1a/0x1c
<4> [538.031799] softirqs last  enabled at (1527230): [<ffffffff98c0033a>] __do_softirq+0x33a/0x4b9
<4> [538.031799] softirqs last disabled at (1527223): [<ffffffff980929f9>] irq_exit+0xa9/0xc0
<4> [538.031799] WARNING: CPU: 1 PID: 1158 at drivers/gpu/drm/i915/intel_ddi.c:3091 icl_program_mg_dp_mode+0xe6/0x180 [i915]
<4> [538.031799] ---[ end trace 0aa4377a89b215c7 ]---
Comment 2 Imre Deak 2018-12-03 14:32:06 UTC
This is similar to
https://bugs.freedesktop.org/show_bug.cgi?id=108070

HPD arriving at the wrong moment while we are trying to do a modeset. I think the solution for both issues will be to keep the port switched to TypeC native mode according to the patch below. Before going with such a change though we would need (a) confirmation from HW people that it's safe to do this and (b) a new flag in VBT that marks the port as TypeC native (vs. being a TypeC USB alternate/Thunderbolt DP port). The VBT flag would allow us to switch to native mode right after driver loading, eliminating problems with other use-cases (DP AUX reading from userspace, modesetting on a port without a sink being connected). I have opened company internal tickets to track both (a) and (b) issues, once those are resolved somehow I will follow up here.

commit 1d4ea665f65445817220a7956bf8bca3bd8686e2
Author: Imre Deak <imre.deak@intel.com>
Date:   Fri Nov 30 23:01:56 2018 +0200

    drm/i915/icl: Remain in legacy mode after TC port disconnect IRQ
    
    Signed-off-by: Imre Deak <imre.deak@intel.com>

diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
index 70ae3d57316b..41f9883240cd 100644
--- a/drivers/gpu/drm/i915/intel_dp.c
+++ b/drivers/gpu/drm/i915/intel_dp.c
@@ -4948,6 +4948,12 @@ static void icl_tc_phy_disconnect(struct drm_i915_private *dev_priv,
 	if (dig_port->tc_type == TC_PORT_UNKNOWN)
 		return;
 
+	if (dig_port->tc_type == TC_PORT_LEGACY) {
+		DRM_DEBUG_DRIVER("Keep TC port %c in legacy mode after disconnect\n",
+				 port_name(dig_port->base.port));
+		return;
+	}
+
 	/*
 	 * TBT disconnection flow is read the live status, what was done in
 	 * caller.
Comment 3 Imre Deak 2018-12-17 20:55:06 UTC
*** Bug 109044 has been marked as a duplicate of this bug. ***
Comment 4 Jani Saarinen 2018-12-18 19:40:45 UTC
Isn't this now merged? Resolving as fixed.
Comment 5 Francesco Balestrieri 2018-12-28 08:33:47 UTC
This particular error hasn't been seen for more than a week, closing. Note that CI Buglog still matches this bug with other failures though.


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.