From: Harry Wentland Date: Wed, 9 Aug 2017 01:01:20 +0000 (-0400) Subject: drm/amd/display: Fix warnings about uninitialized use X-Git-Tag: v4.15~362^2~23^2~193 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=533ed6c708334b697254ff831972b657f5c98a40;p=mirror_ubuntu-bionic-kernel.git drm/amd/display: Fix warnings about uninitialized use Signed-off-by: Harry Wentland Signed-off-by: Alex Deucher --- diff --git a/drivers/gpu/drm/amd/display/dc/core/dc_link.c b/drivers/gpu/drm/amd/display/dc/core/dc_link.c index 72eb6af62f45..b858fec72bd7 100644 --- a/drivers/gpu/drm/amd/display/dc/core/dc_link.c +++ b/drivers/gpu/drm/amd/display/dc/core/dc_link.c @@ -541,7 +541,7 @@ bool dc_link_detect(struct dc_link *link, bool boot) struct audio_support *aud_support = &link->dc->res_pool->audio_support; enum dc_edid_status edid_status; struct dc_context *dc_ctx = link->ctx; - struct dc_sink *sink; + struct dc_sink *sink = NULL; enum dc_connection_type new_connection_type = dc_connection_none; if (link->connector_signal == SIGNAL_TYPE_VIRTUAL) diff --git a/drivers/gpu/drm/amd/display/dc/i2caux/i2caux.c b/drivers/gpu/drm/amd/display/dc/i2caux/i2caux.c index da08cc1c6dc3..4035caf47d31 100644 --- a/drivers/gpu/drm/amd/display/dc/i2caux/i2caux.c +++ b/drivers/gpu/drm/amd/display/dc/i2caux/i2caux.c @@ -265,6 +265,8 @@ static bool get_hw_supported_ddc_line( { enum gpio_ddc_line line_found; + *line = GPIO_DDC_LINE_UNKNOWN; + if (!ddc) { BREAK_TO_DEBUGGER(); return false;