Commit 553aae12 authored by Anthony Koo's avatar Anthony Koo Committed by Alex Deucher

drm/amd/display: Add APU cap in dc_caps

Some features should only be enabled on APUs or should not
be enabled on APUs.
Signed-off-by: default avatarAnthony Koo <anthony.koo@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 433f1aa7
...@@ -558,6 +558,7 @@ static bool construct(struct dc *dc, ...@@ -558,6 +558,7 @@ static bool construct(struct dc *dc,
dc_version = resource_parse_asic_id(init_params->asic_id); dc_version = resource_parse_asic_id(init_params->asic_id);
dc->ctx->dce_version = dc_version; dc->ctx->dce_version = dc_version;
#if defined(CONFIG_DRM_AMD_DC_FBC) #if defined(CONFIG_DRM_AMD_DC_FBC)
dc->ctx->fbc_gpu_addr = init_params->fbc_gpu_addr; dc->ctx->fbc_gpu_addr = init_params->fbc_gpu_addr;
#endif #endif
......
...@@ -60,6 +60,7 @@ struct dc_caps { ...@@ -60,6 +60,7 @@ struct dc_caps {
unsigned int max_video_width; unsigned int max_video_width;
bool dcc_const_color; bool dcc_const_color;
bool dynamic_audio; bool dynamic_audio;
bool is_apu;
}; };
struct dc_dcc_surface_param { struct dc_dcc_surface_param {
......
...@@ -1156,6 +1156,7 @@ static bool construct( ...@@ -1156,6 +1156,7 @@ static bool construct(
dc->caps.max_downscale_ratio = 150; dc->caps.max_downscale_ratio = 150;
dc->caps.i2c_speed_in_khz = 100; dc->caps.i2c_speed_in_khz = 100;
dc->caps.max_cursor_size = 128; dc->caps.max_cursor_size = 128;
dc->caps.is_apu = true;
/************************************************* /*************************************************
* Create resources * * Create resources *
......
...@@ -957,6 +957,7 @@ static bool dce81_construct( ...@@ -957,6 +957,7 @@ static bool dce81_construct(
dc->caps.max_downscale_ratio = 200; dc->caps.max_downscale_ratio = 200;
dc->caps.i2c_speed_in_khz = 40; dc->caps.i2c_speed_in_khz = 40;
dc->caps.max_cursor_size = 128; dc->caps.max_cursor_size = 128;
dc->caps.is_apu = true;
/************************************************* /*************************************************
* Create resources * * Create resources *
...@@ -1121,6 +1122,7 @@ static bool dce83_construct( ...@@ -1121,6 +1122,7 @@ static bool dce83_construct(
dc->caps.max_downscale_ratio = 200; dc->caps.max_downscale_ratio = 200;
dc->caps.i2c_speed_in_khz = 40; dc->caps.i2c_speed_in_khz = 40;
dc->caps.max_cursor_size = 128; dc->caps.max_cursor_size = 128;
dc->caps.is_apu = true;
/************************************************* /*************************************************
* Create resources * * Create resources *
......
...@@ -1235,6 +1235,7 @@ static bool construct( ...@@ -1235,6 +1235,7 @@ static bool construct(
dc->caps.max_cursor_size = 256; dc->caps.max_cursor_size = 256;
dc->caps.max_slave_planes = 1; dc->caps.max_slave_planes = 1;
dc->caps.is_apu = true;
if (dc->ctx->dce_environment == DCE_ENV_PRODUCTION_DRV) if (dc->ctx->dce_environment == DCE_ENV_PRODUCTION_DRV)
dc->debug = debug_defaults_drv; dc->debug = debug_defaults_drv;
......
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