mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-27 11:19:37 +00:00
drm/amd/display: Detect dynamic backlight support in eDP sink
[Why] Check if the eDP sink supports the dynamic backlight control [How] Query the dynamic backlight capability in DPCD (eDP case only) Signed-off-by: Roy Chan <roy.chan@amd.com> Acked-by: Bindu Ramamurthy <bindu.r@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
786b406174
commit
65e870dfa6
2 changed files with 8 additions and 0 deletions
|
@ -3745,6 +3745,7 @@ void detect_edp_sink_caps(struct dc_link *link)
|
|||
uint32_t entry;
|
||||
uint32_t link_rate_in_khz;
|
||||
enum dc_link_rate link_rate = LINK_RATE_UNKNOWN;
|
||||
uint8_t backlight_adj_cap;
|
||||
|
||||
retrieve_link_cap(link);
|
||||
link->dpcd_caps.edp_supported_link_rates_count = 0;
|
||||
|
@ -3775,6 +3776,12 @@ void detect_edp_sink_caps(struct dc_link *link)
|
|||
}
|
||||
link->verified_link_cap = link->reported_link_cap;
|
||||
|
||||
core_link_read_dpcd(link, DP_EDP_BACKLIGHT_ADJUSTMENT_CAP,
|
||||
&backlight_adj_cap, sizeof(backlight_adj_cap));
|
||||
|
||||
link->dpcd_caps.dynamic_backlight_capable_edp =
|
||||
(backlight_adj_cap & DP_EDP_DYNAMIC_BACKLIGHT_CAP) ? true:false;
|
||||
|
||||
dc_link_set_default_brightness_aux(link);
|
||||
}
|
||||
|
||||
|
|
|
@ -1091,6 +1091,7 @@ struct dpcd_caps {
|
|||
bool panel_mode_edp;
|
||||
bool dpcd_display_control_capable;
|
||||
bool ext_receiver_cap_field_present;
|
||||
bool dynamic_backlight_capable_edp;
|
||||
union dpcd_fec_capability fec_cap;
|
||||
struct dpcd_dsc_capabilities dsc_caps;
|
||||
struct dc_lttpr_caps lttpr_caps;
|
||||
|
|
Loading…
Reference in a new issue