summaryrefslogtreecommitdiff
path: root/0002-ALSA-hda-Fix-potential-access-overflow-in-beep-helper.patch
diff options
context:
space:
mode:
authorjc_gargma <jc_gargma@iserlohn-fortress.net>2020-04-17 16:00:33 -0700
committerjc_gargma <jc_gargma@iserlohn-fortress.net>2020-04-17 16:00:33 -0700
commit88472acada1b3a6467b0dbfe73bfc03077db03d9 (patch)
treee5b2ce46bffc73d5567a143e09352fbf077581e0 /0002-ALSA-hda-Fix-potential-access-overflow-in-beep-helper.patch
parentUpdated to 5.6.4 (diff)
downloadlinux-88472acada1b3a6467b0dbfe73bfc03077db03d9.tar.xz
Updated to 5.6.5
Diffstat (limited to '0002-ALSA-hda-Fix-potential-access-overflow-in-beep-helper.patch')
-rw-r--r--0002-ALSA-hda-Fix-potential-access-overflow-in-beep-helper.patch42
1 files changed, 0 insertions, 42 deletions
diff --git a/0002-ALSA-hda-Fix-potential-access-overflow-in-beep-helper.patch b/0002-ALSA-hda-Fix-potential-access-overflow-in-beep-helper.patch
deleted file mode 100644
index 48dfbf5..0000000
--- a/0002-ALSA-hda-Fix-potential-access-overflow-in-beep-helper.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From 28a3a4bec629ccb9cef64c546998052e0806cb1b Mon Sep 17 00:00:00 2001
-From: Takashi Iwai <tiwai@suse.de>
-Date: Tue, 7 Apr 2020 10:36:22 +0200
-Subject: ALSA: hda: Fix potential access overflow in beep helper
-
-The beep control helper function blindly stores the values in two
-stereo channels no matter whether the actual control is mono or
-stereo. This is practically harmless, but it annoys the recently
-introduced sanity check, resulting in an error when the checker is
-enabled.
-
-This patch corrects the behavior to store only on the defined array
-member.
-
-BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=207139
-Cc: <stable@vger.kernel.org>
-Signed-off-by: Takashi Iwai <tiwai@suse.de>
----
- sound/pci/hda/hda_beep.c | 6 +++++-
- 1 file changed, 5 insertions(+), 1 deletion(-)
-
-diff --git a/sound/pci/hda/hda_beep.c b/sound/pci/hda/hda_beep.c
-index f5fd62ed4df5..841523f6b88d 100644
---- a/sound/pci/hda/hda_beep.c
-+++ b/sound/pci/hda/hda_beep.c
-@@ -290,8 +290,12 @@ int snd_hda_mixer_amp_switch_get_beep(struct snd_kcontrol *kcontrol,
- {
- struct hda_codec *codec = snd_kcontrol_chip(kcontrol);
- struct hda_beep *beep = codec->beep;
-+ int chs = get_amp_channels(kcontrol);
-+
- if (beep && (!beep->enabled || !ctl_has_mute(kcontrol))) {
-- ucontrol->value.integer.value[0] =
-+ if (chs & 1)
-+ ucontrol->value.integer.value[0] = beep->enabled;
-+ if (chs & 2)
- ucontrol->value.integer.value[1] = beep->enabled;
- return 0;
- }
---
-cgit v1.2.3-1-gf6bb5
-