drm/i915/dp: Perform 30ms delay after source OUI write
PATCH 1/1 drm/i915/dp: Perform 30ms delay after source OUI write
While working on supporting the Intel HDR backlight interface, I noticed that there's a couple of laptops that will very rarely manage to boot up without detecting Intel HDR backlight support - even though it's supported on the system. One example of such a laptop is the Lenovo P17 1st generation.
Following some investigation Ville Syrjälä did through the docs they have available to them, they discovered that there's actually supposed to be a 30ms wait after writing the source OUI before we begin setting up the rest of the backlight interface.
This seems to be correct, as adding this 30ms delay seems to have completely fixed the probing issues I was previously seeing. So - let's start performing a 30ms wait after writing the OUI, which we do in a manner similar to how we keep track of PPS delays (e.g. record the timestamp of the OUI write, and then wait for however many ms are left since that timestamp right before we interact with the backlight) in order to avoid waiting any longer then we need to. As well, this also avoids us performing this delay on systems where we don't end up using the HDR backlight interface.
--- drivers/gpu/drm/i915/display/intel_display_types.h | 3 +++ drivers/gpu/drm/i915/display/intel_dp.c | 3 +++ drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 11 +++++++++++ 3 files changed, 17 insertions(+)
drivers/gpu/drm/i915/display/intel_display_types.h +3 -0
@@ -1653,6 +1653,9 @@ struct intel_dp {struct intel_dp_pcon_frl frl;struct intel_psr psr; + +/* When we last wrote the OUI for eDP */ +unsigned long last_oui_write; };enum lspcon_vendor {
drivers/gpu/drm/i915/display/intel_dp.c +3 -0
@@ -29,6 +29,7 @@#include <linux/i2c.h> #include <linux/notifier.h> #include <linux/slab.h> +#include <linux/timekeeping.h> #include <linux/types.h> #include <asm/byteorder.h>
@@ -2010,6 +2011,8 @@ intel_edp_init_source_oui(struct intel_dp *intel_dp, bool careful)if (drm_dp_dpcd_write (&intel_dp->aux,DP_SOURCE_OUI , oui,sizeof (oui)) <0 )drm_err (&i915->drm,"Failed to write source OUI\n" ); + + intel_dp->last_oui_write = jiffies; }/* If the device supports it, try to set the power state appropriately */
drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c +11 -0
@@ -96,6 +96,13 @@#define INTEL_EDP_BRIGHTNESS_OPTIMIZATION_1 0x359/* Intel EDP backlight callbacks */ +static void +wait_for_oui (struct drm_i915_private *i915,struct intel_dp *intel_dp) +{ +drm_dbg_kms (&i915->drm,"Performing OUI wait\n" ); +wait_remaining_ms_from_jiffies (intel_dp->last_oui_write,30 ); +} +static bool intel_dp_aux_supports_hdr_backlight (struct intel_connector *connector) {
@@ -106,6 +113,8 @@ intel_dp_aux_supports_hdr_backlight(struct intel_connector *connector)int ret;u8 tcon_cap[4 ]; +wait_for_oui (i915, intel_dp); + ret =drm_dp_dpcd_read (aux,INTEL_EDP_HDR_TCON_CAP0 , tcon_cap,sizeof (tcon_cap));if (ret !=sizeof (tcon_cap))return false;
@@ -204,6 +213,8 @@ intel_dp_aux_hdr_enable_backlight(const struct intel_crtc_state *crtc_state,int ret;u8 old_ctrl, ctrl; +wait_for_oui (i915, intel_dp); + ret =drm_dp_dpcd_readb (&intel_dp->aux,INTEL_EDP_HDR_GETSET_CTRL_PARAMS , &old_ctrl);if (ret !=1 ) {drm_err (&i915->drm,"Failed to read current backlight control mode: %d\n" , ret);
Signature · 1 line
2.31.1
Patchwork
CI[Intel-gfx] ✗ Fi.CI.DOCS: warning for drm/i915/dp: Perform 30ms delay after source OUI write
== Series Details ==
== Series Details ==
Series: drm/i915/dp: Perform 30ms delay after source OUI write
URL : https://patchwork.freedesktop.org/series/96871/
State : warning
== Summary ==
$ make htmldocs 2>&1 > /dev/null | grep i915 ./drivers/gpu/drm/i915/display/intel_fbc.c:635: warning: Excess function parameter 'i915' description in 'intel_fbc_is_active' ./drivers/gpu/drm/i915/display/intel_fbc.c:1638: warning: Excess function parameter 'i915' description in 'intel_fbc_handle_fifo_underrun_irq' ./drivers/gpu/drm/i915/display/intel_fbc.c:635: warning: Function parameter or member 'fbc' not described in 'intel_fbc_is_active' ./drivers/gpu/drm/i915/display/intel_fbc.c:635: warning: Excess function parameter 'i915' description in 'intel_fbc_is_active' ./drivers/gpu/drm/i915/display/intel_fbc.c:1638: warning: Function parameter or member 'fbc' not described in 'intel_fbc_handle_fifo_underrun_irq' ./drivers/gpu/drm/i915/display/intel_fbc.c:1638: warning: Excess function parameter 'i915' description in 'intel_fbc_handle_fifo_underrun_irq'
Patchwork
CI[Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915/dp: Perform 30ms delay after source OUI write
In reply to Lyude Paul== Series Details ==
== Series Details ==
Series: drm/i915/dp: Perform 30ms delay after source OUI write
URL : https://patchwork.freedesktop.org/series/96871/
State : success
== Summary ==
CI Bug Log - changes from CI_DRM_10877 -> Patchwork_21581
====================================================
Summary
-------
**SUCCESS**
No regressions found.
External URL: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/index.html
Participating hosts (30 -> 29)
------------------------------
Additional (2): fi-skl-6700k2 fi-pnv-d510
Missing (3): fi-bsw-cyan bat-dg1-6 bat-dg1-5
Known issues
------------
Here are the changes found in Patchwork_21581 that come from known issues:
### IGT changes ###
#### Issues hit ####
* igt@amdgpu/amd_basic@cs-gfx:
- fi-skl-6700k2: NOTRUN -> [SKIP][1] ([fdo#109271]) +28 similar issues
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/fi-skl-6700k2/igt@amdgpu/[email protected]
* igt@gem_huc_copy@huc-copy:
- fi-skl-6700k2: NOTRUN -> [SKIP][2] ([fdo#109271] / [i915#2190])
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/fi-skl-6700k2/igt@[email protected]
* igt@kms_chamelium@hdmi-crc-fast:
- fi-skl-6700k2: NOTRUN -> [SKIP][3] ([fdo#109271] / [fdo#111827]) +8 similar issues
[3]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/fi-skl-6700k2/igt@[email protected]
* igt@kms_pipe_crc_basic@compare-crc-sanitycheck-pipe-d:
- fi-skl-6700k2: NOTRUN -> [SKIP][4] ([fdo#109271] / [i915#533])
[4]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/fi-skl-6700k2/igt@[email protected]
* igt@prime_vgem@basic-userptr:
- fi-pnv-d510: NOTRUN -> [SKIP][5] ([fdo#109271]) +53 similar issues
[5]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/fi-pnv-d510/igt@[email protected]
#### Possible fixes ####
* igt@kms_frontbuffer_tracking@basic:
- fi-cml-u2: [DMESG-WARN][6] ([i915#4269]) -> [PASS][7]
[6]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/fi-cml-u2/igt@[email protected]
[7]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/fi-cml-u2/igt@[email protected]
[fdo#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
[fdo#111827]: https://bugs.freedesktop.org/show_bug.cgi?id=111827
[i915#2190]: https://gitlab.freedesktop.org/drm/intel/issues/2190
[i915#4269]: https://gitlab.freedesktop.org/drm/intel/issues/4269
[i915#533]: https://gitlab.freedesktop.org/drm/intel/issues/533
Build changes
-------------
* Linux: CI_DRM_10877 -> Patchwork_21581
CI-20190529: 20190529
CI_DRM_10877: 688d3ea17a90b4acf51de31ef08cd2b23799952e @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_6280: 246bfd31dba6bf184b26b170d91d72c90a54be6b @ https://gitlab.freedesktop.org/drm/igt-gpu-tools.git
Patchwork_21581: 56dd8cd7dadd44a32e1339993802920b322f1dad @ git://anongit.freedesktop.org/gfx-ci/linux
== Linux commits ==
56dd8cd7dadd drm/i915/dp: Perform 30ms delay after source OUI write
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/index.html
Patchwork
CI[Intel-gfx] ✓ Fi.CI.IGT: success for drm/i915/dp: Perform 30ms delay after source OUI write
In reply to Lyude Paul== Series Details ==
== Series Details ==
Series: drm/i915/dp: Perform 30ms delay after source OUI write
URL : https://patchwork.freedesktop.org/series/96871/
State : success
== Summary ==
CI Bug Log - changes from CI_DRM_10877_full -> Patchwork_21581_full
====================================================
Summary
-------
**SUCCESS**
No regressions found.
Participating hosts (10 -> 10)
------------------------------
No changes in participating hosts
Known issues
------------
Here are the changes found in Patchwork_21581_full that come from known issues:
### IGT changes ###
#### Issues hit ####
* igt@gem_exec_fair@basic-deadline:
- shard-skl: NOTRUN -> [FAIL][1] ([i915#2846])
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl9/igt@[email protected]
- shard-apl: NOTRUN -> [FAIL][2] ([i915#2846])
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl2/igt@[email protected]
* igt@gem_exec_fair@basic-pace-solo@rcs0:
- shard-tglb: [PASS][3] -> [FAIL][4] ([i915#2842])
[3]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-tglb1/igt@gem_exec_fair@[email protected]
[4]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-tglb5/igt@gem_exec_fair@[email protected]
* igt@gem_exec_fair@basic-pace@vcs0:
- shard-kbl: [PASS][5] -> [FAIL][6] ([i915#2842])
[5]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-kbl6/igt@gem_exec_fair@[email protected]
[6]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-kbl2/igt@gem_exec_fair@[email protected]
* igt@gem_exec_fair@basic-throttle@rcs0:
- shard-iclb: [PASS][7] -> [FAIL][8] ([i915#2849])
[7]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-iclb4/igt@gem_exec_fair@[email protected]
[8]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-iclb1/igt@gem_exec_fair@[email protected]
* igt@gem_exec_gttfill@all:
- shard-glk: [PASS][9] -> [DMESG-WARN][10] ([i915#118])
[9]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-glk2/igt@[email protected]
[10]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-glk9/igt@[email protected]
* igt@gem_huc_copy@huc-copy:
- shard-apl: NOTRUN -> [SKIP][11] ([fdo#109271] / [i915#2190])
[11]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl7/igt@[email protected]
* igt@gem_pwrite@basic-exhaustion:
- shard-kbl: NOTRUN -> [WARN][12] ([i915#2658])
[12]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-kbl2/igt@[email protected]
* igt@gem_userptr_blits@input-checking:
- shard-apl: NOTRUN -> [DMESG-WARN][13] ([i915#3002]) +1 similar issue
[13]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl1/igt@[email protected]
- shard-kbl: NOTRUN -> [DMESG-WARN][14] ([i915#3002])
[14]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-kbl3/igt@[email protected]
* igt@gem_userptr_blits@vma-merge:
- shard-apl: NOTRUN -> [FAIL][15] ([i915#3318])
[15]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl1/igt@[email protected]
- shard-kbl: NOTRUN -> [FAIL][16] ([i915#3318])
[16]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-kbl3/igt@[email protected]
* igt@i915_pm_backlight@fade_with_suspend:
- shard-tglb: [PASS][17] -> [INCOMPLETE][18] ([i915#456]) +1 similar issue
[17]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-tglb8/igt@i915_pm_backlight@fade_with_suspend.html
[18]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-tglb7/igt@i915_pm_backlight@fade_with_suspend.html
* igt@kms_big_fb@x-tiled-max-hw-stride-64bpp-rotate-180-async-flip:
- shard-skl: NOTRUN -> [FAIL][19] ([i915#3743])
[19]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl4/igt@kms_big_fb@x-tiled-max-hw-stride-64bpp-rotate-180-async-flip.html
* igt@kms_big_fb@y-tiled-max-hw-stride-32bpp-rotate-0-hflip:
- shard-apl: NOTRUN -> [SKIP][20] ([fdo#109271] / [i915#3777])
[20]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl4/igt@[email protected]
* igt@kms_ccs@pipe-a-missing-ccs-buffer-y_tiled_gen12_rc_ccs_cc:
- shard-apl: NOTRUN -> [SKIP][21] ([fdo#109271] / [i915#3886]) +9 similar issues
[21]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl3/igt@kms_ccs@pipe-a-missing-ccs-buffer-y_tiled_gen12_rc_ccs_cc.html
* igt@kms_ccs@pipe-c-bad-pixel-format-y_tiled_gen12_rc_ccs_cc:
- shard-kbl: NOTRUN -> [SKIP][22] ([fdo#109271] / [i915#3886]) +4 similar issues
[22]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-kbl2/igt@kms_ccs@pipe-c-bad-pixel-format-y_tiled_gen12_rc_ccs_cc.html
* igt@kms_ccs@pipe-c-crc-sprite-planes-basic-y_tiled_gen12_mc_ccs:
- shard-skl: NOTRUN -> [SKIP][23] ([fdo#109271] / [i915#3886]) +5 similar issues
[23]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl9/igt@kms_ccs@pipe-c-crc-sprite-planes-basic-y_tiled_gen12_mc_ccs.html
* igt@kms_chamelium@dp-edid-change-during-suspend:
- shard-apl: NOTRUN -> [SKIP][24] ([fdo#109271] / [fdo#111827]) +11 similar issues
[24]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl2/igt@[email protected]
* igt@kms_chamelium@dp-hpd-storm-disable:
- shard-skl: NOTRUN -> [SKIP][25] ([fdo#109271] / [fdo#111827]) +9 similar issues
[25]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl4/igt@[email protected]
* igt@kms_color@pipe-b-ctm-0-25:
- shard-skl: [PASS][26] -> [DMESG-WARN][27] ([i915#1982]) +1 similar issue
[26]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-skl9/igt@[email protected]
[27]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl10/igt@[email protected]
* igt@kms_color@pipe-c-ctm-0-5:
- shard-skl: NOTRUN -> [DMESG-WARN][28] ([i915#1982])
[28]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl4/igt@[email protected]
* igt@kms_color_chamelium@pipe-d-ctm-green-to-red:
- shard-kbl: NOTRUN -> [SKIP][29] ([fdo#109271] / [fdo#111827]) +3 similar issues
[29]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-kbl2/igt@[email protected]
* igt@kms_content_protection@atomic:
- shard-kbl: NOTRUN -> [TIMEOUT][30] ([i915#1319])
[30]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-kbl3/igt@[email protected]
* igt@kms_content_protection@lic:
- shard-apl: NOTRUN -> [TIMEOUT][31] ([i915#1319]) +2 similar issues
[31]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl8/igt@[email protected]
* igt@kms_content_protection@uevent:
- shard-kbl: NOTRUN -> [FAIL][32] ([i915#2105])
[32]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-kbl3/igt@[email protected]
- shard-apl: NOTRUN -> [FAIL][33] ([i915#2105])
[33]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl1/igt@[email protected]
* igt@kms_cursor_crc@pipe-a-cursor-128x42-offscreen:
- shard-glk: [PASS][34] -> [FAIL][35] ([i915#3444])
[34]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-glk4/igt@[email protected]
[35]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-glk6/igt@[email protected]
* igt@kms_cursor_crc@pipe-b-cursor-suspend:
- shard-tglb: [PASS][36] -> [INCOMPLETE][37] ([i915#2411] / [i915#456])
[36]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-tglb2/igt@[email protected]
[37]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-tglb7/igt@[email protected]
* igt@kms_cursor_legacy@pipe-d-torture-bo:
- shard-apl: NOTRUN -> [SKIP][38] ([fdo#109271] / [i915#533]) +1 similar issue
[38]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl7/igt@[email protected]
* igt@kms_flip@flip-vs-expired-vblank-interruptible@a-edp1:
- shard-skl: [PASS][39] -> [FAIL][40] ([i915#79]) +1 similar issue
[39]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-skl10/igt@kms_flip@[email protected]
[40]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl8/igt@kms_flip@[email protected]
* igt@kms_flip@flip-vs-suspend-interruptible@a-dp1:
- shard-apl: [PASS][41] -> [DMESG-WARN][42] ([i915#180]) +3 similar issues
[41]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-apl8/igt@kms_flip@[email protected]
[42]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl7/igt@kms_flip@[email protected]
* igt@kms_flip@plain-flip-fb-recreate-interruptible@c-edp1:
- shard-skl: NOTRUN -> [FAIL][43] ([i915#2122]) +1 similar issue
[43]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl4/igt@kms_flip@[email protected]
* igt@kms_flip@plain-flip-ts-check@c-edp1:
- shard-skl: [PASS][44] -> [FAIL][45] ([i915#2122]) +2 similar issues
[44]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-skl10/igt@kms_flip@[email protected]
[45]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl8/igt@kms_flip@[email protected]
* igt@kms_flip_scaled_crc@flip-32bpp-ytile-to-32bpp-ytileccs:
- shard-iclb: [PASS][46] -> [SKIP][47] ([i915#3701])
[46]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-iclb5/igt@[email protected]
[47]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-iclb2/igt@[email protected]
* igt@kms_flip_scaled_crc@flip-64bpp-ytile-to-32bpp-ytilercccs:
- shard-apl: NOTRUN -> [SKIP][48] ([fdo#109271] / [i915#2672])
[48]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl8/igt@[email protected]
* igt@kms_frontbuffer_tracking@fbc-1p-shrfb-fliptrack-mmap-gtt:
- shard-skl: NOTRUN -> [SKIP][49] ([fdo#109271]) +147 similar issues
[49]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl7/igt@[email protected]
* igt@kms_frontbuffer_tracking@fbc-2p-scndscrn-spr-indfb-draw-mmap-wc:
- shard-apl: NOTRUN -> [SKIP][50] ([fdo#109271]) +135 similar issues
[50]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl8/igt@kms_frontbuffer_tracking@fbc-2p-scndscrn-spr-indfb-draw-mmap-wc.html
* igt@kms_frontbuffer_tracking@psr-1p-primscrn-spr-indfb-draw-mmap-cpu:
- shard-kbl: NOTRUN -> [SKIP][51] ([fdo#109271]) +55 similar issues
[51]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-kbl3/igt@kms_frontbuffer_tracking@psr-1p-primscrn-spr-indfb-draw-mmap-cpu.html
* igt@kms_pipe_crc_basic@hang-read-crc-pipe-d:
- shard-skl: NOTRUN -> [SKIP][52] ([fdo#109271] / [i915#533])
[52]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl7/igt@[email protected]
* igt@kms_plane_alpha_blend@pipe-a-alpha-7efc:
- shard-skl: NOTRUN -> [FAIL][53] ([fdo#108145] / [i915#265]) +2 similar issues
[53]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl4/igt@[email protected]
* igt@kms_plane_alpha_blend@pipe-b-constant-alpha-max:
- shard-kbl: NOTRUN -> [FAIL][54] ([fdo#108145] / [i915#265])
[54]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-kbl2/igt@[email protected]
* igt@kms_psr2_sf@overlay-plane-update-sf-dmg-area-3:
- shard-apl: NOTRUN -> [SKIP][55] ([fdo#109271] / [i915#658]) +3 similar issues
[55]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl2/igt@[email protected]
* igt@kms_psr2_sf@primary-plane-update-sf-dmg-area-2:
- shard-kbl: NOTRUN -> [SKIP][56] ([fdo#109271] / [i915#658])
[56]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-kbl2/igt@[email protected]
* igt@kms_psr2_su@frontbuffer:
- shard-skl: NOTRUN -> [SKIP][57] ([fdo#109271] / [i915#658]) +2 similar issues
[57]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl4/igt@[email protected]
* igt@kms_psr@psr2_basic:
- shard-iclb: [PASS][58] -> [SKIP][59] ([fdo#109441]) +3 similar issues
[58]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-iclb2/igt@kms_psr@psr2_basic.html
[59]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-iclb4/igt@kms_psr@psr2_basic.html
* igt@kms_writeback@writeback-check-output:
- shard-apl: NOTRUN -> [SKIP][60] ([fdo#109271] / [i915#2437]) +1 similar issue
[60]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl1/igt@[email protected]
- shard-kbl: NOTRUN -> [SKIP][61] ([fdo#109271] / [i915#2437])
[61]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-kbl3/igt@[email protected]
* igt@perf@polling-parameterized:
- shard-skl: [PASS][62] -> [FAIL][63] ([i915#1542])
[62]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-skl6/igt@[email protected]
[63]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl6/igt@[email protected]
* igt@sysfs_clients@create:
- shard-apl: NOTRUN -> [SKIP][64] ([fdo#109271] / [i915#2994]) +2 similar issues
[64]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl2/igt@[email protected]
- shard-skl: NOTRUN -> [SKIP][65] ([fdo#109271] / [i915#2994]) +2 similar issues
[65]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl9/igt@[email protected]
#### Possible fixes ####
* igt@gem_exec_fair@basic-none-share@rcs0:
- shard-glk: [FAIL][66] ([i915#2842]) -> [PASS][67]
[66]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-glk6/igt@gem_exec_fair@[email protected]
[67]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-glk5/igt@gem_exec_fair@[email protected]
* igt@gem_exec_fair@basic-none@vcs0:
- shard-kbl: [FAIL][68] ([i915#2842]) -> [PASS][69] +1 similar issue
[68]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-kbl4/igt@gem_exec_fair@[email protected]
[69]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-kbl4/igt@gem_exec_fair@[email protected]
* igt@gem_exec_fair@basic-pace@vcs1:
- shard-tglb: [FAIL][70] ([i915#2842]) -> [PASS][71] +1 similar issue
[70]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-tglb5/igt@gem_exec_fair@[email protected]
[71]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-tglb3/igt@gem_exec_fair@[email protected]
* igt@gem_huc_copy@huc-copy:
- shard-tglb: [SKIP][72] ([i915#2190]) -> [PASS][73]
[72]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-tglb6/igt@[email protected]
[73]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-tglb3/igt@[email protected]
* igt@kms_big_fb@y-tiled-32bpp-rotate-0:
- shard-glk: [DMESG-WARN][74] ([i915#118]) -> [PASS][75]
[74]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-glk9/igt@[email protected]
[75]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-glk5/igt@[email protected]
* igt@kms_cursor_crc@pipe-b-cursor-suspend:
- shard-kbl: [DMESG-WARN][76] ([i915#180]) -> [PASS][77]
[76]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-kbl7/igt@[email protected]
[77]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-kbl2/igt@[email protected]
* igt@kms_cursor_legacy@flip-vs-cursor-busy-crc-atomic:
- shard-skl: [FAIL][78] ([i915#2346]) -> [PASS][79]
[78]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-skl10/igt@[email protected]
[79]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl9/igt@[email protected]
* igt@kms_flip@2x-plain-flip-fb-recreate-interruptible@bc-hdmi-a1-hdmi-a2:
- shard-glk: [FAIL][80] ([i915#2122]) -> [PASS][81]
[80]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-glk5/igt@kms_flip@[email protected]
[81]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-glk1/igt@kms_flip@[email protected]
* igt@kms_flip@flip-vs-expired-vblank-interruptible@a-hdmi-a2:
- shard-glk: [FAIL][82] ([i915#79]) -> [PASS][83]
[82]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-glk1/igt@kms_flip@[email protected]
[83]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-glk2/igt@kms_flip@[email protected]
* igt@kms_flip@flip-vs-expired-vblank@a-edp1:
- shard-skl: [FAIL][84] ([i915#79]) -> [PASS][85]
[84]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-skl10/igt@kms_flip@[email protected]
[85]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl8/igt@kms_flip@[email protected]
* igt@kms_flip@flip-vs-suspend@c-dp1:
- shard-kbl: [INCOMPLETE][86] ([i915#636]) -> [PASS][87]
[86]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-kbl2/igt@kms_flip@[email protected]
[87]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-kbl3/igt@kms_flip@[email protected]
* igt@kms_hdr@bpc-switch-suspend:
- shard-apl: [DMESG-WARN][88] ([i915#180]) -> [PASS][89] +6 similar issues
[88]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-apl1/igt@[email protected]
[89]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl3/igt@[email protected]
* igt@kms_plane_alpha_blend@pipe-b-coverage-7efc:
- shard-skl: [FAIL][90] ([fdo#108145] / [i915#265]) -> [PASS][91]
[90]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-skl2/igt@[email protected]
[91]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl7/igt@[email protected]
* igt@kms_psr@psr2_sprite_plane_move:
- shard-iclb: [SKIP][92] ([fdo#109441]) -> [PASS][93] +1 similar issue
[92]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-iclb5/igt@kms_psr@psr2_sprite_plane_move.html
[93]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-iclb2/igt@kms_psr@psr2_sprite_plane_move.html
* igt@kms_setmode@basic:
- shard-apl: [FAIL][94] ([i915#31]) -> [PASS][95]
[94]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-apl2/igt@[email protected]
[95]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl8/igt@[email protected]
* igt@kms_vblank@pipe-c-ts-continuation-suspend:
- shard-kbl: [INCOMPLETE][96] ([i915#2828] / [i915#794]) -> [PASS][97]
[96]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-kbl4/igt@[email protected]
[97]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-kbl6/igt@[email protected]
#### Warnings ####
* igt@gem_exec_fair@basic-none-rrul@rcs0:
- shard-iclb: [FAIL][98] ([i915#2852]) -> [FAIL][99] ([i915#2842])
[98]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-iclb6/igt@gem_exec_fair@[email protected]
[99]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-iclb7/igt@gem_exec_fair@[email protected]
* igt@i915_pm_dc@dc9-dpms:
- shard-iclb: [SKIP][100] ([i915#4281]) -> [FAIL][101] ([i915#4275])
[100]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-iclb3/igt@[email protected]
[101]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-iclb7/igt@[email protected]
* igt@i915_pm_rc6_residency@rc6-idle:
- shard-iclb: [WARN][102] ([i915#1804] / [i915#2684]) -> [WARN][103] ([i915#2684])
[102]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-iclb7/igt@[email protected]
[103]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-iclb8/igt@[email protected]
* igt@kms_psr2_sf@overlay-primary-update-sf-dmg-area-3:
- shard-iclb: [SKIP][104] ([i915#658]) -> [SKIP][105] ([i915#2920]) +2 similar issues
[104]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-iclb5/igt@[email protected]
[105]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-iclb2/igt@[email protected]
* igt@kms_psr2_sf@primary-plane-update-sf-dmg-area-2:
- shard-iclb: [SKIP][106] ([i915#2920]) -> [SKIP][107] ([i915#658]) +1 similar issue
[106]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-iclb2/igt@[email protected]
[107]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-iclb4/igt@[email protected]
* igt@runner@aborted:
- shard-kbl: ([FAIL][108], [FAIL][109]) ([i915#1814] / [i915#3002] / [i915#3363] / [i915#4312]) -> ([FAIL][110], [FAIL][111]) ([i915#3002] / [i915#3363] / [i915#4312])
[108]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-kbl7/igt@[email protected]
[109]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-kbl3/igt@[email protected]
[110]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-kbl1/igt@[email protected]
[111]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-kbl3/igt@[email protected]
- shard-apl: ([FAIL][112], [FAIL][113], [FAIL][114], [FAIL][115], [FAIL][116], [FAIL][117], [FAIL][118]) ([fdo#109271] / [i915#180] / [i915#1814] / [i915#3363] / [i915#4312]) -> ([FAIL][119], [FAIL][120], [FAIL][121], [FAIL][122], [FAIL][123]) ([i915#180] / [i915#1814] / [i915#3002] / [i915#3363] / [i915#4312])
[112]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-apl3/igt@[email protected]
[113]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-apl8/igt@[email protected]
[114]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-apl1/igt@[email protected]
[115]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-apl2/igt@[email protected]
[116]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-apl3/igt@[email protected]
[117]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-apl1/igt@[email protected]
[118]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-apl2/igt@[email protected]
[119]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl1/igt@[email protected]
[120]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl3/igt@[email protected]
[121]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl4/igt@[email protected]
[122]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl6/igt@[email protected]
[123]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-apl7/igt@[email protected]
- shard-skl: ([FAIL][124], [FAIL][125], [FAIL][126], [FAIL][127], [FAIL][128]) ([i915#1436] / [i915#2029] / [i915#2263] / [i915#2369] / [i915#3002] / [i915#3363] / [i915#4312]) -> ([FAIL][129], [FAIL][130], [FAIL][131], [FAIL][132]) ([i915#1436] / [i915#2369] / [i915#3002] / [i915#3363] / [i915#4312])
[124]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-skl2/igt@[email protected]
[125]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-skl9/igt@[email protected]
[126]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-skl8/igt@[email protected]
[127]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-skl10/igt@[email protected]
[128]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10877/shard-skl10/igt@[email protected]
[129]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl8/igt@[email protected]
[130]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl9/igt@[email protected]
[131]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl10/igt@[email protected]
[132]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/shard-skl10/igt@[email protected]
[fdo#108145]: https://bugs.freedesktop.org/show_bug.cgi?id=108145
[fdo#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
[fdo#109441]: https://bugs.freedesktop.org/show_bug.cgi?id=109441
[fdo#111827]: https://bugs.freedesktop.org/show_bug.cgi?id=111827
[i915#118]: https://gitlab.freedesktop.org/drm/intel/issues/118
[i915#1319]: https://gitlab.freedesktop.org/drm/intel/issues/1319
[i915#1436]: https://gitlab.freedesktop.org/drm/intel/issues/1436
[i915#1542]: https://gitlab.freedesktop.org/drm/intel/issues/1542
[i915#180]: https://gitlab.freedesktop.org/drm/intel/issues/180
[i915#1804]: https://gitlab.freedesktop.org/drm/intel/issues/1804
[i915#1814]: https://gitlab.freedesktop.org/drm/intel/issues/1814
[i915#1982]: https://gitlab.freedesktop.org/drm/intel/issues/1982
[i915#2029]: https://gitlab.freedesktop.org/drm/intel/issues/2029
[i915#2105]: https://gitlab.freedesktop.org/drm/intel/issues/2105
[i915#2122]: https://gitlab.freedesktop.org/drm/intel/issues/2122
[i915#2190]: https://gitlab.freedesktop.org/drm/intel/issues/2190
[i915#2263]: https://gitlab.freedesktop.org/drm/intel/issues/2263
[i915#2346]: https://gitlab.freedesktop.org/drm/intel/issues/2346
[i915#2369]: https://gitlab.freedesktop.org/drm/intel/issues/2369
[i915#2411]: https://gitlab.freedesktop.org/drm/intel/issues/2411
[i915#2437]: https://gitlab.freedesktop.org/drm/intel/issues/2437
[i915#265]: https://gitlab.freedesktop.org/drm/intel/issues/265
[i915#2658]: https://gitlab.freedesktop.org/drm/intel/issues/2658
[i915#2672]: https://gitlab.freedesktop.org/drm/intel/issues/2672
[i915#2684]: https://gitlab.freedesktop.org/drm/intel/issues/2684
[i915#2828]: https://gitlab.freedesktop.org/drm/intel/issues/2828
[i915#2842]: https://gitlab.freedesktop.org/drm/intel/issues/2842
[i915#2846]: https://gitlab.freedesktop.org/drm/intel/issues/2846
[i915#2849]: https://gitlab.freedesktop.org/drm/intel/issues/2849
[i915#2852]: https://gitlab.freedesktop.org/drm/intel/issues/2852
[i915#2920]: https://gitlab.freedesktop.org/drm/intel/issues/2920
[i915#2994]: https://gitlab.freedesktop.org/drm/intel/issues/2994
[i915#3002]: https://gitlab.freedesktop.org/drm/intel/issues/3002
[i915#31]: https://gitlab.freedesktop.org/drm/intel/issues/31
[i915#3318]: https://gitlab.freedesktop.org/drm/intel/issues/3318
[i915#3363]: https://gitlab.freedesktop.org/drm/intel/issues/3363
[i915#3444]: https://gitlab.freedesktop.org/drm/intel/issues/3444
[i915#3701]: https://gitlab.freedesktop.org/drm/intel/issues/3701
[i915#3743]: https://gitlab.freedesktop.org/drm/intel/issues/3743
[i915#3777]: https://gitlab.freedesktop.org/drm/intel/issues/3777
[i915#3886]: https://gitlab.freedesktop.org/drm/intel/issues/3886
[i915#4275]: https://gitlab.freedesktop.org/drm/intel/issues/4275
[i915#4281]: https://gitlab.freedesktop.org/drm/intel/issues/4281
[i915#4312]: https://gitlab.freedesktop.org/drm/intel/issues/4312
[i915#456]: https://gitlab.freedesktop.org/drm/intel/issues/456
[i915#533]: https://gitlab.freedesktop.org/drm/intel/issues/533
[i915#636]: https://gitlab.freedesktop.org/drm/intel/issues/636
[i915#658]: https://gitlab.freedesktop.org/drm/intel/issues/658
[i915#79]: https://gitlab.freedesktop.org/drm/intel/issues/79
[i915#794]: https://gitlab.freedesktop.org/drm/intel/issues/794
Build changes
-------------
* Linux: CI_DRM_10877 -> Patchwork_21581
CI-20190529: 20190529
CI_DRM_10877: 688d3ea17a90b4acf51de31ef08cd2b23799952e @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_6280: 246bfd31dba6bf184b26b170d91d72c90a54be6b @ https://gitlab.freedesktop.org/drm/igt-gpu-tools.git
Patchwork_21581: 56dd8cd7dadd44a32e1339993802920b322f1dad @ git://anongit.freedesktop.org/gfx-ci/linux
piglit_4509: fdc5a4ca11124ab8413c7988896eec4c97336694 @ git://anongit.freedesktop.org/piglit
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_21581/index.html
Jani Nikula
maintainerQuoted 11 lines · Lyude Paul
While working on supporting the Intel HDR backlight interface, I noticed that there's a couple of laptops that will very rarely manage to boot up without detecting Intel HDR backlight support - even though it's supported on the system. One example of such a laptop is the Lenovo P17 1st generation.
Following some investigation Ville Syrjälä did through the docs they have available to them, they discovered that there's actually supposed to be a 30ms wait after writing the source OUI before we begin setting up the rest of the backlight interface.
Quoted 9 lines
This seems to be correct, as adding this 30ms delay seems to have completely fixed the probing issues I was previously seeing. So - let's start performing a 30ms wait after writing the OUI, which we do in a manner similar to how we keep track of PPS delays (e.g. record the timestamp of the OUI write, and then wait for however many ms are left since that timestamp right before we interact with the backlight) in order to avoid waiting any longer then we need to. As well, this also avoids us performing this delay on systems where we don't end up using the HDR backlight interface.
Ugh. Thanks for digging into this.
The only thing that I dislike with the implementation is splitting the implementation to two places. See how well we've managed to shove all of the PPS waits inside intel_pps.c. Almost all of intel_dp->pps is managed within intel_pps.c.
I think I'd actually add a intel_dp_wait_source_oui() or something in intel_dp.c, so all of the details about source OUI and intel_dp->last_oui_write access would be localized.
BR,
Jani.
Quoted 82 lines
Signed-off-by Lyude Paul <[email protected]>Fixes 4a8d79901d5b ("drm/i915/dp: Enable Intel's HDR backlight interface (only SDR for now)")Cc Ville Syrjälä <[email protected]>Cc <[email protected]> # v5.12+--- drivers/gpu/drm/i915/display/intel_display_types.h | 3 +++ drivers/gpu/drm/i915/display/intel_dp.c | 3 +++ drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 11 +++++++++++ 3 files changed, 17 insertions(+)drivers/gpu/drm/i915/display/intel_display_types.h +3
-0@@ -1653,6 +1653,9 @@ struct intel_dp {struct intel_dp_pcon_frl frl;struct intel_psr psr; + +/* When we last wrote the OUI for eDP */ +unsigned long last_oui_write; };enum lspcon_vendor {drivers/gpu/drm/i915/display/intel_dp.c +3
-0@@ -29,6 +29,7 @@#include <linux/i2c.h> #include <linux/notifier.h> #include <linux/slab.h> +#include <linux/timekeeping.h> #include <linux/types.h> #include <asm/byteorder.h> @@ -2010,6 +2011,8 @@ intel_edp_init_source_oui(struct intel_dp *intel_dp, bool careful)if (drm_dp_dpcd_write (&intel_dp->aux,DP_SOURCE_OUI , oui,sizeof (oui)) <0 )drm_err (&i915->drm,"Failed to write source OUI\n" ); + + intel_dp->last_oui_write = jiffies; }/* If the device supports it, try to set the power state appropriately */ drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c +11
-0@@ -96,6 +96,13 @@#define INTEL_EDP_BRIGHTNESS_OPTIMIZATION_1 0x359/* Intel EDP backlight callbacks */ +static void +wait_for_oui (struct drm_i915_private *i915,struct intel_dp *intel_dp) +{ +drm_dbg_kms (&i915->drm,"Performing OUI wait\n" ); +wait_remaining_ms_from_jiffies (intel_dp->last_oui_write,30 ); +} +static bool intel_dp_aux_supports_hdr_backlight (struct intel_connector *connector) {@@ -106,6 +113,8 @@ intel_dp_aux_supports_hdr_backlight(struct intel_connector *connector)int ret;u8 tcon_cap[4 ]; +wait_for_oui (i915, intel_dp); + ret =drm_dp_dpcd_read (aux,INTEL_EDP_HDR_TCON_CAP0 , tcon_cap,sizeof (tcon_cap));if (ret !=sizeof (tcon_cap))return false;@@ -204,6 +213,8 @@ intel_dp_aux_hdr_enable_backlight(const struct intel_crtc_state *crtc_state,int ret;u8 old_ctrl, ctrl; +wait_for_oui (i915, intel_dp); + ret =drm_dp_dpcd_readb (&intel_dp->aux,INTEL_EDP_HDR_GETSET_CTRL_PARAMS , &old_ctrl);if (ret !=1 ) {drm_err (&i915->drm,"Failed to read current backlight control mode: %d\n" , ret);
Signature · 1 line
Jani Nikula, Intel Open Source Graphics Center
Quoted 24 lines · Jani Nikula
Quoted 11 lines · Lyude Paul
While working on supporting the Intel HDR backlight interface, I noticed that there's a couple of laptops that will very rarely manage to boot up without detecting Intel HDR backlight support - even though it's supported on the system. One example of such a laptop is the Lenovo P17 1st generation.
Following some investigation Ville Syrjälä did through the docs they have available to them, they discovered that there's actually supposed to be a 30ms wait after writing the source OUI before we begin setting up the rest of the backlight interface.
Quoted 11 lines
This seems to be correct, as adding this 30ms delay seems to have completely fixed the probing issues I was previously seeing. So - let's start performing a 30ms wait after writing the OUI, which we do in a manner
similar to how we keep track of PPS delays (e.g. record the timestamp of the OUI write, and then wait for however many ms are left since that timestamp right before we interact with the backlight) in order to avoid waiting any longer then we need to. As well, this also avoids us performing
this delay on systems where we don't end up using the HDR backlight interface.
Quoted 1 line
Ugh. Thanks for digging into this.
haha, np! You should thank Ville for finding the hidden docs that told us about this :).
Quoted 5 lines
The only thing that I dislike with the implementation is splitting the implementation to two places. See how well we've managed to shove all of the PPS waits inside
intel_pps.c. Almost all ofintel_dp->ppsis managed withinintel_pps.c.
gotcha, I think I meant to do this after I got things working but forgot before I sent this out, will respin ASAP
Quoted 105 lines
I think I'd actually add a
intel_dp_wait_source_oui()or something inintel_dp.c, so all of the details about source OUI andintel_dp->last_oui_writeaccess would be localized.BR,
Jani.Quoted 94 lines
Signed-off-by Lyude Paul <[email protected]>Fixes 4a8d79901d5b ("drm/i915/dp: Enable Intel's HDR backlight interface(only SDR for now)")
Cc: Ville Syrjälä <[email protected]>
Cc: <[email protected]> # v5.12+
---
drivers/gpu/drm/i915/display/intel_display_types.h | 3 +++ drivers/gpu/drm/i915/display/intel_dp.c | 3 +++drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c| 11 +++++++++++3 files changed, 17 insertions(+)drivers/gpu/drm/i915/display/intel_display_types.h +0
-0@@ -1653,6 +1653,9 @@ struct intel_dp { struct intel_dp_pcon_frl frl;
structintel_psrpsr;
+
+ /* When we last wrote the OUI for eDP */
+ unsigned longlast_oui_write;
};
enumlspcon_vendor{drivers/gpu/drm/i915/display/intel_dp.c +1
-0@@ -29,6 +29,7 @@ #include <linux/i2c.h> #include <linux/notifier.h> #include <linux/slab.h> +#include <linux/timekeeping.h> #include <linux/types.h>
#include <asm/byteorder.h>drivers/gpu/drm/i915/display/intel_dp.c +0
-0@@ -2010,6 +2011,8 @@ intel_edp_init_source_oui(struct intel_dp *intel_dp, bool careful)
if (drm_dp_dpcd_write(&intel_dp->aux, DP_SOURCE_OUI, oui, sizeof(oui))< 0)
drm_err(&i915->drm, "Failed to write source OUI\n"); +
+ intel_dp->last_oui_write = jiffies;
}
/* If the device supports it, try to set the power state appropriately */drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c +0
-0@@ -96,6 +96,13 @@ #define INTEL_EDP_BRIGHTNESS_OPTIMIZATION_1
0x359
/* Intel EDP backlight callbacks */drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c +7
-0+static void +wait_for_oui (struct drm_i915_private *i915,struct intel_dp *intel_dp) +{ + drm_dbg_kms(&i915->drm, "Performing OUI wait\n"); + wait_remaining_ms_from_jiffies(intel_dp->last_oui_write, 30); +} +static bool
intel_dp_aux_supports_hdr_backlight(structintel_connector*connector) {drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c +0
-0@@ -106,6 +113,8 @@ intel_dp_aux_supports_hdr_backlight(struct intel_connector *connector) int ret; u8 tcon_cap[4];
+ wait_for_oui(i915,intel_dp);
+
ret =drm_dp_dpcd_read(aux, INTEL_EDP_HDR_TCON_CAP0, tcon_cap, sizeof(tcon_cap));
if (ret !=sizeof(tcon_cap))
return false;drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c +0
-0@@ -204,6 +213,8 @@ intel_dp_aux_hdr_enable_backlight(const structintel_crtc_state *crtc_state, int ret; u8 old_ctrl, ctrl;
+ wait_for_oui(i915,intel_dp);
+
ret =drm_dp_dpcd_readb(&intel_dp->aux, INTEL_EDP_HDR_GETSET_CTRL_PARAMS, &old_ctrl);
if (ret != 1) {
drm_err(&i915->drm, "Failed to read current backlight control mode: %d\n", ret);
Signature · 3 lines
Cheers, Lyude Paul (she/her) Software Engineer at Red Hat