mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-08 14:02:37 -04:00
drm/i915/pps: move vlv_active_pipe() to intel_pps.c
All the users for vlv_active_pipe() are within intel_pps.c now, and there are already uses of g4x_dp_port_enabled() and intel_dp->output_reg in there, so seems fine to reduce interfaces and move vlv_active_pipe() to intel_pps.c too. Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/e12ae0a931f113f3bbbf1b4c66108b572a933efb.1726681620.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
This commit is contained in:
@@ -1245,20 +1245,6 @@ static void intel_dp_encoder_destroy(struct drm_encoder *encoder)
|
||||
kfree(enc_to_dig_port(to_intel_encoder(encoder)));
|
||||
}
|
||||
|
||||
enum pipe vlv_active_pipe(struct intel_dp *intel_dp)
|
||||
{
|
||||
struct intel_display *display = to_intel_display(intel_dp);
|
||||
struct drm_i915_private *dev_priv = to_i915(display->drm);
|
||||
struct intel_encoder *encoder = &dp_to_dig_port(intel_dp)->base;
|
||||
enum pipe pipe;
|
||||
|
||||
if (g4x_dp_port_enabled(dev_priv, intel_dp->output_reg,
|
||||
encoder->port, &pipe))
|
||||
return pipe;
|
||||
|
||||
return INVALID_PIPE;
|
||||
}
|
||||
|
||||
static void intel_dp_encoder_reset(struct drm_encoder *encoder)
|
||||
{
|
||||
struct intel_display *display = to_intel_display(encoder->dev);
|
||||
|
||||
@@ -19,7 +19,6 @@ struct intel_encoder;
|
||||
|
||||
#ifdef I915
|
||||
const struct dpll *vlv_get_dpll(struct drm_i915_private *i915);
|
||||
enum pipe vlv_active_pipe(struct intel_dp *intel_dp);
|
||||
void g4x_dp_set_clock(struct intel_encoder *encoder,
|
||||
struct intel_crtc_state *pipe_config);
|
||||
bool g4x_dp_port_enabled(struct drm_i915_private *dev_priv,
|
||||
@@ -32,10 +31,6 @@ static inline const struct dpll *vlv_get_dpll(struct drm_i915_private *i915)
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
static inline int vlv_active_pipe(struct intel_dp *intel_dp)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
static inline void g4x_dp_set_clock(struct intel_encoder *encoder,
|
||||
struct intel_crtc_state *pipe_config)
|
||||
{
|
||||
|
||||
@@ -1211,6 +1211,20 @@ static void vlv_steal_power_sequencer(struct intel_display *display,
|
||||
}
|
||||
}
|
||||
|
||||
static enum pipe vlv_active_pipe(struct intel_dp *intel_dp)
|
||||
{
|
||||
struct intel_display *display = to_intel_display(intel_dp);
|
||||
struct drm_i915_private *dev_priv = to_i915(display->drm);
|
||||
struct intel_encoder *encoder = &dp_to_dig_port(intel_dp)->base;
|
||||
enum pipe pipe;
|
||||
|
||||
if (g4x_dp_port_enabled(dev_priv, intel_dp->output_reg,
|
||||
encoder->port, &pipe))
|
||||
return pipe;
|
||||
|
||||
return INVALID_PIPE;
|
||||
}
|
||||
|
||||
/* Call on all DP, not just eDP */
|
||||
void vlv_pps_pipe_init(struct intel_dp *intel_dp)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user