aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTomi Valkeinen <tomi.valkeinen@ti.com>2018-03-29 06:40:36 -0400
committerSean Paul <seanpaul@chromium.org>2018-05-07 10:19:11 -0400
commit77eeac24b10fc84d3ffd5b11a897dff88dde244d (patch)
tree642570608b8b3f7b2be5c8f9fe376d0d058c20da
parent4a9fbfcab19d3f71ad2bf0bcb653c4ee84e69c7f (diff)
drm/omap: fix uninitialized ret variable
audio_config function for both HDMI4 and HDMI5 return uninitialized value as the error code if the display is not currently enabled. For some reason this has not caused any issues. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Link: https://patchwork.freedesktop.org/patch/msgid/20180329104038.29154-1-tomi.valkeinen@ti.com Reviewed-by: Emil Velikov <emil.velikov@collabora.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Sean Paul <seanpaul@chromium.org>
-rw-r--r--drivers/gpu/drm/omapdrm/dss/hdmi4.c2
-rw-r--r--drivers/gpu/drm/omapdrm/dss/hdmi5.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/omapdrm/dss/hdmi4.c b/drivers/gpu/drm/omapdrm/dss/hdmi4.c
index 97c88861d67a..5879f45f6fc9 100644
--- a/drivers/gpu/drm/omapdrm/dss/hdmi4.c
+++ b/drivers/gpu/drm/omapdrm/dss/hdmi4.c
@@ -679,7 +679,7 @@ static int hdmi_audio_config(struct device *dev,
679 struct omap_dss_audio *dss_audio) 679 struct omap_dss_audio *dss_audio)
680{ 680{
681 struct omap_hdmi *hd = dev_get_drvdata(dev); 681 struct omap_hdmi *hd = dev_get_drvdata(dev);
682 int ret; 682 int ret = 0;
683 683
684 mutex_lock(&hd->lock); 684 mutex_lock(&hd->lock);
685 685
diff --git a/drivers/gpu/drm/omapdrm/dss/hdmi5.c b/drivers/gpu/drm/omapdrm/dss/hdmi5.c
index d28da9ac3e90..ae1a001d1b83 100644
--- a/drivers/gpu/drm/omapdrm/dss/hdmi5.c
+++ b/drivers/gpu/drm/omapdrm/dss/hdmi5.c
@@ -671,7 +671,7 @@ static int hdmi_audio_config(struct device *dev,
671 struct omap_dss_audio *dss_audio) 671 struct omap_dss_audio *dss_audio)
672{ 672{
673 struct omap_hdmi *hd = dev_get_drvdata(dev); 673 struct omap_hdmi *hd = dev_get_drvdata(dev);
674 int ret; 674 int ret = 0;
675 675
676 mutex_lock(&hd->lock); 676 mutex_lock(&hd->lock);
677 677