From: Jani Nikula <jani.nikula@linux.intel.com>
To: "Yaroslav Bolyukin" <iam@lach.pw>,
"Ville Syrjälä" <ville.syrjala@linux.intel.com>,
"Maarten Lankhorst" <maarten.lankhorst@linux.intel.com>,
"Maxime Ripard" <mripard@kernel.org>,
"Thomas Zimmermann" <tzimmermann@suse.de>,
"David Airlie" <airlied@gmail.com>,
"Simona Vetter" <simona@ffwll.ch>
Cc: "Harry Wentland" <harry.wentland@amd.com>,
"Leo Li" <sunpeng.li@amd.com>,
"Rodrigo Siqueira" <siqueira@igalia.com>,
"Alex Deucher" <alexander.deucher@amd.com>,
"Christian König" <christian.koenig@amd.com>,
"Wayne Lin" <Wayne.Lin@amd.com>,
amd-gfx@lists.freedesktop.org, linux-kernel@vger.kernel.org,
dri-devel@lists.freedesktop.org,
"Yaroslav Bolyukin" <iam@lach.pw>
Subject: Re: [PATCH v7 6/7] drm/edid: parse DRM VESA dsc bpp target
Date: Thu, 04 Dec 2025 14:12:12 +0200 [thread overview]
Message-ID: <22d49b0cd8b52f485c51af530f49cd8771b2634c@intel.com> (raw)
In-Reply-To: <20251202110218.9212-7-iam@lach.pw>
On Tue, 02 Dec 2025, Yaroslav Bolyukin <iam@lach.pw> wrote:
> As per DisplayID v2.1a spec "DSC pass-through timing support",
> VESA vendor-specific data block may contain target DSC bits per pixel
> fields, that should be always used for the VII modes that declare they
> only support working with this value (Pass-through Timing Support for
> Target DSC Bits per Pixel).
>
> Signed-off-by: Yaroslav Bolyukin <iam@lach.pw>
>
> fixup parse DRM vesa dsc bpp target
Needs to be removed while applying, no need to resend for this.
Reviewed-by: Jani Nikula <jani.nikula@intel.com>
> ---
> drivers/gpu/drm/drm_displayid_internal.h | 4 ++++
> drivers/gpu/drm/drm_edid.c | 17 +++++++++++++++++
> include/drm/drm_connector.h | 6 ++++++
> 3 files changed, 27 insertions(+)
>
> diff --git a/drivers/gpu/drm/drm_displayid_internal.h b/drivers/gpu/drm/drm_displayid_internal.h
> index 55f972d32847..8f1a2f33ca1a 100644
> --- a/drivers/gpu/drm/drm_displayid_internal.h
> +++ b/drivers/gpu/drm/drm_displayid_internal.h
> @@ -148,6 +148,8 @@ struct displayid_formula_timing_block {
> #define DISPLAYID_VESA_DP_TYPE GENMASK(2, 0)
> #define DISPLAYID_VESA_MSO_OVERLAP GENMASK(3, 0)
> #define DISPLAYID_VESA_MSO_MODE GENMASK(6, 5)
> +#define DISPLAYID_VESA_DSC_BPP_INT GENMASK(5, 0)
> +#define DISPLAYID_VESA_DSC_BPP_FRACT GENMASK(3, 0)
>
> #define DISPLAYID_VESA_DP_TYPE_EDP 0
> #define DISPLAYID_VESA_DP_TYPE_DP 1
> @@ -157,6 +159,8 @@ struct displayid_vesa_vendor_specific_block {
> u8 oui[3];
> u8 data_structure_type;
> u8 mso;
> + u8 dsc_bpp_int;
> + u8 dsc_bpp_fract;
> } __packed;
>
> /*
> diff --git a/drivers/gpu/drm/drm_edid.c b/drivers/gpu/drm/drm_edid.c
> index be8715632b91..8273920f5ba4 100644
> --- a/drivers/gpu/drm/drm_edid.c
> +++ b/drivers/gpu/drm/drm_edid.c
> @@ -45,6 +45,7 @@
> #include <drm/drm_edid.h>
> #include <drm/drm_eld.h>
> #include <drm/drm_encoder.h>
> +#include <drm/drm_fixed.h>
> #include <drm/drm_print.h>
>
> #include "drm_crtc_internal.h"
> @@ -6593,6 +6594,21 @@ static void drm_parse_vesa_specific_block(struct drm_connector *connector,
> } else {
> info->mso_pixel_overlap = 0;
> }
> +
> + if (block->num_bytes < 7) {
> + /* DSC bpp is optional */
> + return;
> + }
> +
> + info->dp_dsc_bpp_x16 = FIELD_GET(DISPLAYID_VESA_DSC_BPP_INT, vesa->dsc_bpp_int) << 4 |
> + FIELD_GET(DISPLAYID_VESA_DSC_BPP_FRACT, vesa->dsc_bpp_fract);
> +
> + if (info->dp_dsc_bpp_x16 > 0) {
> + drm_dbg_kms(connector->dev,
> + "[CONNECTOR:%d:%s] DSC bits per pixel " FXP_Q4_FMT "\n",
> + connector->base.id, connector->name,
> + FXP_Q4_ARGS(info->dp_dsc_bpp_x16));
> + }
> }
>
> static void drm_update_vesa_specific_block(struct drm_connector *connector,
> @@ -6641,6 +6657,7 @@ static void drm_reset_display_info(struct drm_connector *connector)
> info->mso_stream_count = 0;
> info->mso_pixel_overlap = 0;
> info->max_dsc_bpp = 0;
> + info->dp_dsc_bpp_x16 = 0;
>
> kfree(info->vics);
> info->vics = NULL;
> diff --git a/include/drm/drm_connector.h b/include/drm/drm_connector.h
> index 8f34f4b8183d..7decfc288aa3 100644
> --- a/include/drm/drm_connector.h
> +++ b/include/drm/drm_connector.h
> @@ -837,6 +837,12 @@ struct drm_display_info {
> */
> u32 max_dsc_bpp;
>
> + /**
> + * @dp_dsc_bpp: DP Display-Stream-Compression (DSC) timing's target
> + * DSC bits per pixel in 6.4 fixed point format. 0 means undefined.
> + */
> + u16 dp_dsc_bpp_x16;
> +
> /**
> * @vics: Array of vics_len VICs. Internal to EDID parsing.
> */
--
Jani Nikula, Intel
next prev parent reply other threads:[~2025-12-04 12:12 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-12-02 11:02 [PATCH v7 0/7] VESA DisplayID fixed DSC BPP value support Yaroslav Bolyukin
2025-12-02 11:02 ` [PATCH v7 1/7] drm/edid: rename VESA block parsing functions to more generic name Yaroslav Bolyukin
2025-12-02 11:02 ` [PATCH v7 2/7] drm/edid: prepare for VESA vendor-specific data block extension Yaroslav Bolyukin
2025-12-02 11:02 ` [PATCH v7 3/7] drm/edid: MSO should only be used for non-eDP displays Yaroslav Bolyukin
2025-12-04 12:08 ` Jani Nikula
2025-12-02 11:02 ` [PATCH v7 4/7] drm/edid: parse DSC DPP passthru support flag for mode VII timings Yaroslav Bolyukin
2025-12-04 12:11 ` Jani Nikula
2025-12-02 11:02 ` [PATCH v7 5/7] drm/edid: for consistency, use mask everywhere for block rev parsing Yaroslav Bolyukin
2025-12-04 12:11 ` Jani Nikula
2025-12-02 11:02 ` [PATCH v7 6/7] drm/edid: parse DRM VESA dsc bpp target Yaroslav Bolyukin
2025-12-04 12:12 ` Jani Nikula [this message]
2025-12-02 11:02 ` [PATCH v7 7/7] drm/amd: use fixed dsc bits-per-pixel from edid Yaroslav Bolyukin
2025-12-29 2:25 ` Lin, Wayne
2026-01-08 20:45 ` [PATCH v7 0/7] VESA DisplayID fixed DSC BPP value support Yaroslav Bolyukin
2026-01-09 8:15 ` Jani Nikula
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=22d49b0cd8b52f485c51af530f49cd8771b2634c@intel.com \
--to=jani.nikula@linux.intel.com \
--cc=Wayne.Lin@amd.com \
--cc=airlied@gmail.com \
--cc=alexander.deucher@amd.com \
--cc=amd-gfx@lists.freedesktop.org \
--cc=christian.koenig@amd.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=harry.wentland@amd.com \
--cc=iam@lach.pw \
--cc=linux-kernel@vger.kernel.org \
--cc=maarten.lankhorst@linux.intel.com \
--cc=mripard@kernel.org \
--cc=simona@ffwll.ch \
--cc=siqueira@igalia.com \
--cc=sunpeng.li@amd.com \
--cc=tzimmermann@suse.de \
--cc=ville.syrjala@linux.intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®