On Fri, May 08, 2026 at 03:26:43PM +0300, Hogander, Jouni wrote: > On Thu, 2026-05-07 at 09:59 +0300, Imre Deak wrote: > > Fix the error path during DDI encoder/connector initialization by > > calling the missing TC port cleanup function. > > > > This fixes the leaked TC port state. > > Do we need "Fixes:" line here? Otherwise patch looks ok:
Wondered about it too. Fixes: involves the automatic stable backporting of the patch and the criteria for a stable backport is whether the patch fixes an actual usecase for someone. The likelihood for that is close to 0, it's an error path and even if that ran for someone (due to -ENOMEM) the leaks wouldn't be the real issue. > Reviewed-by: Jouni Högander <[email protected]> > > > > > Signed-off-by: Imre Deak <[email protected]> > > --- > > drivers/gpu/drm/i915/display/intel_ddi.c | 13 ++++++++----- > > 1 file changed, 8 insertions(+), 5 deletions(-) > > > > diff --git a/drivers/gpu/drm/i915/display/intel_ddi.c > > b/drivers/gpu/drm/i915/display/intel_ddi.c > > index 2681940a5cfe3..e37cc32ee83ed 100644 > > --- a/drivers/gpu/drm/i915/display/intel_ddi.c > > +++ b/drivers/gpu/drm/i915/display/intel_ddi.c > > @@ -5411,7 +5411,7 @@ void intel_ddi_init(struct intel_display > > *display, > > if (need_aux_ch(encoder, init_dp)) { > > dig_port->aux_ch = intel_dp_aux_ch(encoder); > > if (dig_port->aux_ch == AUX_CH_NONE) > > - goto err; > > + goto err_aux_ch_init; > > } > > > > /* > > @@ -5447,7 +5447,7 @@ void intel_ddi_init(struct intel_display > > *display, > > dig_port->unlock = intel_tc_port_unlock; > > > > if (intel_tc_port_init(dig_port, is_legacy) < 0) > > - goto err; > > + goto err_aux_ch_init; > > } > > > > drm_WARN_ON(display->drm, port > PORT_I); > > @@ -5478,7 +5478,7 @@ void intel_ddi_init(struct intel_display > > *display, > > > > if (init_dp) { > > if (intel_ddi_init_dp_connector(dig_port)) > > - goto err; > > + goto err_dp_connector_init; > > > > dig_port->hpd_pulse = intel_dp_hpd_pulse; > > > > @@ -5492,12 +5492,15 @@ void intel_ddi_init(struct intel_display > > *display, > > */ > > if (encoder->type != INTEL_OUTPUT_EDP && init_hdmi) { > > if (intel_ddi_init_hdmi_connector(dig_port)) > > - goto err; > > + goto err_dp_connector_init; > > } > > > > return; > > > > -err: > > +err_dp_connector_init: > > + if (intel_encoder_is_tc(encoder)) > > + intel_tc_port_cleanup(dig_port); > > +err_aux_ch_init: > > drm_encoder_cleanup(&encoder->base); > > kfree(dig_port); > > } >
