mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-16 04:21:09 -04:00
drm/i915/dp: Fix VSC dynamic range signaling for RGB formats
For RGB, set dynamic_range to CTA or VESA based on
crtc_state->limited_color_range so sinks apply correct
quantization. YCbCr remains limited (CTA) range.
(DP v1.4, Table 5-1)
v2:
- Added Reported-by and Tested-by tags
v3:
- Add back YCbCr comment(Suraj)
Cc: stable@vger.kernel.org #v5.8+
Reported-by: DeepChirp <DeepChirp@outlook.com>
Closes: https://gitlab.freedesktop.org/drm/i915/kernel/-/work_items/15874
Tested-by: DeepChirp <DeepChirp@outlook.com>
Fixes: 9799c4c3b7 ("drm/i915/dp: Add compute routine for DP VSC SDP")
Assisted-by: GitHub-Copilot:GPT-5.4
Signed-off-by: Chaitanya Kumar Borah <chaitanya.kumar.borah@intel.com>
Reviewed-by: Suraj Kandpal <suraj.kandpal@intel.com>
Signed-off-by: Suraj Kandpal <suraj.kandpal@intel.com>
Link: https://patch.msgid.link/20260505090920.2479112-1-chaitanya.kumar.borah@intel.com
(cherry picked from commit 38e10ddae6f8d42a2e8437fcd25a1cac51106c64)
Signed-off-by: Tvrtko Ursulin <tursulin@ursulin.net>
This commit is contained in:
committed by
Tvrtko Ursulin
parent
4cfe4c0efb
commit
1ae15b6c79
@@ -3119,8 +3119,13 @@ static void intel_dp_compute_vsc_colorimetry(const struct intel_crtc_state *crtc
|
||||
drm_WARN_ON(display->drm,
|
||||
vsc->bpc == 6 && vsc->pixelformat != DP_PIXELFORMAT_RGB);
|
||||
|
||||
/* all YCbCr are always limited range */
|
||||
vsc->dynamic_range = DP_DYNAMIC_RANGE_CTA;
|
||||
/* All YCbCr formats are always limited range. */
|
||||
if (vsc->pixelformat == DP_PIXELFORMAT_RGB)
|
||||
vsc->dynamic_range = crtc_state->limited_color_range ?
|
||||
DP_DYNAMIC_RANGE_CTA : DP_DYNAMIC_RANGE_VESA;
|
||||
else
|
||||
vsc->dynamic_range = DP_DYNAMIC_RANGE_CTA;
|
||||
|
||||
vsc->content_type = DP_CONTENT_TYPE_NOT_DEFINED;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user