aboutsummaryrefslogtreecommitdiffstats
path: root/common/recipes-kernel/linux/files/0859-drm-amd-dal-Use-native-memcmp-directly.patch
diff options
context:
space:
mode:
Diffstat (limited to 'common/recipes-kernel/linux/files/0859-drm-amd-dal-Use-native-memcmp-directly.patch')
-rw-r--r--common/recipes-kernel/linux/files/0859-drm-amd-dal-Use-native-memcmp-directly.patch104
1 files changed, 104 insertions, 0 deletions
diff --git a/common/recipes-kernel/linux/files/0859-drm-amd-dal-Use-native-memcmp-directly.patch b/common/recipes-kernel/linux/files/0859-drm-amd-dal-Use-native-memcmp-directly.patch
new file mode 100644
index 00000000..3be30733
--- /dev/null
+++ b/common/recipes-kernel/linux/files/0859-drm-amd-dal-Use-native-memcmp-directly.patch
@@ -0,0 +1,104 @@
+From 584476ee37b5d38e15b654d5cb75a0b6e3faa6a0 Mon Sep 17 00:00:00 2001
+From: Harry Wentland <harry.wentland@amd.com>
+Date: Sat, 27 Feb 2016 14:42:36 -0500
+Subject: [PATCH 0859/1110] drm/amd/dal: Use native memcmp directly
+
+Signed-off-by: Harry Wentland <harry.wentland@amd.com>
+Acked-by: Harry Wentland <harry.wentland@amd.com>
+---
+ drivers/gpu/drm/amd/dal/amdgpu_dm/amdgpu_dm_services.c | 5 -----
+ drivers/gpu/drm/amd/dal/dc/core/dc_resource.c | 2 +-
+ drivers/gpu/drm/amd/dal/dc/dce110/dce110_resource.c | 4 ++--
+ drivers/gpu/drm/amd/dal/dc/dce80/dce80_resource.c | 4 ++--
+ drivers/gpu/drm/amd/dal/dc/dm_services.h | 2 --
+ 5 files changed, 5 insertions(+), 12 deletions(-)
+
+diff --git a/drivers/gpu/drm/amd/dal/amdgpu_dm/amdgpu_dm_services.c b/drivers/gpu/drm/amd/dal/amdgpu_dm/amdgpu_dm_services.c
+index f587bc3..7bab44a 100644
+--- a/drivers/gpu/drm/amd/dal/amdgpu_dm/amdgpu_dm_services.c
++++ b/drivers/gpu/drm/amd/dal/amdgpu_dm/amdgpu_dm_services.c
+@@ -40,11 +40,6 @@
+ #define dm_realloc(ptr, size) krealloc(ptr, size, GFP_KERNEL)
+ #define dm_free(ptr) kfree(ptr)
+
+-int32_t dm_memcmp(const void *p1, const void *p2, uint32_t count)
+-{
+- return memcmp(p1, p2, count);
+-}
+-
+ int32_t dm_strncmp(const char *p1, const char *p2, uint32_t count)
+ {
+ return strncmp(p1, p2, count);
+diff --git a/drivers/gpu/drm/amd/dal/dc/core/dc_resource.c b/drivers/gpu/drm/amd/dal/dc/core/dc_resource.c
+index 519329b..fcb9a0f 100644
+--- a/drivers/gpu/drm/amd/dal/dc/core/dc_resource.c
++++ b/drivers/gpu/drm/amd/dal/dc/core/dc_resource.c
+@@ -98,7 +98,7 @@ bool is_same_timing(
+ const struct dc_crtc_timing *timing1,
+ const struct dc_crtc_timing *timing2)
+ {
+- return dm_memcmp(timing1, timing2, sizeof(struct dc_crtc_timing)) == 0;
++ return memcmp(timing1, timing2, sizeof(struct dc_crtc_timing)) == 0;
+ }
+
+ static bool is_sharable_clk_src(
+diff --git a/drivers/gpu/drm/amd/dal/dc/dce110/dce110_resource.c b/drivers/gpu/drm/amd/dal/dc/dce110/dce110_resource.c
+index 99484f6..2ebd398 100644
+--- a/drivers/gpu/drm/amd/dal/dc/dce110/dce110_resource.c
++++ b/drivers/gpu/drm/amd/dal/dc/dce110/dce110_resource.c
+@@ -813,7 +813,7 @@ enum dc_status dce110_validate_bandwidth(
+ * the same
+ */
+ if (number_of_displays != 0 && all_displays_in_sync)
+- if (dm_memcmp(&prev_timing,
++ if (memcmp(&prev_timing,
+ &pipe_ctx->stream->public.timing,
+ sizeof(struct dc_crtc_timing)) != 0)
+ all_displays_in_sync = false;
+@@ -857,7 +857,7 @@ enum dc_status dce110_validate_bandwidth(
+ "%s: Bandwidth validation failed!",
+ __func__);
+
+- if (dm_memcmp(&dc->current_context.bw_results,
++ if (memcmp(&dc->current_context.bw_results,
+ &context->bw_results, sizeof(context->bw_results))) {
+ struct log_entry log_entry;
+ dal_logger_open(
+diff --git a/drivers/gpu/drm/amd/dal/dc/dce80/dce80_resource.c b/drivers/gpu/drm/amd/dal/dc/dce80/dce80_resource.c
+index ae85fec..04f235a 100644
+--- a/drivers/gpu/drm/amd/dal/dc/dce80/dce80_resource.c
++++ b/drivers/gpu/drm/amd/dal/dc/dce80/dce80_resource.c
+@@ -811,7 +811,7 @@ enum dc_status dce80_validate_bandwidth(
+ * the same
+ */
+ if (number_of_displays != 0 && all_displays_in_sync)
+- if (dm_memcmp(&prev_timing,
++ if (memcmp(&prev_timing,
+ &pipe_ctx->stream->public.timing,
+ sizeof(struct dc_crtc_timing)) != 0)
+ all_displays_in_sync = false;
+@@ -855,7 +855,7 @@ enum dc_status dce80_validate_bandwidth(
+ "%s: Bandwidth validation failed!",
+ __func__);
+
+- if (dm_memcmp(&dc->current_context.bw_results,
++ if (memcmp(&dc->current_context.bw_results,
+ &context->bw_results, sizeof(context->bw_results))) {
+ struct log_entry log_entry;
+ dal_logger_open(
+diff --git a/drivers/gpu/drm/amd/dal/dc/dm_services.h b/drivers/gpu/drm/amd/dal/dc/dm_services.h
+index 8f1bb5c..3862682 100644
+--- a/drivers/gpu/drm/amd/dal/dc/dm_services.h
++++ b/drivers/gpu/drm/amd/dal/dc/dm_services.h
+@@ -44,8 +44,6 @@
+ #define dm_realloc(ptr, size) krealloc(ptr, size, GFP_KERNEL)
+ #define dm_free(ptr) kfree(ptr)
+
+-int32_t dm_memcmp(const void *p1, const void *p2, uint32_t count);
+-
+ int32_t dm_strncmp(const char *p1, const char *p2, uint32_t count);
+
+ irq_handler_idx dm_register_interrupt(
+--
+2.7.4
+