Skip to content

linux-ptl: enable PSR2 selective update on OLED panels#75

Open
TsaiGaggery wants to merge 4 commits intoomacom-io:masterfrom
TsaiGaggery:update-linux-ptl-psr2-vrr
Open

linux-ptl: enable PSR2 selective update on OLED panels#75
TsaiGaggery wants to merge 4 commits intoomacom-io:masterfrom
TsaiGaggery:update-linux-ptl-psr2-vrr

Conversation

@TsaiGaggery
Copy link
Copy Markdown
Contributor

@TsaiGaggery TsaiGaggery commented Apr 7, 2026

Summary

  • Add three display driver patches to enable PSR2 + VRR on Panther Lake eDP OLED panels
  • Fixes PSR2 being silently rejected due to SU granularity read from wrong DPCD registers
  • Removes blanket VRR rejection that prevented PSR2 + VRR coexistence

Patches

0019-drm-i915-psr-accept-early-transport-for-psr2.patch
Accept Early Transport (DPCD version 0x04) for PSR2 sink support.

0020-drm-i915-psr-fix-su-granularity-source-for-psr2.patch
Fix SU granularity register source when Panel Replay is disabled. Without this, PSR2 reads Panel Replay X granularity (0xFFFF) causing 2880 % 65535 != 0 failure.

0022-psr-allow-vrr.patch
Remove blanket VRR rejection in _psr_compute_config(). The existing Wa_16011303918 in intel_psr2_config_valid() already handles the Alderlake-P stepping-specific VRR incompatibility. On PTL, PSR2 + VRR works correctly.

Root cause

All three patches fix kernel code issues, not panel problems:

  1. ET acceptance: kernel didn't recognize DPCD 0x04 (Early Transport) as valid PSR2
  2. Granularity: kernel read Panel Replay DPCD (0xB2=0xFFFF) instead of PSR2 DPCD (0x72=4) when PR is disabled but supported
  3. VRR rejection: _psr_compute_config() had if (crtc_state->vrr.enable) return false blocking ALL PSR with VRR on ALL platforms, even though only ADL-P A0/B0 has a known issue

In upstream drm-intel-next, issues 1-2 are solved by architectural refactoring. Issue 3 is handled differently — upstream blocks PSR+VRR but enables Panel Replay+VRR instead.

Power measurements

Dell XPS 14 OLED (Panther Lake B0, LG Display 2880x1800, eDP 1.5).
90s settle + 60s measure, no debugfs reads, screensaver disabled.

Mode Package (mW) Psys (mW)
PSR2 (Early Transport) 800 1384
PSR1 816 1442
PSR disabled 981 1597

PSR2 saves ~213 mW Psys (13%) vs PSR disabled.

Test results

PSR2 + VRR both active from boot:

PSR mode: PSR2 enabled (Early Transport)
Source PSR/PanelReplay status: DEEP_SLEEP
PSR2 selective fetch: enabled
vrr: true (20-120Hz)

Configuration

/etc/modprobe.d/xe-psr2.conf:
    options xe enable_psr=2 enable_panel_replay=0

~/.config/hypr/monitors.conf:
    monitor=,preferred,auto,auto,vrr,1

Notes

  • Not cherry-picked from upstream. In drm-intel-next, PTL uses Panel Replay SU (not PSR2) with VRR.
  • Panel Replay has cursor lag (~10Hz) on Dell XPS + LGD OLED — upstream quirk QUIRK_DISABLE_EDP_PANEL_REPLAY (45c77d4bf8d4). PSR2 has no cursor lag.
  • Boot message Selective fetch area calculation failed in pipe A is a known PTL issue. Does not affect PSR2 operation.
  • Requires PR Backport DisplayID adaptive sync VRR parsing #72 (DisplayID adaptive sync VRR parsing) for VRR on XPS 16. XPS 14 detects VRR without it but PR Backport DisplayID adaptive sync VRR parsing #72 is included for compatibility.

Add two display driver patches for PSR2 support on Panther Lake
eDP OLED panels:

0019: Accept Early Transport (DPCD 0x04) for PSR2 sink support.
      Panels advertising PSR2 with Early Transport imply Y-coordinate
      support, so the explicit Y-coordinate requirement check is
      relaxed for these panels.

0020: Fix SU granularity register source when Panel Replay is disabled.
      When a panel supports both PSR2 and Panel Replay SU, the
      granularity helper functions unconditionally read from Panel
      Replay DPCD registers. If Panel Replay is disabled via
      enable_panel_replay=0, PSR2 is the active mode but gets Panel
      Replay granularity values (X=0xFFFF), failing the width modulus
      check. The fix adds a panel_replay_global_enabled() guard so
      PSR2 registers are used when Panel Replay is disabled.

Tested on Dell XPS 14 OLED (Panther Lake, LG Display 2880x1800):
- PSR2 with Early Transport and selective fetch enabled
- Display enters DEEP_SLEEP with VRR at 20Hz idle
- RAPL uncore power: 23mW (PSR1) -> 4mW (PSR2), 83% reduction
@TsaiGaggery TsaiGaggery changed the title linux-ptl: enable PSR2 selective update on OLED panels linux-ptl: [EXPERIMENTAL] enable PSR2 selective update on OLED panels Apr 7, 2026
Remove blanket VRR rejection in _psr_compute_config() that prevented
PSR2 from coexisting with VRR on all platforms. The existing
Wa_16011303918 already handles the ADL-P stepping-specific issue.

Tested on Dell XPS 14 OLED (PTL B0): PSR2 + VRR both active from boot.
spencerbull added a commit to spencerbull/omarchy-pkgs that referenced this pull request Apr 9, 2026
GaggeryTsai and others added 2 commits April 10, 2026 00:09
Backport drm-tip handling of DP_PANEL_REPLAY_FULL_LINE_GRANULARITY
(0xFFFF) in psr2_granularity_check(). Without this, Panel Replay SU
is rejected because crtc_hdisplay (2880) % 65535 != 0.

With this patch, Panel Replay SU activates on LGD 2880x1800 OLED,
saving ~83 mW Psys vs basic Panel Replay.
@TsaiGaggery TsaiGaggery changed the title linux-ptl: [EXPERIMENTAL] enable PSR2 selective update on OLED panels linux-ptl: enable PSR2 selective update on OLED panels Apr 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants