[PATCH 14/29] drm/i915/dp: Abort AUX on disconnected native DP ports
Imre Deak
imre.deak at intel.com
Wed Dec 20 00:53:53 UTC 2023
Signed-off-by: Imre Deak <imre.deak at intel.com>
---
drivers/gpu/drm/i915/display/intel_dp_aux.c | 16 ++++++++++++----
1 file changed, 12 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/i915/display/intel_dp_aux.c b/drivers/gpu/drm/i915/display/intel_dp_aux.c
index 2e2af71bcd5a8..cb902b92f4b23 100644
--- a/drivers/gpu/drm/i915/display/intel_dp_aux.c
+++ b/drivers/gpu/drm/i915/display/intel_dp_aux.c
@@ -9,6 +9,7 @@
#include "intel_bios.h"
#include "intel_de.h"
#include "intel_display_types.h"
+#include "intel_dp.h"
#include "intel_dp_aux.h"
#include "intel_dp_aux_regs.h"
#include "intel_pps.h"
@@ -238,6 +239,7 @@ intel_dp_aux_xfer(struct intel_dp *intel_dp,
intel_wakeref_t pps_wakeref;
int i, ret, recv_bytes;
int try, clock = 0;
+ bool is_connected;
u32 status;
bool vdd;
@@ -253,10 +255,16 @@ intel_dp_aux_xfer(struct intel_dp *intel_dp,
* timeouts that would otherwise happen.
* TODO: abort the transfer on non-TC ports as well.
*/
- if (!intel_tc_port_connected_locked(&dig_port->base)) {
- ret = -ENXIO;
- goto out_unlock;
- }
+ is_connected = intel_tc_port_connected_locked(&dig_port->base);
+ } else if (!intel_dp_is_edp(intel_dp)) {
+ is_connected = intel_digital_port_connected(&dig_port->base);
+ } else {
+ is_connected = true;
+ }
+
+ if (!is_connected) {
+ ret = -ENXIO;
+ goto out_unlock;
}
aux_domain = intel_aux_power_domain(dig_port);
--
2.39.2
More information about the Intel-gfx-trybot
mailing list