| 1 | /* SPDX-License-Identifier: MIT |
| 2 | * |
| 3 | * Copyright © 2025 Intel Corporation |
| 4 | */ |
| 5 | |
| 6 | #ifndef __INTEL_LT_PHY_H__ |
| 7 | #define __INTEL_LT_PHY_H__ |
| 8 | |
| 9 | #include <linux/types.h> |
| 10 | |
| 11 | struct intel_atomic_state; |
| 12 | struct intel_display; |
| 13 | struct intel_encoder; |
| 14 | struct intel_crtc_state; |
| 15 | struct intel_crtc; |
| 16 | struct intel_lt_phy_pll_state; |
| 17 | |
| 18 | void intel_lt_phy_pll_enable(struct intel_encoder *encoder, |
| 19 | const struct intel_crtc_state *crtc_state); |
| 20 | void intel_lt_phy_pll_disable(struct intel_encoder *encoder); |
| 21 | int |
| 22 | intel_lt_phy_pll_calc_state(struct intel_crtc_state *crtc_state, |
| 23 | struct intel_encoder *encoder); |
| 24 | int intel_lt_phy_calc_port_clock(struct intel_encoder *encoder, |
| 25 | const struct intel_crtc_state *crtc_state); |
| 26 | void intel_lt_phy_set_signal_levels(struct intel_encoder *encoder, |
| 27 | const struct intel_crtc_state *crtc_state); |
| 28 | void intel_lt_phy_dump_hw_state(struct intel_display *display, |
| 29 | const struct intel_lt_phy_pll_state *hw_state); |
| 30 | bool |
| 31 | intel_lt_phy_pll_compare_hw_state(const struct intel_lt_phy_pll_state *a, |
| 32 | const struct intel_lt_phy_pll_state *b); |
| 33 | void intel_lt_phy_pll_readout_hw_state(struct intel_encoder *encoder, |
| 34 | const struct intel_crtc_state *crtc_state, |
| 35 | struct intel_lt_phy_pll_state *pll_state); |
| 36 | void intel_lt_phy_pll_state_verify(struct intel_atomic_state *state, |
| 37 | struct intel_crtc *crtc); |
| 38 | int |
| 39 | intel_lt_phy_calculate_hdmi_state(struct intel_lt_phy_pll_state *lt_state, |
| 40 | u32 frequency_khz); |
| 41 | void intel_xe3plpd_pll_enable(struct intel_encoder *encoder, |
| 42 | const struct intel_crtc_state *crtc_state); |
| 43 | void intel_xe3plpd_pll_disable(struct intel_encoder *encoder); |
| 44 | |
| 45 | #define HAS_LT_PHY(display) (DISPLAY_VER(display) >= 35) |
| 46 | |
| 47 | #endif /* __INTEL_LT_PHY_H__ */ |
| 48 | |