Commit d487ed7e authored by Jouni Högander's avatar Jouni Högander
Browse files

drm/i915/display: Avoid unnecessarily calling intel_cx0_get_owned_lane_mask



Currently we are always calling intel_cx0_get_owned_lane_mask when
intel_lnl_mac_transmit_lfps is called. Avoid this in cases where it's not
needed.

Signed-off-by: default avatarJouni Högander <jouni.hogander@intel.com>
Reviewed-by: default avatarGustavo Sousa <gustavo.sousa@intel.com>
Link: https://lore.kernel.org/r/20250722125618.1842615-3-jouni.hogander@intel.com
parent 8265ce0e
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -3239,13 +3239,14 @@ void intel_lnl_mac_transmit_lfps(struct intel_encoder *encoder,
				 const struct intel_crtc_state *crtc_state)
{
	struct intel_display *display = to_intel_display(encoder);
	u8 owned_lane_mask = intel_cx0_get_owned_lane_mask(encoder);
	int i;
	u8 owned_lane_mask;

	if (DISPLAY_VER(display) < 20 ||
	    !intel_alpm_is_alpm_aux_less(enc_to_intel_dp(encoder), crtc_state))
		return;

	owned_lane_mask = intel_cx0_get_owned_lane_mask(encoder);
	for (i = 0; i < 4; i++) {
		int tx = i % 2 + 1;
		u8 lane_mask = i < 2 ? INTEL_CX0_LANE0 : INTEL_CX0_LANE1;