mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-23 17:30:02 +00:00
drm/i915: Nuke intel_get_shared_dpll_id()
Each PLL knows its own ID so intel_get_shared_dpll_id() is pointless. Get rid of it. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20220921122343.13061-3-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com>
This commit is contained in:
parent
8a549e8d19
commit
e731a2d2fa
3 changed files with 2 additions and 27 deletions
|
@ -3536,7 +3536,7 @@ static void icl_ddi_tc_get_clock(struct intel_encoder *encoder,
|
|||
if (drm_WARN_ON(&i915->drm, !pll))
|
||||
return;
|
||||
|
||||
if (intel_get_shared_dpll_id(i915, pll) == DPLL_ID_ICL_TBTPLL)
|
||||
if (pll->info->id == DPLL_ID_ICL_TBTPLL)
|
||||
port_dpll_id = ICL_PORT_DPLL_DEFAULT;
|
||||
else
|
||||
port_dpll_id = ICL_PORT_DPLL_MG_PHY;
|
||||
|
@ -3549,7 +3549,7 @@ static void icl_ddi_tc_get_clock(struct intel_encoder *encoder,
|
|||
|
||||
icl_set_active_port_dpll(crtc_state, port_dpll_id);
|
||||
|
||||
if (intel_get_shared_dpll_id(i915, crtc_state->shared_dpll) == DPLL_ID_ICL_TBTPLL)
|
||||
if (crtc_state->shared_dpll->info->id == DPLL_ID_ICL_TBTPLL)
|
||||
crtc_state->port_clock = icl_calc_tbt_pll_link(i915, encoder->port);
|
||||
else
|
||||
crtc_state->port_clock = intel_dpll_get_freq(i915, crtc_state->shared_dpll,
|
||||
|
|
|
@ -152,28 +152,6 @@ intel_get_shared_dpll_by_id(struct drm_i915_private *dev_priv,
|
|||
return &dev_priv->display.dpll.shared_dplls[id];
|
||||
}
|
||||
|
||||
/**
|
||||
* intel_get_shared_dpll_id - get the id of a DPLL
|
||||
* @dev_priv: i915 device instance
|
||||
* @pll: the DPLL
|
||||
*
|
||||
* Returns:
|
||||
* The id of @pll
|
||||
*/
|
||||
enum intel_dpll_id
|
||||
intel_get_shared_dpll_id(struct drm_i915_private *dev_priv,
|
||||
struct intel_shared_dpll *pll)
|
||||
{
|
||||
long pll_idx = pll - dev_priv->display.dpll.shared_dplls;
|
||||
|
||||
if (drm_WARN_ON(&dev_priv->drm,
|
||||
pll_idx < 0 ||
|
||||
pll_idx >= dev_priv->display.dpll.num_shared_dpll))
|
||||
return -1;
|
||||
|
||||
return pll_idx;
|
||||
}
|
||||
|
||||
/* For ILK+ */
|
||||
void assert_shared_dpll(struct drm_i915_private *dev_priv,
|
||||
struct intel_shared_dpll *pll,
|
||||
|
|
|
@ -328,9 +328,6 @@ struct intel_shared_dpll {
|
|||
struct intel_shared_dpll *
|
||||
intel_get_shared_dpll_by_id(struct drm_i915_private *dev_priv,
|
||||
enum intel_dpll_id id);
|
||||
enum intel_dpll_id
|
||||
intel_get_shared_dpll_id(struct drm_i915_private *dev_priv,
|
||||
struct intel_shared_dpll *pll);
|
||||
void assert_shared_dpll(struct drm_i915_private *dev_priv,
|
||||
struct intel_shared_dpll *pll,
|
||||
bool state);
|
||||
|
|
Loading…
Reference in a new issue