]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
4.4-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 26 Nov 2019 09:43:42 +0000 (10:43 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 26 Nov 2019 09:43:42 +0000 (10:43 +0100)
added patches:
ath9k_hw-fix-uninitialized-variable-data.patch

queue-4.4/ath9k_hw-fix-uninitialized-variable-data.patch [new file with mode: 0644]
queue-4.4/series

diff --git a/queue-4.4/ath9k_hw-fix-uninitialized-variable-data.patch b/queue-4.4/ath9k_hw-fix-uninitialized-variable-data.patch
new file mode 100644 (file)
index 0000000..81b4a3a
--- /dev/null
@@ -0,0 +1,39 @@
+From 80e84f36412e0c5172447b6947068dca0d04ee82 Mon Sep 17 00:00:00 2001
+From: Denis Efremov <efremov@linux.com>
+Date: Fri, 27 Sep 2019 01:56:04 +0300
+Subject: ath9k_hw: fix uninitialized variable data
+
+From: Denis Efremov <efremov@linux.com>
+
+commit 80e84f36412e0c5172447b6947068dca0d04ee82 upstream.
+
+Currently, data variable in ar9003_hw_thermo_cal_apply() could be
+uninitialized if ar9300_otp_read_word() will fail to read the value.
+Initialize data variable with 0 to prevent an undefined behavior. This
+will be enough to handle error case when ar9300_otp_read_word() fails.
+
+Fixes: 80fe43f2bbd5 ("ath9k_hw: Read and configure thermocal for AR9462")
+Cc: Rajkumar Manoharan <rmanohar@qca.qualcomm.com>
+Cc: John W. Linville <linville@tuxdriver.com>
+Cc: Kalle Valo <kvalo@codeaurora.org>
+Cc: "David S. Miller" <davem@davemloft.net>
+Cc: stable@vger.kernel.org
+Signed-off-by: Denis Efremov <efremov@linux.com>
+Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/net/wireless/ath/ath9k/ar9003_eeprom.c |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/drivers/net/wireless/ath/ath9k/ar9003_eeprom.c
++++ b/drivers/net/wireless/ath/ath9k/ar9003_eeprom.c
+@@ -4114,7 +4114,7 @@ static void ar9003_hw_thermometer_apply(
+ static void ar9003_hw_thermo_cal_apply(struct ath_hw *ah)
+ {
+-      u32 data, ko, kg;
++      u32 data = 0, ko, kg;
+       if (!AR_SREV_9462_20_OR_LATER(ah))
+               return;
index 00b9a865ee8ba101e66cded671eb6120b01a9f91..588169960fba45a4e932a9c6c0f9f209e75bac89 100644 (file)
@@ -97,3 +97,4 @@ pci-keystone-use-quirk-to-limit-mrrs-for-k2g.patch
 spi-omap2-mcspi-fix-dma-and-fifo-event-trigger-size-.patch
 ib-hfi1-ensure-full-gen3-speed-in-a-gen4-system.patch
 bluetooth-fix-invalid-free-in-bcsp_close.patch
+ath9k_hw-fix-uninitialized-variable-data.patch