Commit cc57306f authored by Andrew Jiang's avatar Andrew Jiang Committed by Alex Deucher

drm/amd/display: Use constants from atom.h for HDMI caps read

Get rid of the constant we copied over before and just directly use the
constants from the file.
Signed-off-by: default avatarAndrew Jiang <Andrew.Jiang@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 7bef1af3
...@@ -24,6 +24,7 @@ ...@@ -24,6 +24,7 @@
*/ */
#include "dm_services.h" #include "dm_services.h"
#include "atom.h"
#include "dm_helpers.h" #include "dm_helpers.h"
#include "dc.h" #include "dc.h"
#include "grph_object_id.h" #include "grph_object_id.h"
...@@ -45,7 +46,6 @@ ...@@ -45,7 +46,6 @@
#include "dce/dce_11_0_enum.h" #include "dce/dce_11_0_enum.h"
#include "dce/dce_11_0_sh_mask.h" #include "dce/dce_11_0_sh_mask.h"
#define EXT_DISPLAY_PATH_CAPS__EXT_CHIP_MASK 0x007C /* Copied from atombios.h */
#define LINK_INFO(...) \ #define LINK_INFO(...) \
dm_logger_write(dc_ctx->logger, LOG_HW_HOTPLUG, \ dm_logger_write(dc_ctx->logger, LOG_HW_HOTPLUG, \
__VA_ARGS__) __VA_ARGS__)
...@@ -1696,7 +1696,7 @@ static void enable_link_hdmi(struct pipe_ctx *pipe_ctx) ...@@ -1696,7 +1696,7 @@ static void enable_link_hdmi(struct pipe_ctx *pipe_ctx)
if (dc_is_hdmi_signal(pipe_ctx->stream->signal)) { if (dc_is_hdmi_signal(pipe_ctx->stream->signal)) {
unsigned short masked_chip_caps = pipe_ctx->stream->sink->link->chip_caps & unsigned short masked_chip_caps = pipe_ctx->stream->sink->link->chip_caps &
EXT_DISPLAY_PATH_CAPS__EXT_CHIP_MASK; EXT_DISPLAY_PATH_CAPS__EXT_CHIP_MASK;
if (masked_chip_caps == (0x2 << 2)) { if (masked_chip_caps == EXT_DISPLAY_PATH_CAPS__HDMI20_TISN65DP159RSBT) {
/* DP159, Retimer settings */ /* DP159, Retimer settings */
eng_id = pipe_ctx->stream_res.stream_enc->id; eng_id = pipe_ctx->stream_res.stream_enc->id;
...@@ -1707,7 +1707,7 @@ static void enable_link_hdmi(struct pipe_ctx *pipe_ctx) ...@@ -1707,7 +1707,7 @@ static void enable_link_hdmi(struct pipe_ctx *pipe_ctx)
write_i2c_default_retimer_setting(pipe_ctx, write_i2c_default_retimer_setting(pipe_ctx,
is_vga_mode, is_over_340mhz); is_vga_mode, is_over_340mhz);
} }
} else if (masked_chip_caps == (0x1 << 2)) { } else if (masked_chip_caps == EXT_DISPLAY_PATH_CAPS__HDMI20_PI3EQX1204) {
/* PI3EQX1204, Redriver settings */ /* PI3EQX1204, Redriver settings */
write_i2c_redriver_setting(pipe_ctx, is_over_340mhz); write_i2c_redriver_setting(pipe_ctx, is_over_340mhz);
} }
......
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