drm/amd/display: Skip DPIA-specific DP LL automation flag for non-DPIA links
[Why] The is_automated flag logic only applies to USB4 DPIA links during DP LL compliance test automation. The flag should not be set for non-DPIA cases. [How] Add check for DPIA link endpoint type before setting the flag. Also, rename is_automated to skip_fallback_on_link_loss for clarity. Tested-by: Daniel Wheeler <daniel.wheeler@amd.com> Reviewed-by: Meenakshikumar Somasundaram <meenakshikumar.somasundaram@amd.com> Reviewed-by: Wenjing Liu <wenjing.liu@amd.com> Acked-by: Rodrigo Siqueira <rodrigo.siqueira@amd.com> Signed-off-by: George Shen <george.shen@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
2cbed167d2
commit
d24e50e100
@ -1541,7 +1541,13 @@ struct dc_link {
|
|||||||
bool is_dig_mapping_flexible;
|
bool is_dig_mapping_flexible;
|
||||||
bool hpd_status; /* HPD status of link without physical HPD pin. */
|
bool hpd_status; /* HPD status of link without physical HPD pin. */
|
||||||
bool is_hpd_pending; /* Indicates a new received hpd */
|
bool is_hpd_pending; /* Indicates a new received hpd */
|
||||||
bool is_automated; /* Indicates automated testing */
|
|
||||||
|
/* USB4 DPIA links skip verifying link cap, instead performing the fallback method
|
||||||
|
* for every link training. This is incompatible with DP LL compliance automation,
|
||||||
|
* which expects the same link settings to be used every retry on a link loss.
|
||||||
|
* This flag is used to skip the fallback when link loss occurs during automation.
|
||||||
|
*/
|
||||||
|
bool skip_fallback_on_link_loss;
|
||||||
|
|
||||||
bool edp_sink_present;
|
bool edp_sink_present;
|
||||||
|
|
||||||
|
@ -265,7 +265,7 @@ void dp_handle_link_loss(struct dc_link *link)
|
|||||||
|
|
||||||
for (i = count - 1; i >= 0; i--) {
|
for (i = count - 1; i >= 0; i--) {
|
||||||
// Always use max settings here for DP 1.4a LL Compliance CTS
|
// Always use max settings here for DP 1.4a LL Compliance CTS
|
||||||
if (link->is_automated) {
|
if (link->skip_fallback_on_link_loss) {
|
||||||
pipes[i]->link_config.dp_link_settings.lane_count =
|
pipes[i]->link_config.dp_link_settings.lane_count =
|
||||||
link->verified_link_cap.lane_count;
|
link->verified_link_cap.lane_count;
|
||||||
pipes[i]->link_config.dp_link_settings.link_rate =
|
pipes[i]->link_config.dp_link_settings.link_rate =
|
||||||
@ -404,7 +404,9 @@ bool dp_handle_hpd_rx_irq(struct dc_link *link,
|
|||||||
|
|
||||||
if (hpd_irq_dpcd_data.bytes.device_service_irq.bits.AUTOMATED_TEST) {
|
if (hpd_irq_dpcd_data.bytes.device_service_irq.bits.AUTOMATED_TEST) {
|
||||||
// Workaround for DP 1.4a LL Compliance CTS as USB4 has to share encoders unlike DP and USBC
|
// Workaround for DP 1.4a LL Compliance CTS as USB4 has to share encoders unlike DP and USBC
|
||||||
link->is_automated = true;
|
if (link->ep_type == DISPLAY_ENDPOINT_USB4_DPIA)
|
||||||
|
link->skip_fallback_on_link_loss = true;
|
||||||
|
|
||||||
device_service_clear.bits.AUTOMATED_TEST = 1;
|
device_service_clear.bits.AUTOMATED_TEST = 1;
|
||||||
core_link_write_dpcd(
|
core_link_write_dpcd(
|
||||||
link,
|
link,
|
||||||
|
@ -811,7 +811,7 @@ static enum link_training_result dpia_training_eq_transparent(
|
|||||||
/* Take into consideration corner case for DP 1.4a LL Compliance CTS as USB4
|
/* Take into consideration corner case for DP 1.4a LL Compliance CTS as USB4
|
||||||
* has to share encoders unlike DP and USBC
|
* has to share encoders unlike DP and USBC
|
||||||
*/
|
*/
|
||||||
if (dp_is_interlane_aligned(dpcd_lane_status_updated) || (link->is_automated && retries_eq)) {
|
if (dp_is_interlane_aligned(dpcd_lane_status_updated) || (link->skip_fallback_on_link_loss && retries_eq)) {
|
||||||
result = LINK_TRAINING_SUCCESS;
|
result = LINK_TRAINING_SUCCESS;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@ -1037,7 +1037,7 @@ enum link_training_result dpia_perform_link_training(
|
|||||||
*/
|
*/
|
||||||
if (result == LINK_TRAINING_SUCCESS) {
|
if (result == LINK_TRAINING_SUCCESS) {
|
||||||
fsleep(5000);
|
fsleep(5000);
|
||||||
if (!link->is_automated)
|
if (!link->skip_fallback_on_link_loss)
|
||||||
result = dp_check_link_loss_status(link, <_settings);
|
result = dp_check_link_loss_status(link, <_settings);
|
||||||
} else if (result == LINK_TRAINING_ABORT)
|
} else if (result == LINK_TRAINING_ABORT)
|
||||||
dpia_training_abort(link, <_settings, repeater_id);
|
dpia_training_abort(link, <_settings, repeater_id);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user