Commit f0cd0a34 authored by Eric Bernstein's avatar Eric Bernstein Committed by Alex Deucher

drm/amd/display: DCN1 link encoder

Create DCN1 link encoder files and update AUX and HPD register access.
Signed-off-by: default avatarEric Bernstein <eric.bernstein@amd.com>
Reviewed-by: default avatarTony Cheng <Tony.Cheng@amd.com>
Acked-by: default avatarHarry Wentland <harry.wentland@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent a944744b
...@@ -11,8 +11,6 @@ ...@@ -11,8 +11,6 @@
#include "dc_link_dp.h" #include "dc_link_dp.h"
#include "dc_link_ddc.h" #include "dc_link_ddc.h"
#include "dm_helpers.h" #include "dm_helpers.h"
#include "dce/dce_link_encoder.h"
#include "dce/dce_stream_encoder.h"
#include "dpcd_defs.h" #include "dpcd_defs.h"
enum dc_status core_link_read_dpcd( enum dc_status core_link_read_dpcd(
......
...@@ -26,7 +26,7 @@ DCN10 = dcn10_resource.o dcn10_ipp.o dcn10_hw_sequencer.o \ ...@@ -26,7 +26,7 @@ DCN10 = dcn10_resource.o dcn10_ipp.o dcn10_hw_sequencer.o \
dcn10_dpp.o dcn10_opp.o dcn10_optc.o \ dcn10_dpp.o dcn10_opp.o dcn10_optc.o \
dcn10_hubp.o dcn10_mpc.o \ dcn10_hubp.o dcn10_mpc.o \
dcn10_dpp_dscl.o dcn10_dpp_cm.o dcn10_cm_common.o \ dcn10_dpp_dscl.o dcn10_dpp_cm.o dcn10_cm_common.o \
dcn10_hubbub.o dcn10_stream_encoder.o dcn10_hubbub.o dcn10_stream_encoder.o dcn10_link_encoder.o
AMD_DAL_DCN10 = $(addprefix $(AMDDALPATH)/dc/dcn10/,$(DCN10)) AMD_DAL_DCN10 = $(addprefix $(AMDDALPATH)/dc/dcn10/,$(DCN10))
......
This diff is collapsed.
This diff is collapsed.
...@@ -38,7 +38,7 @@ ...@@ -38,7 +38,7 @@
#include "dcn10/dcn10_hw_sequencer.h" #include "dcn10/dcn10_hw_sequencer.h"
#include "dce110/dce110_hw_sequencer.h" #include "dce110/dce110_hw_sequencer.h"
#include "dcn10/dcn10_opp.h" #include "dcn10/dcn10_opp.h"
#include "dce/dce_link_encoder.h" #include "dcn10/dcn10_link_encoder.h"
#include "dcn10/dcn10_stream_encoder.h" #include "dcn10/dcn10_stream_encoder.h"
#include "dce/dce_clocks.h" #include "dce/dce_clocks.h"
#include "dce/dce_clock_source.h" #include "dce/dce_clock_source.h"
...@@ -214,13 +214,11 @@ static const struct dce_aduio_mask audio_mask = { ...@@ -214,13 +214,11 @@ static const struct dce_aduio_mask audio_mask = {
AUX_REG_LIST(id)\ AUX_REG_LIST(id)\
} }
static const struct dce110_link_enc_aux_registers link_enc_aux_regs[] = { static const struct dcn10_link_enc_aux_registers link_enc_aux_regs[] = {
aux_regs(0), aux_regs(0),
aux_regs(1), aux_regs(1),
aux_regs(2), aux_regs(2),
aux_regs(3), aux_regs(3)
aux_regs(4),
aux_regs(5)
}; };
#define hpd_regs(id)\ #define hpd_regs(id)\
...@@ -228,13 +226,11 @@ static const struct dce110_link_enc_aux_registers link_enc_aux_regs[] = { ...@@ -228,13 +226,11 @@ static const struct dce110_link_enc_aux_registers link_enc_aux_regs[] = {
HPD_REG_LIST(id)\ HPD_REG_LIST(id)\
} }
static const struct dce110_link_enc_hpd_registers link_enc_hpd_regs[] = { static const struct dcn10_link_enc_hpd_registers link_enc_hpd_regs[] = {
hpd_regs(0), hpd_regs(0),
hpd_regs(1), hpd_regs(1),
hpd_regs(2), hpd_regs(2),
hpd_regs(3), hpd_regs(3)
hpd_regs(4),
hpd_regs(5)
}; };
#define link_regs(id)\ #define link_regs(id)\
...@@ -243,14 +239,19 @@ static const struct dce110_link_enc_hpd_registers link_enc_hpd_regs[] = { ...@@ -243,14 +239,19 @@ static const struct dce110_link_enc_hpd_registers link_enc_hpd_regs[] = {
SRI(DP_DPHY_INTERNAL_CTRL, DP, id) \ SRI(DP_DPHY_INTERNAL_CTRL, DP, id) \
} }
static const struct dce110_link_enc_registers link_enc_regs[] = { static const struct dcn10_link_enc_registers link_enc_regs[] = {
link_regs(0), link_regs(0),
link_regs(1), link_regs(1),
link_regs(2), link_regs(2),
link_regs(3), link_regs(3)
link_regs(4), };
link_regs(5),
link_regs(6), static const struct dcn10_link_enc_shift le_shift = {
LINK_ENCODER_MASK_SH_LIST_DCN10(__SHIFT)
};
static const struct dcn10_link_enc_mask le_mask = {
LINK_ENCODER_MASK_SH_LIST_DCN10(_MASK)
}; };
#define ipp_regs(id)\ #define ipp_regs(id)\
...@@ -583,20 +584,22 @@ static const struct encoder_feature_support link_enc_feature = { ...@@ -583,20 +584,22 @@ static const struct encoder_feature_support link_enc_feature = {
struct link_encoder *dcn10_link_encoder_create( struct link_encoder *dcn10_link_encoder_create(
const struct encoder_init_data *enc_init_data) const struct encoder_init_data *enc_init_data)
{ {
struct dce110_link_encoder *enc110 = struct dcn10_link_encoder *enc10 =
kzalloc(sizeof(struct dce110_link_encoder), GFP_KERNEL); kzalloc(sizeof(struct dcn10_link_encoder), GFP_KERNEL);
if (!enc110) if (!enc10)
return NULL; return NULL;
dce110_link_encoder_construct(enc110, dcn10_link_encoder_construct(enc10,
enc_init_data, enc_init_data,
&link_enc_feature, &link_enc_feature,
&link_enc_regs[enc_init_data->transmitter], &link_enc_regs[enc_init_data->transmitter],
&link_enc_aux_regs[enc_init_data->channel - 1], &link_enc_aux_regs[enc_init_data->channel - 1],
&link_enc_hpd_regs[enc_init_data->hpd_source]); &link_enc_hpd_regs[enc_init_data->hpd_source],
&le_shift,
&le_mask);
return &enc110->base; return &enc10->base;
} }
struct clock_source *dcn10_clock_source_create( struct clock_source *dcn10_clock_source_create(
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment