diff options
author | Felix Fietkau <nbd@nbd.name> | 2017-01-27 11:11:00 +0100 |
---|---|---|
committer | Felix Fietkau <nbd@nbd.name> | 2017-02-03 12:35:44 +0100 |
commit | eccb2e5e59f01dcd5a70c390e934f11b62e7dce8 (patch) | |
tree | 5bb44b87764b4026d3dcbc743e5008b672482710 /package/kernel | |
parent | 50efd403e67c6195a057417f8a2436d189c8dc81 (diff) | |
download | mtk-20170518-eccb2e5e59f01dcd5a70c390e934f11b62e7dce8.zip mtk-20170518-eccb2e5e59f01dcd5a70c390e934f11b62e7dce8.tar.gz mtk-20170518-eccb2e5e59f01dcd5a70c390e934f11b62e7dce8.tar.bz2 |
acx-mac80211: fix scan API error that could lead to a crash
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'package/kernel')
-rw-r--r-- | package/kernel/acx-mac80211/patches/300-api_sync.patch | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/package/kernel/acx-mac80211/patches/300-api_sync.patch b/package/kernel/acx-mac80211/patches/300-api_sync.patch index 94d6135..d055271 100644 --- a/package/kernel/acx-mac80211/patches/300-api_sync.patch +++ b/package/kernel/acx-mac80211/patches/300-api_sync.patch @@ -81,3 +81,32 @@ adev->channel = channel; +--- a/merge.c ++++ b/merge.c +@@ -2776,7 +2776,10 @@ void acx_irq_work(struct work_struct *wo + /* HOST_INT_SCAN_COMPLETE */ + if (irqmasked & HOST_INT_SCAN_COMPLETE) { + if (test_bit(ACX_FLAG_SCANNING, &adev->flags)) { +- ieee80211_scan_completed(adev->hw, false); ++ struct cfg80211_scan_info info = { ++ .aborted = false ++ }; ++ ieee80211_scan_completed(adev->hw, &info); + log(L_INIT, "scan completed\n"); + clear_bit(ACX_FLAG_SCANNING, &adev->flags); + } +@@ -3138,10 +3141,13 @@ int acx_op_start(struct ieee80211_hw *hw + + void acx_stop(acx_device_t *adev) + { ++ struct cfg80211_scan_info info = { ++ .aborted = true ++ }; + acxmem_lock_flags; + + if (test_bit(ACX_FLAG_SCANNING, &adev->flags)) { +- ieee80211_scan_completed(adev->hw, true); ++ ieee80211_scan_completed(adev->hw, &info); + acx_issue_cmd(adev, ACX1xx_CMD_STOP_SCAN, NULL, 0); + clear_bit(ACX_FLAG_SCANNING, &adev->flags); + } |