Home Home > GIT Browse > openSUSE-15.0
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2019-10-19 08:45:58 +0200
committerTakashi Iwai <tiwai@suse.de>2019-10-19 08:46:57 +0200
commitb3a4a196c2276459688536064f740f6629aa7770 (patch)
treee980a301cf2455cd8c6662cde62145dcc245a385
parent250f10e2c2795c02cbe2c3154847c8d44a19e303 (diff)
ALSA: hda/hdmi: remove redundant assignment to variable pcm_idx
(bsc#1051510).
-rw-r--r--patches.suse/ALSA-hda-hdmi-remove-redundant-assignment-to-variabl.patch37
-rw-r--r--series.conf1
2 files changed, 38 insertions, 0 deletions
diff --git a/patches.suse/ALSA-hda-hdmi-remove-redundant-assignment-to-variabl.patch b/patches.suse/ALSA-hda-hdmi-remove-redundant-assignment-to-variabl.patch
new file mode 100644
index 0000000000..658622cdc9
--- /dev/null
+++ b/patches.suse/ALSA-hda-hdmi-remove-redundant-assignment-to-variabl.patch
@@ -0,0 +1,37 @@
+From f953e72c9ca60ef13bb9680af8a5baf92cb93e52 Mon Sep 17 00:00:00 2001
+From: Colin Ian King <colin.king@canonical.com>
+Date: Thu, 5 Sep 2019 16:48:26 +0100
+Subject: [PATCH] ALSA: hda/hdmi: remove redundant assignment to variable pcm_idx
+Git-commit: f953e72c9ca60ef13bb9680af8a5baf92cb93e52
+Patch-mainline: v5.4-rc1
+References: bsc#1051510
+
+Variable pcm_idx is being initialized with a value that is never read
+and is being re-assigned immediately afterwards. The assignment is
+redundant and hence can be removed.
+
+Addresses-coverity: ("Unused value")
+Signed-off-by: Colin Ian King <colin.king@canonical.com>
+Link: https://lore.kernel.org/r/20190905154826.5916-1-colin.king@canonical.com
+Signed-off-by: Takashi Iwai <tiwai@suse.de>
+
+---
+ sound/pci/hda/patch_hdmi.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/sound/pci/hda/patch_hdmi.c b/sound/pci/hda/patch_hdmi.c
+index 83b8b9d27711..bca5de78e9ad 100644
+--- a/sound/pci/hda/patch_hdmi.c
++++ b/sound/pci/hda/patch_hdmi.c
+@@ -1440,7 +1440,7 @@ static bool update_eld(struct hda_codec *codec,
+ struct hdmi_spec *spec = codec->spec;
+ bool old_eld_valid = pin_eld->eld_valid;
+ bool eld_changed;
+- int pcm_idx = -1;
++ int pcm_idx;
+
+ /* for monitor disconnection, save pcm_idx firstly */
+ pcm_idx = per_pin->pcm_idx;
+--
+2.16.4
+
diff --git a/series.conf b/series.conf
index 5b0a0d2f8b..2af4559bb7 100644
--- a/series.conf
+++ b/series.conf
@@ -24605,6 +24605,7 @@
patches.suse/ALSA-hda-Define-a-fallback_pin_fixup_tbl-for-alc269-.patch
patches.suse/ALSA-hda-realtek-Check-beep-whitelist-before-assigni.patch
patches.suse/ALSA-hda-realtek-Blacklist-PC-beep-for-Lenovo-ThinkC.patch
+ patches.suse/ALSA-hda-hdmi-remove-redundant-assignment-to-variabl.patch
patches.suse/ASoC-es8328-Fix-copy-paste-error-in-es8328_right_lin.patch
patches.suse/ASoC-wm8737-Fix-copy-paste-error-in-wm8737_snd_contr.patch
patches.suse/ASoC-Intel-Baytrail-Fix-implicit-fallthrough-warning.patch