Skip to content

Commit

Permalink
drm/i915: Introduce g4x_dp.c
Browse files Browse the repository at this point in the history
Move the g4x+ DP code into a new file. This will leave mostly
platform agnostic code in intel_dp.c. Well, the misplaced phy
test stuff pretty much ruins that, but let's squint real hard
for now.

v2: Add comment exlaining which platforms are covered (Daniel)
    Leave intel_dp_unused_lane_mask() be since it is pretty generic

Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20210318161015.22070-6-ville.syrjala@linux.intel.com
Ville Syrjälä committed Mar 19, 2021
1 parent 764f672 commit 917c289
Showing 7 changed files with 1,568 additions and 1,520 deletions.
1 change: 1 addition & 0 deletions drivers/gpu/drm/i915/Makefile
Original file line number Diff line number Diff line change
@@ -240,6 +240,7 @@ i915-y += \
display/dvo_ns2501.o \
display/dvo_sil164.o \
display/dvo_tfp410.o \
display/g4x_dp.o \
display/icl_dsi.o \
display/intel_crt.o \
display/intel_ddi.o \
1,433 changes: 1,433 additions & 0 deletions drivers/gpu/drm/i915/display/g4x_dp.c

Large diffs are not rendered by default.

31 changes: 31 additions & 0 deletions drivers/gpu/drm/i915/display/g4x_dp.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
/* SPDX-License-Identifier: MIT */
/*
* Copyright © 2020 Intel Corporation
*/

#ifndef _G4X_DP_H_
#define _G4X_DP_H_

#include <linux/types.h>

#include "i915_reg.h"

enum pipe;
enum port;
struct drm_i915_private;
struct intel_crtc_state;
struct intel_dp;
struct intel_encoder;

const struct dpll *vlv_get_dpll(struct drm_i915_private *i915);
enum pipe vlv_active_pipe(struct intel_dp *intel_dp);
void intel_dp_set_clock(struct intel_encoder *encoder,
struct intel_crtc_state *pipe_config);
bool intel_dp_port_enabled(struct drm_i915_private *dev_priv,
i915_reg_t dp_reg, enum port port,
enum pipe *pipe);
bool intel_dp_init(struct drm_i915_private *dev_priv,
i915_reg_t output_reg,
enum port port);

#endif
1 change: 1 addition & 0 deletions drivers/gpu/drm/i915/display/intel_display.c
Original file line number Diff line number Diff line change
@@ -66,6 +66,7 @@

#include "gt/intel_rps.h"

#include "g4x_dp.h"
#include "i915_drv.h"
#include "intel_acpi.h"
#include "intel_atomic.h"
1,615 changes: 101 additions & 1,514 deletions drivers/gpu/drm/i915/display/intel_dp.c

Large diffs are not rendered by default.

6 changes: 0 additions & 6 deletions drivers/gpu/drm/i915/display/intel_dp.h
Original file line number Diff line number Diff line change
@@ -37,11 +37,6 @@ void intel_dp_adjust_compliance_config(struct intel_dp *intel_dp,
bool intel_dp_limited_color_range(const struct intel_crtc_state *crtc_state,
const struct drm_connector_state *conn_state);
int intel_dp_min_bpp(enum intel_output_format output_format);
bool intel_dp_port_enabled(struct drm_i915_private *dev_priv,
i915_reg_t dp_reg, enum port port,
enum pipe *pipe);
bool intel_dp_init(struct drm_i915_private *dev_priv, i915_reg_t output_reg,
enum port port);
bool intel_dp_init_connector(struct intel_digital_port *dig_port,
struct intel_connector *intel_connector);
void intel_dp_set_link_params(struct intel_dp *intel_dp,
@@ -131,7 +126,6 @@ bool intel_dp_initial_fastset_check(struct intel_encoder *encoder,
struct intel_crtc_state *crtc_state);
void intel_dp_sync_state(struct intel_encoder *encoder,
const struct intel_crtc_state *crtc_state);
const struct dpll *vlv_get_dpll(struct drm_i915_private *i915);

void intel_dp_check_frl_training(struct intel_dp *intel_dp);
void intel_dp_pcon_dsc_configure(struct intel_dp *intel_dp,
1 change: 1 addition & 0 deletions drivers/gpu/drm/i915/display/intel_pps.c
Original file line number Diff line number Diff line change
@@ -3,6 +3,7 @@
* Copyright © 2020 Intel Corporation
*/

#include "g4x_dp.h"
#include "i915_drv.h"
#include "intel_display_types.h"
#include "intel_dp.h"

0 comments on commit 917c289

Please sign in to comment.