From: Lee Shawn C <shawn.c.lee@intel.com>
To: dri-devel@lists.freedesktop.org
Cc: cooper.chiou@intel.com, william.tseng@intel.com,
jani.nikula@intel.com, intel-gfx@lists.freedesktop.org
Subject: [Intel-gfx] [v8 5/5] drm/edid: check for HF-SCDB block
Date: Thu, 17 Mar 2022 20:42:02 +0800 [thread overview]
Message-ID: <20220317124202.14189-6-shawn.c.lee@intel.com> (raw)
In-Reply-To: <20220317124202.14189-1-shawn.c.lee@intel.com>
Find HF-SCDB information in CEA extensions block. And retrieve
Max_TMDS_Character_Rate that support by sink device.
v2: HF-SCDB and HF-VSDBS carry the same SCDS data. Reuse
drm_parse_hdmi_forum_vsdb() to parse this packet.
Cc: Jani Nikula <jani.nikula@linux.intel.com>
Cc: Ville Syrjala <ville.syrjala@linux.intel.com>
Cc: Ankit Nautiyal <ankit.k.nautiyal@intel.com>
Cc: intel-gfx <intel-gfx@lists.freedesktop.org>
Signed-off-by: Lee Shawn C <shawn.c.lee@intel.com>
---
drivers/gpu/drm/drm_edid.c | 18 +++++++++++++++++-
1 file changed, 17 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/drm_edid.c b/drivers/gpu/drm/drm_edid.c
index 40c192587f0a..64d13ba0f701 100644
--- a/drivers/gpu/drm/drm_edid.c
+++ b/drivers/gpu/drm/drm_edid.c
@@ -3350,6 +3350,7 @@ add_detailed_modes(struct drm_connector *connector, struct edid *edid,
#define EXT_VIDEO_DATA_BLOCK_420 0x0E
#define EXT_VIDEO_CAP_BLOCK_Y420CMDB 0x0F
#define EXT_VIDEO_HF_EEODB_DATA_BLOCK 0x78
+#define EXT_VIDEO_HF_SCDB_DATA_BLOCK 0x79
#define EDID_BASIC_AUDIO (1 << 6)
#define EDID_CEA_YCRCB444 (1 << 5)
#define EDID_CEA_YCRCB422 (1 << 4)
@@ -4277,6 +4278,20 @@ static bool cea_db_is_vcdb(const u8 *db)
return true;
}
+static bool cea_db_is_hdmi_forum_scdb(const u8 *db)
+{
+ if (cea_db_tag(db) != USE_EXTENDED_TAG)
+ return false;
+
+ if (cea_db_payload_len(db) < 7)
+ return false;
+
+ if (cea_db_extended_tag(db) != EXT_VIDEO_HF_SCDB_DATA_BLOCK)
+ return false;
+
+ return true;
+}
+
static bool cea_db_is_y420cmdb(const u8 *db)
{
if (cea_db_tag(db) != USE_EXTENDED_TAG)
@@ -5274,7 +5289,8 @@ static void drm_parse_cea_ext(struct drm_connector *connector,
if (cea_db_is_hdmi_vsdb(db))
drm_parse_hdmi_vsdb_video(connector, db);
- if (cea_db_is_hdmi_forum_vsdb(db))
+ if (cea_db_is_hdmi_forum_vsdb(db) ||
+ cea_db_is_hdmi_forum_scdb(db))
drm_parse_hdmi_forum_vsdb(connector, db);
if (cea_db_is_microsoft_vsdb(db))
drm_parse_microsoft_vsdb(connector, db);
--
2.17.1
next prev parent reply other threads:[~2022-03-17 12:28 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-17 12:41 [Intel-gfx] [v8 0/5] enhanced edid driver compatibility Lee Shawn C
2022-03-17 12:41 ` [Intel-gfx] [v8 1/5] drm/edid: seek for available CEA block from specific EDID block index Lee Shawn C
2022-03-17 12:41 ` [Intel-gfx] [v8 2/5] drm/edid: parse multiple CEA extension block Lee Shawn C
2022-03-17 12:42 ` [Intel-gfx] [v8 3/5] drm/edid: read HF-EEODB ext block Lee Shawn C
2022-03-23 10:11 ` Jani Nikula
2022-03-23 12:02 ` Jani Nikula
2022-03-23 12:04 ` Simon Ser
2022-03-23 12:14 ` Jani Nikula
2022-03-23 14:26 ` Ville Syrjälä
2022-03-17 12:42 ` [Intel-gfx] [v8 4/5] drm/edid: parse HF-EEODB CEA extension block Lee Shawn C
2022-03-17 12:42 ` Lee Shawn C [this message]
2022-03-17 12:53 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for enhanced edid driver compatibility (rev4) Patchwork
2022-03-17 12:55 ` [Intel-gfx] ✗ Fi.CI.SPARSE: " Patchwork
2022-03-17 13:28 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork
2022-03-17 15:05 ` [Intel-gfx] ✗ Fi.CI.IGT: failure " Patchwork
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=20220317124202.14189-6-shawn.c.lee@intel.com \
--to=shawn.c.lee@intel.com \
--cc=cooper.chiou@intel.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=intel-gfx@lists.freedesktop.org \
--cc=jani.nikula@intel.com \
--cc=william.tseng@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