summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/display
diff options
context:
space:
mode:
authorJaehyun Chung <jaehyun.chung@amd.com>2020-04-28 12:41:54 -0400
committerAlex Deucher <alexander.deucher@amd.com>2020-05-28 14:00:47 -0400
commit1810f441ae112b0d44fe52ab4147eb768084e978 (patch)
tree940a01473ee2318bc2ea8dba096a528f6ec6eebe /drivers/gpu/drm/amd/display
parent9ca1f474cea0edc14a1d7ec933e5472c0ff115d3 (diff)
drm/amd/display: Handle persistence in DM
[Why] Remove dm_write_persistent_data and dm_read_persistent_data as persistence should be handled in DM. [How] Remove functions. Move read/write calls into DM layer while maintaining logic. Signed-off-by: Jaehyun Chung <jaehyun.chung@amd.com> Reviewed-by: Anthony Koo <Anthony.Koo@amd.com> Acked-by: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/display')
-rw-r--r--drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_services.c25
-rw-r--r--drivers/gpu/drm/amd/display/dc/dm_services.h69
-rw-r--r--drivers/gpu/drm/amd/display/modules/inc/mod_stats.h8
3 files changed, 7 insertions, 95 deletions
diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_services.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_services.c
index 022da5d45d4d..51f57420fadd 100644
--- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_services.c
+++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_services.c
@@ -47,29 +47,4 @@ void dm_perf_trace_timestamp(const char *func_name, unsigned int line)
{
}
-bool dm_write_persistent_data(struct dc_context *ctx,
- const struct dc_sink *sink,
- const char *module_name,
- const char *key_name,
- void *params,
- unsigned int size,
- struct persistent_data_flag *flag)
-{
- /*TODO implement*/
- return false;
-}
-
-bool dm_read_persistent_data(struct dc_context *ctx,
- const struct dc_sink *sink,
- const char *module_name,
- const char *key_name,
- void *params,
- unsigned int size,
- struct persistent_data_flag *flag)
-{
- /*TODO implement*/
- return false;
-}
-
/**** power component interfaces ****/
-
diff --git a/drivers/gpu/drm/amd/display/dc/dm_services.h b/drivers/gpu/drm/amd/display/dc/dm_services.h
index 968ff1fef486..fdd1943c828d 100644
--- a/drivers/gpu/drm/amd/display/dc/dm_services.h
+++ b/drivers/gpu/drm/amd/display/dc/dm_services.h
@@ -261,75 +261,6 @@ struct persistent_data_flag {
bool save_per_edid;
};
-/* Call to write data in registry editor for persistent data storage.
- *
- * \inputs sink - identify edid/link for registry folder creation
- * module name - identify folders for registry
- * key name - identify keys within folders for registry
- * params - value to write in defined folder/key
- * size - size of the input params
- * flag - determine whether to save by link or edid
- *
- * \returns true - call is successful
- * false - call failed
- *
- * sink module key
- * -----------------------------------------------------------------------------
- * NULL NULL NULL - failure
- * NULL NULL - - create key with param value
- * under base folder
- * NULL - NULL - create module folder under base folder
- * - NULL NULL - failure
- * NULL - - - create key under module folder
- * with no edid/link identification
- * - NULL - - create key with param value
- * under base folder
- * - - NULL - create module folder under base folder
- * - - - - create key under module folder
- * with edid/link identification
- */
-bool dm_write_persistent_data(struct dc_context *ctx,
- const struct dc_sink *sink,
- const char *module_name,
- const char *key_name,
- void *params,
- unsigned int size,
- struct persistent_data_flag *flag);
-
-
-/* Call to read data in registry editor for persistent data storage.
- *
- * \inputs sink - identify edid/link for registry folder creation
- * module name - identify folders for registry
- * key name - identify keys within folders for registry
- * size - size of the output params
- * flag - determine whether it was save by link or edid
- *
- * \returns params - value read from defined folder/key
- * true - call is successful
- * false - call failed
- *
- * sink module key
- * -----------------------------------------------------------------------------
- * NULL NULL NULL - failure
- * NULL NULL - - read key under base folder
- * NULL - NULL - failure
- * - NULL NULL - failure
- * NULL - - - read key under module folder
- * with no edid/link identification
- * - NULL - - read key under base folder
- * - - NULL - failure
- * - - - - read key under module folder
- * with edid/link identification
- */
-bool dm_read_persistent_data(struct dc_context *ctx,
- const struct dc_sink *sink,
- const char *module_name,
- const char *key_name,
- void *params,
- unsigned int size,
- struct persistent_data_flag *flag);
-
bool dm_query_extended_brightness_caps
(struct dc_context *ctx, enum dm_acpi_display_type display,
struct dm_acpi_atif_backlight_caps *pCaps);
diff --git a/drivers/gpu/drm/amd/display/modules/inc/mod_stats.h b/drivers/gpu/drm/amd/display/modules/inc/mod_stats.h
index 3812094b52e8..4220fd8fdd60 100644
--- a/drivers/gpu/drm/amd/display/modules/inc/mod_stats.h
+++ b/drivers/gpu/drm/amd/display/modules/inc/mod_stats.h
@@ -36,7 +36,13 @@ struct mod_stats_caps {
bool dummy;
};
-struct mod_stats *mod_stats_create(struct dc *dc);
+struct mod_stats_init_params {
+ unsigned int stats_enable;
+ unsigned int stats_entries;
+};
+
+struct mod_stats *mod_stats_create(struct dc *dc,
+ struct mod_stats_init_params *init_params);
void mod_stats_destroy(struct mod_stats *mod_stats);