diff options
Diffstat (limited to 'common/recipes-kernel/linux/files/0637-drm-amd-dal-Do-not-dereference-NULL-sink-at-the-end-.patch')
-rw-r--r-- | common/recipes-kernel/linux/files/0637-drm-amd-dal-Do-not-dereference-NULL-sink-at-the-end-.patch | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/common/recipes-kernel/linux/files/0637-drm-amd-dal-Do-not-dereference-NULL-sink-at-the-end-.patch b/common/recipes-kernel/linux/files/0637-drm-amd-dal-Do-not-dereference-NULL-sink-at-the-end-.patch new file mode 100644 index 00000000..196818eb --- /dev/null +++ b/common/recipes-kernel/linux/files/0637-drm-amd-dal-Do-not-dereference-NULL-sink-at-the-end-.patch @@ -0,0 +1,41 @@ +From 011186be4edf1b60f71a8a19c0234660e9a84bb9 Mon Sep 17 00:00:00 2001 +From: David Rokhvarg <David.Rokhvarg@amd.com> +Date: Thu, 17 Dec 2015 15:02:29 -0500 +Subject: [PATCH 0637/1110] drm/amd/dal: Do not dereference NULL sink at the + end of sink detection. + +While printing detection results for Disconnect case a null sink pointer +was dereferenced. + +Signed-off-by: David Rokhvarg <David.Rokhvarg@amd.com> +Acked-by: Jordan Lazare <Jordan.Lazare@amd.com> +--- + drivers/gpu/drm/amd/dal/dc/core/dc_link.c | 12 +++++++----- + 1 file changed, 7 insertions(+), 5 deletions(-) + +diff --git a/drivers/gpu/drm/amd/dal/dc/core/dc_link.c b/drivers/gpu/drm/amd/dal/dc/core/dc_link.c +index add76ca..d4b1085 100644 +--- a/drivers/gpu/drm/amd/dal/dc/core/dc_link.c ++++ b/drivers/gpu/drm/amd/dal/dc/core/dc_link.c +@@ -647,11 +647,13 @@ void dc_link_detect(const struct dc_link *dc_link) + link_disconnect_all_sinks(link); + } + +- LINK_INFO("link=%d, dc_sink_in=%p is now %s\n", +- link->link_index, &sink->public, +- (signal == SIGNAL_TYPE_NONE ? "Disconnected":"Connected")); +- +- /* TODO: */ ++ if (signal == SIGNAL_TYPE_NONE) { ++ LINK_INFO("link=%d is now Disconnected.\n", ++ link->link_index); ++ } else { ++ LINK_INFO("link=%d is now Connected. Sink ptr=%p Signal=%d\n", ++ link->link_index, &sink->public, signal); ++ } + + return; + } +-- +2.7.4 + |