Re: [igt-dev] ✗ Fi.CI.BAT: failure for igt/i915/i915_pm_lpsp enable pm_lpsp for platforms till Gen11 v3

Imre Deak
2019-04-24T08:21:17Z

On Wed, Apr 24, 2019 at 11:16:00AM +0530, Gupta, Anshuman wrote:
> Hi Imre ,
> Sometimes it has been observed on Gen9 that screens-disabled i915_pm_lpsp
> sub-test failed because power well 2 was not disabled when subtest checks
> its register value. It get disabled slightly later.
>
> https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_2866/fi-cfl-8109u/igt@i915_pm_lpsp@screens-disabled.html
>
> I checked it locally and found similar behaviour (there were three screens
> connected in my test), below are the log snippet.
>
> [ 254.042328] [IGT] i915_pm_lpsp: starting subtest screens-disabled
> [ 254.042374] [drm:drm_mode_setcrtc] [CRTC:47:pipe A]
> [ 254.250784] [drm:intel_disable_pipe [i915]] disabling pipe A
> [ 254.421970] [drm:drm_mode_setcrtc] Returning [CRTC:47:pipe A]
> (kernel instrumenting log to indicate drm_mode_setcrtc has returned)
> [ 254.421990] [drm:drm_mode_setcrtc] [CRTC:65:pipe B]
> [ 254.423605] [drm:intel_disable_pipe [i915]] disabling pipe B
> [ 254.437460] [drm:drm_mode_setcrtc] Returning [CRTC:65:pipe B]
> [ 254.437476] [drm:drm_mode_setcrtc] [CRTC:83:pipe C]
> [ 254.438526] [drm:intel_disable_pipe [i915]] disabling pipe C
> [ 254.456603] [drm:drm_mode_setcrtc] Returning [CRTC:83:pipe C]
> [ 254.464966] [drm:intel_power_well_disable [i915]] disabling power well 2
>
> We can see power well 2 is getting disabled after 8ms of drm_mode_setcrtc()
> ioctl returned, which is sufficient to fail the test.
>
> Do u see any issue with driver behaviour.
>
> If it is expected behaviour from i915 driver then we may need to have
> some wait while checking the power well 2 for lpsp.

I think the only reason can be delayed audio disabling. In the above CFL
log I see, which would point to that:

<7> [235.044427] [drm:hsw_audio_codec_disable [i915]] Disable audio codec on pipe A

I haven't managed to track this down in the depths of the HDA runtime PM
code, but I suspect it will result in a - delayed - runtime PM put on
the HDA device which will end up calling
i915_audio_component_put_power(), that drops the PW#2 reference.

You could prove this by dumping debugfs/i915_runtime_pm_status and
i915_power_domain_info when you see PW#2 still on after the IOCTL
returned. You should btw make this debug output part of the test,
perhaps even making a generic helper that we could call in similar
failing scenarios.

If that proves to be the case, the solution is to wait for PW#2 to go
off with some timeout as you suggested.

Thanks for the investigate work!

>
> Thanks ,
> Anshuman Gupta.
> On 4/16/2019 7:47 PM, Patchwork wrote:
> > == Series Details ==
> >
> > Series: igt/i915/i915_pm_lpsp enable pm_lpsp for platforms till Gen11 v3
> > URL : https://patchwork.freedesktop.org/series/59581/
> > State : failure
> >
> > == Summary ==
> >
> > CI Bug Log - changes from CI_DRM_5938 -> IGTPW_2866
> > ====================================================
> >
> > Summary
> > -------
> >
> > **FAILURE**
> >
> > Serious unknown changes coming with IGTPW_2866 absolutely need to be
> > verified manually.
> > If you think the reported changes have nothing to do with the changes
> > introduced in IGTPW_2866, please notify your bug team to allow them
> > to document this new failure mode, which will reduce false positives in CI.
> >
> > External URL: https://patchwork.freedesktop.org/api/1.0/series/59581/revisions/1/mbox/
> >
> > Possible new issues
> > -------------------
> >
> > Here are the unknown changes that may have been introduced in IGTPW_2866:
> >
> > ### IGT changes ###
> >
> > #### Possible regressions ####
> >
> > * igt@i915_pm_lpsp@edp-panel-fitter:
> > - fi-icl-y: NOTRUN -> SKIP +1
> > - fi-icl-u3: NOTRUN -> SKIP
> >
> > * igt@i915_pm_lpsp@non-edp:
> > - fi-bxt-j4205: NOTRUN -> FAIL
> >
> > * igt@i915_pm_lpsp@screens-disabled:
> > - fi-cfl-8109u: NOTRUN -> FAIL
> >
> > Known issues
> > ------------
> >
> > Here are the changes found in IGTPW_2866 that come from known issues:
> >
> > ### IGT changes ###
> >
> > #### Issues hit ####
> >
> > * igt@amdgpu/amd_basic@semaphore:
> > - fi-bdw-5557u: NOTRUN -> SKIP [fdo#109271] +40
> >
> > * igt@amdgpu/amd_cs_nop@fork-compute0:
> > - fi-icl-y: NOTRUN -> SKIP [fdo#109315] +17
> >
> > * igt@amdgpu/amd_cs_nop@sync-fork-compute0:
> > - fi-icl-u3: NOTRUN -> SKIP [fdo#109315] +17
> >
> > * igt@gem_exec_basic@basic-bsd2:
> > - fi-icl-y: NOTRUN -> SKIP [fdo#109276] +7
> >
> > * igt@gem_exec_basic@gtt-bsd1:
> > - fi-icl-u3: NOTRUN -> SKIP [fdo#109276] +7
> >
> > * igt@gem_exec_parse@basic-rejected:
> > - fi-icl-u3: NOTRUN -> SKIP [fdo#109289] +1
> > - fi-icl-y: NOTRUN -> SKIP [fdo#109289] +1
> >
> > * igt@gem_exec_suspend@basic-s3:
> > - fi-blb-e6850: PASS -> INCOMPLETE [fdo#107718]
> >
> > * igt@i915_pm_lpsp@edp-native:
> > - fi-hsw-4770r: NOTRUN -> SKIP [fdo#109271] +1
> > - fi-pnv-d510: NOTRUN -> SKIP [fdo#109271] +3
> > - fi-snb-2520m: NOTRUN -> SKIP [fdo#109271] +3
> > - fi-byt-clapper: NOTRUN -> SKIP [fdo#109271] +3
> > - fi-kbl-x1275: NOTRUN -> SKIP [fdo#109271] +1
> > - fi-skl-lmem: NOTRUN -> SKIP [fdo#109271] +1
> > - fi-bwr-2160: NOTRUN -> SKIP [fdo#109271] +3
> > - fi-skl-6770hq: NOTRUN -> SKIP [fdo#109271] +1
> > - fi-kbl-8809g: NOTRUN -> SKIP [fdo#109271] +2
> > - fi-kbl-guc: NOTRUN -> SKIP [fdo#109271] +2
> > - fi-hsw-4770: NOTRUN -> SKIP [fdo#109271] +2
> > - fi-skl-gvtdvm: NOTRUN -> SKIP [fdo#109271] +1
> > - fi-skl-6700k2: NOTRUN -> SKIP [fdo#109271] +1
> > - fi-bxt-dsi: NOTRUN -> SKIP [fdo#109271] +2
> > - fi-skl-iommu: NOTRUN -> SKIP [fdo#109271] +1
> > - fi-cfl-guc: NOTRUN -> SKIP [fdo#109271] +1
> > - fi-skl-guc: NOTRUN -> SKIP [fdo#109271] +1
> > - fi-cfl-8700k: NOTRUN -> SKIP [fdo#109271] +1
> > - fi-apl-guc: NOTRUN -> SKIP [fdo#109271] +1
> > - fi-cfl-8109u: NOTRUN -> SKIP [fdo#109271] +1
> > - fi-bxt-j4205: NOTRUN -> SKIP [fdo#109271] +1
> >
> > * igt@i915_pm_lpsp@edp-panel-fitter:
> > - fi-ilk-650: NOTRUN -> SKIP [fdo#109271] +3
> > - fi-bdw-gvtdvm: NOTRUN -> SKIP [fdo#109271] +1
> > - fi-hsw-peppy: NOTRUN -> FAIL [fdo#106602]
> > - fi-skl-6600u: NOTRUN -> SKIP [fdo#109271] +1
> >
> > * igt@i915_pm_lpsp@non-edp:
> > - fi-byt-n2820: NOTRUN -> SKIP [fdo#109271] +3
> > - fi-ivb-3770: NOTRUN -> SKIP [fdo#109271] +3
> > - fi-byt-j1900: NOTRUN -> SKIP [fdo#109271] +3
> > - fi-snb-2600: NOTRUN -> SKIP [fdo#109271] +3
> > - fi-kbl-r: NOTRUN -> SKIP [fdo#109271] +1
> > - fi-hsw-peppy: NOTRUN -> SKIP [fdo#109271]
> > - fi-whl-u: NOTRUN -> SKIP [fdo#109271] +1
> >
> > * igt@i915_pm_lpsp@screens-disabled:
> > - fi-elk-e7500: NOTRUN -> SKIP [fdo#109271] +3
> > - fi-gdg-551: NOTRUN -> SKIP [fdo#109271] +3
> > - fi-bsw-kefka: NOTRUN -> SKIP [fdo#109271] +3
> >
> > * igt@i915_selftest@live_contexts:
> > - fi-bdw-gvtdvm: PASS -> DMESG-FAIL [fdo#110235 ]
> >
> > * igt@kms_chamelium@dp-crc-fast:
> > - fi-icl-y: NOTRUN -> SKIP [fdo#109284] +8
> >
> > * igt@kms_chamelium@hdmi-edid-read:
> > - fi-icl-u3: NOTRUN -> SKIP [fdo#109284] +8
> >
> > * igt@kms_cursor_legacy@basic-flip-before-cursor-varying-size:
> > - fi-glk-dsi: PASS -> INCOMPLETE [fdo#103359] / [k.org#198133]
> >
> > * igt@kms_force_connector_basic@force-load-detect:
> > - fi-icl-y: NOTRUN -> SKIP [fdo#109285] +3
> >
> > * igt@kms_force_connector_basic@prune-stale-modes:
> > - fi-icl-u3: NOTRUN -> SKIP [fdo#109285] +3
> >
> > * igt@kms_frontbuffer_tracking@basic:
> > - fi-icl-u3: NOTRUN -> FAIL [fdo#103167]
> >
> > * igt@kms_psr@cursor_plane_move:
> > - fi-skl-6260u: NOTRUN -> SKIP [fdo#109271] +39
> >
> > * igt@kms_psr@primary_mmap_gtt:
> > - fi-icl-y: NOTRUN -> SKIP [fdo#110189] +3
> >
> > * igt@prime_vgem@basic-fence-flip:
> > - fi-icl-y: NOTRUN -> SKIP [fdo#109294]
> >
> > #### Possible fixes ####
> >
> > * igt@i915_selftest@live_execlists:
> > - fi-apl-guc: INCOMPLETE [fdo#103927] / [fdo#109720] -> PASS
> >
> > {name}: This element is suppressed. This means it is ignored when computing
> > the status of the difference (SUCCESS, WARNING, or FAILURE).
> >
> > [fdo#103167]: https://bugs.freedesktop.org/show_bug.cgi?id=103167
> > [fdo#103359]: https://bugs.freedesktop.org/show_bug.cgi?id=103359
> > [fdo#103927]: https://bugs.freedesktop.org/show_bug.cgi?id=103927
> > [fdo#106602]: https://bugs.freedesktop.org/show_bug.cgi?id=106602
> > [fdo#107718]: https://bugs.freedesktop.org/show_bug.cgi?id=107718
> > [fdo#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
> > [fdo#109276]: https://bugs.freedesktop.org/show_bug.cgi?id=109276
> > [fdo#109284]: https://bugs.freedesktop.org/show_bug.cgi?id=109284
> > [fdo#109285]: https://bugs.freedesktop.org/show_bug.cgi?id=109285
> > [fdo#109289]: https://bugs.freedesktop.org/show_bug.cgi?id=109289
> > [fdo#109294]: https://bugs.freedesktop.org/show_bug.cgi?id=109294
> > [fdo#109315]: https://bugs.freedesktop.org/show_bug.cgi?id=109315
> > [fdo#109720]: https://bugs.freedesktop.org/show_bug.cgi?id=109720
> > [fdo#110189]: https://bugs.freedesktop.org/show_bug.cgi?id=110189
> > [fdo#110235 ]: https://bugs.freedesktop.org/show_bug.cgi?id=110235
> > [k.org#198133]: https://bugzilla.kernel.org/show_bug.cgi?id=198133
> >
> >
> > Participating hosts (47 -> 43)
> > ------------------------------
> >
> > Additional (3): fi-icl-y fi-bdw-5557u fi-skl-6260u
> > Missing (7): fi-kbl-soraka fi-ilk-m540 fi-hsw-4200u fi-bsw-n3050 fi-bsw-cyan fi-ctg-p8600 fi-bdw-samus
> >
> >
> > Build changes
> > -------------
> >
> > * IGT: IGT_4951 -> IGTPW_2866
> >
> > CI_DRM_5938: 61a332623362ea87cdde81115229b1b955335654 @ git://anongit.freedesktop.org/gfx-ci/linux
> > IGTPW_2866: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_2866/
> > IGT_4951: cc9a60c029432b5843724e4f2c57f9f815f7adbb @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools
> >
> > == Logs ==
> >
> > For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_2866/
> >