intel_dpll.h (1787B)
1/* SPDX-License-Identifier: MIT */ 2/* 3 * Copyright © 2020 Intel Corporation 4 */ 5 6#ifndef _INTEL_DPLL_H_ 7#define _INTEL_DPLL_H_ 8 9#include <linux/types.h> 10 11struct dpll; 12struct drm_i915_private; 13struct intel_atomic_state; 14struct intel_crtc; 15struct intel_crtc_state; 16enum pipe; 17 18void intel_dpll_init_clock_hook(struct drm_i915_private *dev_priv); 19int intel_dpll_crtc_compute_clock(struct intel_atomic_state *state, 20 struct intel_crtc *crtc); 21int intel_dpll_crtc_get_shared_dpll(struct intel_atomic_state *state, 22 struct intel_crtc *crtc); 23int vlv_calc_dpll_params(int refclk, struct dpll *clock); 24int pnv_calc_dpll_params(int refclk, struct dpll *clock); 25int i9xx_calc_dpll_params(int refclk, struct dpll *clock); 26u32 i9xx_dpll_compute_fp(const struct dpll *dpll); 27void vlv_compute_dpll(struct intel_crtc_state *crtc_state); 28void chv_compute_dpll(struct intel_crtc_state *crtc_state); 29 30int vlv_force_pll_on(struct drm_i915_private *dev_priv, enum pipe pipe, 31 const struct dpll *dpll); 32void vlv_force_pll_off(struct drm_i915_private *dev_priv, enum pipe pipe); 33 34void chv_enable_pll(const struct intel_crtc_state *crtc_state); 35void chv_disable_pll(struct drm_i915_private *dev_priv, enum pipe pipe); 36void vlv_enable_pll(const struct intel_crtc_state *crtc_state); 37void vlv_disable_pll(struct drm_i915_private *dev_priv, enum pipe pipe); 38void i9xx_enable_pll(const struct intel_crtc_state *crtc_state); 39void i9xx_disable_pll(const struct intel_crtc_state *crtc_state); 40bool bxt_find_best_dpll(struct intel_crtc_state *crtc_state, 41 struct dpll *best_clock); 42int chv_calc_dpll_params(int refclk, struct dpll *pll_clock); 43 44void assert_pll_enabled(struct drm_i915_private *i915, enum pipe pipe); 45void assert_pll_disabled(struct drm_i915_private *i915, enum pipe pipe); 46 47#endif