]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
5.0-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 4 May 2019 09:22:29 +0000 (11:22 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 4 May 2019 09:22:29 +0000 (11:22 +0200)
added patches:
ath10k-drop-warn_on-s-that-always-trigger-during-system-resume.patch
iwlwifi-mvm-properly-check-debugfs-dentry-before-using-it.patch

queue-5.0/ath10k-drop-warn_on-s-that-always-trigger-during-system-resume.patch [new file with mode: 0644]
queue-5.0/iwlwifi-mvm-properly-check-debugfs-dentry-before-using-it.patch [new file with mode: 0644]
queue-5.0/series

diff --git a/queue-5.0/ath10k-drop-warn_on-s-that-always-trigger-during-system-resume.patch b/queue-5.0/ath10k-drop-warn_on-s-that-always-trigger-during-system-resume.patch
new file mode 100644 (file)
index 0000000..cb6af74
--- /dev/null
@@ -0,0 +1,51 @@
+From 9e80ad37f6788ed52b89a3cfcd593e0aa69b216d Mon Sep 17 00:00:00 2001
+From: "Rafael J. Wysocki" <rafael.j.wysocki@intel.com>
+Date: Sun, 3 Mar 2019 18:24:33 +0100
+Subject: ath10k: Drop WARN_ON()s that always trigger during system resume
+
+From: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
+
+commit 9e80ad37f6788ed52b89a3cfcd593e0aa69b216d upstream.
+
+ath10k_mac_vif_chan() always returns an error for the given vif
+during system-wide resume which reliably triggers two WARN_ON()s
+in ath10k_bss_info_changed() and they are not particularly
+useful in that code path, so drop them.
+
+Tested: QCA6174 hw3.2 PCI with WLAN.RM.2.0-00180-QCARMSWPZ-1
+Tested: QCA6174 hw3.2 SDIO with WLAN.RMH.4.4.1-00007-QCARMSWP-1
+
+Fixes: cd93b83ad927 ("ath10k: support for multicast rate control")
+Fixes: f279294e9ee2 ("ath10k: add support for configuring management packet rate")
+Cc: stable@vger.kernel.org
+Reviewed-by: Brian Norris <briannorris@chromium.org>
+Tested-by: Brian Norris <briannorris@chromium.org>
+Tested-by: Claire Chang <tientzu@chromium.org>
+Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
+Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/net/wireless/ath/ath10k/mac.c |    4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+--- a/drivers/net/wireless/ath/ath10k/mac.c
++++ b/drivers/net/wireless/ath/ath10k/mac.c
+@@ -5705,7 +5705,7 @@ static void ath10k_bss_info_changed(stru
+       }
+       if (changed & BSS_CHANGED_MCAST_RATE &&
+-          !WARN_ON(ath10k_mac_vif_chan(arvif->vif, &def))) {
++          !ath10k_mac_vif_chan(arvif->vif, &def)) {
+               band = def.chan->band;
+               rateidx = vif->bss_conf.mcast_rate[band] - 1;
+@@ -5743,7 +5743,7 @@ static void ath10k_bss_info_changed(stru
+       }
+       if (changed & BSS_CHANGED_BASIC_RATES) {
+-              if (WARN_ON(ath10k_mac_vif_chan(vif, &def))) {
++              if (ath10k_mac_vif_chan(vif, &def)) {
+                       mutex_unlock(&ar->conf_mutex);
+                       return;
+               }
diff --git a/queue-5.0/iwlwifi-mvm-properly-check-debugfs-dentry-before-using-it.patch b/queue-5.0/iwlwifi-mvm-properly-check-debugfs-dentry-before-using-it.patch
new file mode 100644 (file)
index 0000000..46efa62
--- /dev/null
@@ -0,0 +1,48 @@
+From 154d4899e4111ae24e68d6ba955f46856cb046bc Mon Sep 17 00:00:00 2001
+From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+Date: Sat, 30 Mar 2019 10:31:52 +0100
+Subject: iwlwifi: mvm: properly check debugfs dentry before using it
+
+From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+commit 154d4899e4111ae24e68d6ba955f46856cb046bc upstream.
+
+debugfs can now report an error code if something went wrong instead of
+just NULL.  So if the return value is to be used as a "real" dentry, it
+needs to be checked if it is an error before dereferencing it.
+
+This is now happening because of ff9fb72bc077 ("debugfs: return error
+values, not NULL").  If multiple iwlwifi devices are in the system, this
+can cause problems when the driver attempts to create the main debugfs
+directory again.  Later on in the code we fail horribly by trying to
+dereference a pointer that is an error value.
+
+Reported-by: Laura Abbott <labbott@redhat.com>
+Reported-by: Gabriel Ramirez <gabriello.ramirez@gmail.com>
+Cc: Johannes Berg <johannes.berg@intel.com>
+Cc: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
+Cc: Luca Coelho <luciano.coelho@intel.com>
+Cc: Intel Linux Wireless <linuxwifi@intel.com>
+Cc: Kalle Valo <kvalo@codeaurora.org>
+Cc: stable <stable@vger.kernel.org> # 5.0
+Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/net/wireless/intel/iwlwifi/mvm/debugfs-vif.c |    5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/drivers/net/wireless/intel/iwlwifi/mvm/debugfs-vif.c
++++ b/drivers/net/wireless/intel/iwlwifi/mvm/debugfs-vif.c
+@@ -1482,6 +1482,11 @@ void iwl_mvm_vif_dbgfs_register(struct i
+               return;
+       mvmvif->dbgfs_dir = debugfs_create_dir("iwlmvm", dbgfs_dir);
++      if (IS_ERR_OR_NULL(mvmvif->dbgfs_dir)) {
++              IWL_ERR(mvm, "Failed to create debugfs directory under %pd\n",
++                      dbgfs_dir);
++              return;
++      }
+       if (!mvmvif->dbgfs_dir) {
+               IWL_ERR(mvm, "Failed to create debugfs directory under %pd\n",
index 3674b04244c6c082729c566c0b5c64173f0e288e..0145cb59a19b8ef4326bdf568718bbb6cf8f2b86 100644 (file)
@@ -28,3 +28,5 @@ net-tls-fix-copy-to-fragments-in-reencrypt.patch
 kvm-x86-whitelist-port-0x7e-for-pre-incrementing-rip.patch
 kvm-nvmx-fix-size-checks-in-vmx_set_nested_state.patch
 alsa-line6-use-dynamic-buffers.patch
+iwlwifi-mvm-properly-check-debugfs-dentry-before-using-it.patch
+ath10k-drop-warn_on-s-that-always-trigger-during-system-resume.patch