mirror of
https://github.com/torvalds/linux.git
synced 2026-05-30 10:04:04 +02:00
drm/i915/ltphy: Hook up LT Phy Enable & Disable sequences
Hook up the LT Phy enable and disable sequences using encoder-> enable/disable_clock and reusing the TBT enable disable sequence from cx0 PHY since it remains the same. Signed-off-by: Suraj Kandpal <suraj.kandpal@intel.com> Reviewed-by: Arun R Murthy <arun.r.murthy@intel.com> Link: https://patch.msgid.link/20251101032513.4171255-18-suraj.kandpal@intel.com
This commit is contained in:
parent
fa5fd596bf
commit
109289252f
|
|
@ -18,6 +18,7 @@
|
|||
#include "intel_display_utils.h"
|
||||
#include "intel_dp.h"
|
||||
#include "intel_hdmi.h"
|
||||
#include "intel_lt_phy.h"
|
||||
#include "intel_panel.h"
|
||||
#include "intel_psr.h"
|
||||
#include "intel_snps_hdmi_pll.h"
|
||||
|
|
@ -3150,8 +3151,8 @@ static int intel_mtl_tbt_clock_select(struct intel_display *display,
|
|||
}
|
||||
}
|
||||
|
||||
static void intel_mtl_tbt_pll_enable(struct intel_encoder *encoder,
|
||||
const struct intel_crtc_state *crtc_state)
|
||||
void intel_mtl_tbt_pll_enable(struct intel_encoder *encoder,
|
||||
const struct intel_crtc_state *crtc_state)
|
||||
{
|
||||
struct intel_display *display = to_intel_display(encoder);
|
||||
enum phy phy = intel_encoder_to_phy(encoder);
|
||||
|
|
@ -3335,7 +3336,7 @@ static bool intel_cx0_pll_is_enabled(struct intel_encoder *encoder)
|
|||
intel_cx0_get_pclk_pll_request(lane);
|
||||
}
|
||||
|
||||
static void intel_mtl_tbt_pll_disable(struct intel_encoder *encoder)
|
||||
void intel_mtl_tbt_pll_disable(struct intel_encoder *encoder)
|
||||
{
|
||||
struct intel_display *display = to_intel_display(encoder);
|
||||
enum phy phy = intel_encoder_to_phy(encoder);
|
||||
|
|
|
|||
|
|
@ -63,5 +63,8 @@ int intel_mtl_tbt_calc_port_clock(struct intel_encoder *encoder);
|
|||
void intel_cx0_pll_power_save_wa(struct intel_display *display);
|
||||
void intel_lnl_mac_transmit_lfps(struct intel_encoder *encoder,
|
||||
const struct intel_crtc_state *crtc_state);
|
||||
void intel_mtl_tbt_pll_enable(struct intel_encoder *encoder,
|
||||
const struct intel_crtc_state *crtc_state);
|
||||
void intel_mtl_tbt_pll_disable(struct intel_encoder *encoder);
|
||||
|
||||
#endif /* __INTEL_CX0_PHY_H__ */
|
||||
|
|
|
|||
|
|
@ -72,6 +72,7 @@
|
|||
#include "intel_hotplug.h"
|
||||
#include "intel_hti.h"
|
||||
#include "intel_lspcon.h"
|
||||
#include "intel_lt_phy.h"
|
||||
#include "intel_mg_phy_regs.h"
|
||||
#include "intel_modeset_lock.h"
|
||||
#include "intel_panel.h"
|
||||
|
|
@ -5231,7 +5232,11 @@ void intel_ddi_init(struct intel_display *display,
|
|||
encoder->cloneable = 0;
|
||||
encoder->pipe_mask = ~0;
|
||||
|
||||
if (DISPLAY_VER(display) >= 14) {
|
||||
if (HAS_LT_PHY(display)) {
|
||||
encoder->enable_clock = intel_xe3plpd_pll_enable;
|
||||
encoder->disable_clock = intel_xe3plpd_pll_disable;
|
||||
encoder->port_pll_type = intel_mtl_port_pll_type;
|
||||
} else if (DISPLAY_VER(display) >= 14) {
|
||||
encoder->enable_clock = intel_mtl_pll_enable;
|
||||
encoder->disable_clock = intel_mtl_pll_disable;
|
||||
encoder->port_pll_type = intel_mtl_port_pll_type;
|
||||
|
|
|
|||
|
|
@ -1705,3 +1705,24 @@ void intel_lt_phy_pll_disable(struct intel_encoder *encoder)
|
|||
|
||||
intel_lt_phy_transaction_end(encoder, wakeref);
|
||||
}
|
||||
|
||||
void intel_xe3plpd_pll_enable(struct intel_encoder *encoder,
|
||||
const struct intel_crtc_state *crtc_state)
|
||||
{
|
||||
struct intel_digital_port *dig_port = enc_to_dig_port(encoder);
|
||||
|
||||
if (intel_tc_port_in_tbt_alt_mode(dig_port))
|
||||
intel_mtl_tbt_pll_enable(encoder, crtc_state);
|
||||
else
|
||||
intel_lt_phy_pll_enable(encoder, crtc_state);
|
||||
}
|
||||
|
||||
void intel_xe3plpd_pll_disable(struct intel_encoder *encoder)
|
||||
{
|
||||
struct intel_digital_port *dig_port = enc_to_dig_port(encoder);
|
||||
|
||||
if (intel_tc_port_in_tbt_alt_mode(dig_port))
|
||||
intel_mtl_tbt_pll_disable(encoder);
|
||||
else
|
||||
intel_lt_phy_pll_disable(encoder);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -20,6 +20,9 @@ intel_lt_phy_pll_calc_state(struct intel_crtc_state *crtc_state,
|
|||
struct intel_encoder *encoder);
|
||||
int intel_lt_phy_calc_port_clock(struct intel_encoder *encoder,
|
||||
const struct intel_crtc_state *crtc_state);
|
||||
void intel_xe3plpd_pll_enable(struct intel_encoder *encoder,
|
||||
const struct intel_crtc_state *crtc_state);
|
||||
void intel_xe3plpd_pll_disable(struct intel_encoder *encoder);
|
||||
|
||||
#define HAS_LT_PHY(display) (DISPLAY_VER(display) >= 35)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user