On 4/23/2026 8:00 PM, Nemesa Garg wrote:
These constants are used when decoding dsc max delta
This seems to be missing some part. It is not clear that which constants
are we talking about.
values from the sink dpcd. Also add version_1 as suffix
to MAX_DELTA_BPP.
v2: Move constants under 0x6E register. [Ankit]
Add mask for Native 422 also. [Ankit]
Signed-off-by: Nemesa Garg <[email protected]>
---
include/drm/display/drm_dp.h | 23 ++++++++++++++---------
1 file changed, 14 insertions(+), 9 deletions(-)
diff --git a/include/drm/display/drm_dp.h b/include/drm/display/drm_dp.h
index 520490ac6778..c29b391453cd 100644
--- a/include/drm/display/drm_dp.h
+++ b/include/drm/display/drm_dp.h
@@ -354,17 +354,22 @@
# define DP_DSC_20_PER_DP_DSC_SINK (1 << 1)
# define DP_DSC_24_PER_DP_DSC_SINK (1 << 2)
-#define DP_DSC_MAX_BPP_DELTA 0x06E
+#define DP_DSC_MAX_BPP_DELTA_VERSION_1 0x06E
# define DP_DSC_RGB_YCbCr444_MAX_BPP_DELTA_MASK 0x1f
# define DP_DSC_RGB_YCbCr420_MAX_BPP_DELTA_MASK 0xe0
-
-#define DP_DSC_BITS_PER_PIXEL_INC 0x06F
-# define DP_DSC_BITS_PER_PIXEL_1_16 0x0
-# define DP_DSC_BITS_PER_PIXEL_1_8 0x1
-# define DP_DSC_BITS_PER_PIXEL_1_4 0x2
-# define DP_DSC_BITS_PER_PIXEL_1_2 0x3
-# define DP_DSC_BITS_PER_PIXEL_1_1 0x4
-# define DP_DSC_BITS_PER_PIXEL_MASK 0x7
+# define DP_DSC_BPP_DELTA_444 16
+# define DP_DSC_BPP_DELTA_420 12
+# define DP_DSC_BPP_DELTA_SHIFT_420 5
+
+#define DP_DSC_BITS_PER_PIXEL_INC 0x06F
+# define DP_DSC_BITS_PER_PIXEL_1_16 0x0
+# define DP_DSC_BITS_PER_PIXEL_1_8 0x1
+# define DP_DSC_BITS_PER_PIXEL_1_4 0x2
+# define DP_DSC_BITS_PER_PIXEL_1_2 0x3
+# define DP_DSC_BITS_PER_PIXEL_1_1 0x4
+# define DP_DSC_BITS_PER_PIXEL_MASK 0x7
+# define DP_DSC_NATIVE4222_MAX_BPP_DELTA_MASK 0x78
This should be: _NATIVE_YCbCr422_ to match with existing code, and in
line with the comments on the previous patch.
Regards,
Ankit
+# define DP_DSC_BPP_DELTA_NATIVE_422 16
#define DP_PSR_SUPPORT 0x070 /* XXX 1.2? */
# define DP_PSR_IS_SUPPORTED 1