Skip to content

Commit cfbc726

Browse files
surajk8kv2019i
authored andcommitted
drm/i915/vbt: Add eDP Data rate overrride field in VBT
Add edp_data_rate_override field VBT which gives us a mask of rates which needs to be skipped in favour of subsequent higher rate. --v2 -Rename vbt field [Jani] -Fix comment to 263+ [Jani] -Use BIT_U32 [Jani] -Fix the bits assignment in vbt [Jani] --v3 -Add a mask which represents all link rates [Ankit] Bspec: 20124 Signed-off-by: Suraj Kandpal <suraj.kandpal@intel.com> Reviewed-by: Ankit Nautiyal <ankit.k.nautiyal@intel.com> Link: https://lore.kernel.org/r/20250821042653.269227-2-suraj.kandpal@intel.com (cherry picked from commit 4d33c77) Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
1 parent 30fdccc commit cfbc726

2 files changed

Lines changed: 21 additions & 1 deletion

File tree

drivers/gpu/drm/i915/display/intel_bios.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2747,8 +2747,10 @@ static int child_device_expected_size(u16 version)
27472747
{
27482748
BUILD_BUG_ON(sizeof(struct child_device_config) < 40);
27492749

2750-
if (version > 256)
2750+
if (version > 263)
27512751
return -ENOENT;
2752+
else if (version >= 263)
2753+
return 44;
27522754
else if (version >= 256)
27532755
return 40;
27542756
else if (version >= 216)

drivers/gpu/drm/i915/display/intel_vbt_defs.h

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -437,6 +437,22 @@ enum vbt_gmbus_ddi {
437437
#define BDB_230_VBT_DP_MAX_LINK_RATE_UHBR13P5 6
438438
#define BDB_230_VBT_DP_MAX_LINK_RATE_UHBR20 7
439439

440+
/* EDP link rate 263+ */
441+
#define BDB_263_VBT_EDP_LINK_RATE_1_62 BIT_U32(0)
442+
#define BDB_263_VBT_EDP_LINK_RATE_2_16 BIT_U32(1)
443+
#define BDB_263_VBT_EDP_LINK_RATE_2_43 BIT_U32(2)
444+
#define BDB_263_VBT_EDP_LINK_RATE_2_7 BIT_U32(3)
445+
#define BDB_263_VBT_EDP_LINK_RATE_3_24 BIT_U32(4)
446+
#define BDB_263_VBT_EDP_LINK_RATE_4_32 BIT_U32(5)
447+
#define BDB_263_VBT_EDP_LINK_RATE_5_4 BIT_U32(6)
448+
#define BDB_263_VBT_EDP_LINK_RATE_6_75 BIT_U32(7)
449+
#define BDB_263_VBT_EDP_LINK_RATE_8_1 BIT_U32(8)
450+
#define BDB_263_VBT_EDP_LINK_RATE_10 BIT_U32(9)
451+
#define BDB_263_VBT_EDP_LINK_RATE_13_5 BIT_U32(10)
452+
#define BDB_263_VBT_EDP_LINK_RATE_20 BIT_U32(11)
453+
#define BDB_263_VBT_EDP_NUM_RATES 12
454+
#define BDB_263_VBT_EDP_RATES_MASK GENMASK(BDB_263_VBT_EDP_NUM_RATES - 1, 0)
455+
440456
/*
441457
* The child device config, aka the display device data structure, provides a
442458
* description of a port and its configuration on the platform.
@@ -547,6 +563,8 @@ struct child_device_config {
547563
u8 dp_max_link_rate:3; /* 216+ */
548564
u8 dp_max_link_rate_reserved:5; /* 216+ */
549565
u8 efp_index; /* 256+ */
566+
u32 edp_data_rate_override:12; /* 263+ */
567+
u32 edp_data_rate_override_reserved:20; /* 263+ */
550568
} __packed;
551569

552570
struct bdb_general_definitions {

0 commit comments

Comments
 (0)