Created attachment 298237 [details] edid.i915: edid file for display when running with i915 driver I have a Lenovo Legion 7i 16ITHg6 laptop with a Tiger Lake H CPU and the associated i915 iGPU. The panel is capable of 60 and 165 Hz refresh rates. The i915 is only able to achieve the 60 Hz mode under Linux. The Intel GPU is able to achieve 165 Hz under Windows. I'm able to achieve 165 Hz under both Linux and Windows using the Nvidia discrete GPU. The problem persists even if I blacklist the Nvidia module from loading entirely. In case it matters, I do not think the display is FreeSync capable (like it is on the AMD version of this laptop). Legion 7i 16ITHg6: Tiger Lake H i9 11980HK i915 iGPU Nvidia RTX 3080 mobile dGPU 32GB memory Setting drm.debug=4, here is the output I got when attempting to switch modes: First I switch from "165 Hz" to 60: Aug 5 10:59:12 legion kernel: [ 247.263181] [drm:drm_mode_debug_printmodeline [drm]] Modeline "": 60 282670 2560 2608 2640 2720 1600 1603 1609 1732 0x0 0x9 Aug 5 10:59:12 legion kernel: [ 247.263307] [drm:drm_mode_debug_printmodeline [drm]] Modeline "2560x1600": 60 282670 2560 2608 2640 2720 1600 1603 1609 1732 0x48 0x9 Aug 5 10:59:12 legion kernel: [ 247.263521] [drm:drm_mode_debug_printmodeline [drm]] Modeline "2560x1600": 60 282670 2560 2608 2640 2720 1600 1603 1609 1732 0x40 0x9 Then I attempt to switch from 60 Hz to 165 Hz: Aug 5 10:59:22 legion kernel: [ 257.078950] [drm:drm_mode_debug_printmodeline [drm]] Modeline "": 165 777340 2560 2608 2640 2720 1600 1603 1609 1732 0x0 0xa Aug 5 10:59:22 legion kernel: [ 257.079075] [drm:drm_mode_debug_printmodeline [drm]] Modeline "2560x1600": 60 282670 2560 2608 2640 2720 1600 1603 1609 1732 0x48 0x9 Aug 5 10:59:22 legion kernel: [ 257.079266] [drm:drm_mode_debug_printmodeline [drm]] Modeline "2560x1600": 60 282670 2560 2608 2640 2720 1600 1603 1609 1732 0x40 0x9 The screen never flickers, it remains on 60 Hz no matter what I do. I've attempted to grab the mode when running in Nvidia mode and applying it while running in Intel mode. I've attempted to add the mode both via the xrandr command as well as to xorg.conf. The behavior remains unchanged. Maybe it's an issue with parsing the edid resulting in not finding any other modes beyond 60 Hz? sudo get-edid >edid.i915 parse-edid < edid.i915 You seem to have too many extension blocks. Will not continue to parse Something strange happened. Please contact the author, Matthew Kern at <pyrophobicman@gmail.com> I did try copying the edid when running with the discrete GPU and applying it when running against the Intel iGPU without success, but it's possible I was doing that incorrectly. This problem so far occurs under Linux kernel versions linux-image-5.11.0-25-generic, linux-image-5.13.8, and linux-image-5.13.9. I suspect all are affected. I suspect all kernel versions are affected, but these are what I've tested.
Managed to get the system using the edid I acquired through nvidia-settings: Aug 12 13:31:20 ukyo kernel: [ 1.289544] [drm] Got external EDID base block and 2 extensions from "edid/edid.bin" for connector "eDP-1" Aug 12 13:31:20 ukyo kernel: [ 1.289623] [drm:drm_edid_to_eld [drm]] ELD monitor Aug 12 13:31:20 ukyo kernel: [ 1.289632] [drm:drm_edid_to_eld [drm]] ELD size 20, SAD count 0 Aug 12 13:31:20 ukyo kernel: [ 1.289725] [drm:drm_dp_get_edid_quirks.part.0 [drm_kms_helper]] DP sink: EDID mfg 09-e5 prod-ID 85-09 quirks: 0x0000 Aug 12 13:31:20 ukyo kernel: [ 1.289733] i915 0000:00:02.0: [drm:intel_panel_edid_fixed_mode [i915]] [CONNECTOR:308:eDP-1] using preferred mode from EDID: Aug 12 13:31:20 ukyo kernel: [ 2.158130] nvidia-modeset: WARNING: GPU:0: Unable to read EDID for display device DP-4 Aug 12 13:31:20 ukyo kernel: [ 2.167190] nvidia-modeset: WARNING: GPU:0: Unable to read EDID for display device DP-4 Unfortunately, it still tries to use the other mode and gives up and stays with the 60 Hz mode: Aug 12 13:42:04 legion kernel: [ 527.567062] [drm:drm_mode_debug_printmodeline [drm]] Modeline "2560x1600": 60 282670 2560 2608 2640 2720 1600 1603 1609 1732 0x48 0x9 Aug 12 13:42:05 legion kernel: [ 528.629025] [drm:drm_mode_debug_printmodeline [drm]] Modeline "2560x1600": 165 777340 2560 2608 2640 2720 1600 1603 1609 1732 0x48 0xa Aug 12 13:42:05 legion kernel: [ 528.629064] [drm:drm_mode_debug_printmodeline [drm]] Modeline "2560x1600": 60 282670 2560 2608 2640 2720 1600 1603 1609 1732 0x48 0x9 Aug 12 13:42:05 legion kernel: [ 528.633861] [drm:drm_mode_debug_printmodeline [drm]] Modeline "2560x1600": 165 777340 2560 2608 2640 2720 1600 1603 1609 1732 0x48 0xa Aug 12 13:42:05 legion kernel: [ 528.633872] [drm:drm_mode_debug_printmodeline [drm]] Modeline "2560x1600": 60 282670 2560 2608 2640 2720 1600 1603 1609 1732 0x48 0x9 The screen never flickers which suggests the mode is never actually tried. I was able to run at full 144 Hz with my previous i7 10875h Comet Lake laptop with the i915 driver with optimus.
Created attachment 298301 [details] edid.nvidia-settings - EDID acquired via nvidia-settings Looking at the EDID, it looks like the 165 Hz mode is defined in the 2nd extension block. Maybe this is part of the problem? Aug 12 13:31:20 ukyo kernel: [ 1.289733] i915 0000:00:02.0: [drm:intel_panel_edid_fixed_mode [i915]] [CONNECTOR:308:eDP-1] using preferred mode from EDID:
Please file drm/i915 bugs at freedesktop.org gitlab. https://gitlab.freedesktop.org/drm/intel/-/wikis/How-to-file-i915-bugs I think there's a dupe of this already.