Skip to content

Commit 933fe2c

Browse files
Aurabindo Pillaialexdeucher
authored andcommitted
drm/amd/display: DispalyPort: Write OUI only if panel supports it
[why] Organizational Unit Identifier register is optional, and its presence is published via Down Stream Port Count register. Writing this register when not available will result in errors [how] Read this register and continue writing OUI only if the panel has the support advertised. Signed-off-by: Aurabindo Pillai <[email protected]> Reviewed-by: Aric Cyr <[email protected]> Acked-by: Rodrigo Siqueira <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
1 parent e32b248 commit 933fe2c

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

drivers/gpu/drm/amd/display/dc/core/dc_link_dp.c

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4227,6 +4227,21 @@ void dp_set_fec_enable(struct dc_link *link, bool enable)
42274227
void dpcd_set_source_specific_data(struct dc_link *link)
42284228
{
42294229
const uint32_t post_oui_delay = 30; // 30ms
4230+
uint8_t dspc = 0;
4231+
enum dc_status ret = DC_ERROR_UNEXPECTED;
4232+
4233+
ret = core_link_read_dpcd(link, DP_DOWN_STREAM_PORT_COUNT, &dspc,
4234+
sizeof(dspc));
4235+
4236+
if (ret != DC_OK) {
4237+
DC_LOG_ERROR("Error in DP aux read transaction,"
4238+
" not writing source specific data\n");
4239+
return;
4240+
}
4241+
4242+
/* Return if OUI unsupported */
4243+
if (!(dspc & DP_OUI_SUPPORT))
4244+
return;
42304245

42314246
if (!link->dc->vendor_signature.is_valid) {
42324247
struct dpcd_amd_signature amd_signature;

0 commit comments

Comments
 (0)