aboutsummaryrefslogtreecommitdiffstats
path: root/package/kernel/mac80211/patches
Commit message (Collapse)AuthorAgeFilesLines
...
* mac80211: revert "wireless: set correct mandatory rate flags"Matthias Schiffer2018-01-261-0/+60
| | | | | | | | | Revert upstream commit 1bd773c077de "wireless: set correct mandatory rate flags", as it breaks 11s interoperability: nodes can only associate when neither or both have this patch. As this is a regression from released versions, revert to the old code for now. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* mac80211: mesh: drop frames appearing to be from usFelix Fietkau2018-01-251-0/+25
| | | | | | | Upstream backport to fix issues arising from devices with duplicate MAC addresses Signed-off-by: Felix Fietkau <nbd@nbd.name>
* ath9k: discard undersized packetsFelix Fietkau2018-01-171-0/+25
| | | | | | | | Sometimes the hardware will push small packets that trigger a WARN_ON in mac80211. Discard them early to avoid this issue. Reported-by: Stijn Tintel <stijn@linux-ipv6.be> Signed-off-by: Felix Fietkau <nbd@nbd.name>
* ath9k, ath10k(-ct): move spectral scan support under a separate config symbolMatthias Schiffer2018-01-132-0/+194
| | | | | | | | | | | | | Backport patches that separate spectral scan support from general debugfs support of ath9k/ath10k; this allows to remove the dependency on KERNEL_RELAY from these driver packages even with debugfs enabled and avoids the memory footprint of the relay buffers allocated by ath9k/ath10k even when they aren't used at all. The KERNEL_RELAY dependency is moved to a new config symbol that enables spectral scan support in these drivers. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* mac80211: ath10k: search DT for BDF variant infoSven Eckelmann2018-01-131-0/+106
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Board Data File (BDF) is loaded upon driver boot-up procedure. The right board data file is identified on QCA4019 using bus, bmi-chip-id and bmi-board-id. The problem, however, can occur when the (default) board data file cannot fulfill the vendor requirements and it is necessary to use a different board data file. This problem was solved for SMBIOS by adding a special SMBIOS type 0xF8. Something similar has to be provided for systems without SMBIOS but with device trees. No solution was specified by QCA and therefore a new one has to be found for ath10k. The device tree requires addition strings to define the variant name wifi@a000000 { status = "okay"; qcom,ath10k-calibration-variant = "RT-AC58U"; }; wifi@a800000 { status = "okay"; qcom,ath10k-calibration-variant = "RT-AC58U"; }; This would create the boarddata identifiers for the board-2.bin search * bus=ahb,bmi-chip-id=0,bmi-board-id=16,variant=RT-AC58U * bus=ahb,bmi-chip-id=0,bmi-board-id=17,variant=RT-AC58U Signed-off-by: Sven Eckelmann <sven.eckelmann@open-mesh.com>
* mac80211: tweak TSQ settingsFelix Fietkau2017-11-292-1/+16
| | | | | | | | | | Latencies can be much higher on wifi devices, especially with aggregation. Tune the network stack setting introduced in the previous commit to account for that. This commit reintroduces the previously reverted one with a fix for the crash issues Signed-off-by: Felix Fietkau <nbd@nbd.name>
* Revert "mac80211: tweak TSQ settings"Felix Fietkau2017-11-282-15/+1
| | | | | | | | This reverts commit 2dc485250d516f1535eeaf53f0f2f5742e5f9e0c. This patch needs some additional checks in order to avoid overwriting unrelated fields for request sockets. Signed-off-by: Felix Fietkau <nbd@nbd.name>
* mac80211: fix a race condition that could lead to a use-after-free on a timerFelix Fietkau2017-11-201-0/+37
| | | | Signed-off-by: Felix Fietkau <nbd@nbd.name>
* mac80211: fix netlink family id for nl80211 messagesFelix Fietkau2017-11-201-0/+10
| | | | | | | Fixes responses for nl80211 calls Reported-by: Koen Vandeputte <koen.vandeputte@ncentric.com> Signed-off-by: Felix Fietkau <nbd@nbd.name>
* mac80211: tweak TSQ settingsFelix Fietkau2017-11-162-1/+15
| | | | | | | | Latencies can be much higher on wifi devices, especially with aggregation. Tune the network stack setting introduced in the previous commit to account for that Signed-off-by: Felix Fietkau <nbd@nbd.name>
* mac80211: update to wireless-testing 2017-11-01Felix Fietkau2017-11-1628-492/+716
| | | | | | | The wireless regdb is now loaded via firmware loading, CRDA support and built-in regdb support have been removed. Signed-off-by: Felix Fietkau <nbd@nbd.name>
* ath9k: unset the default LED pin if used by platform buttonsMathias Kresin2017-11-041-4/+7
| | | | | | | | | | Unset the default LED gpio pin if the same gpio pin is used by a button defined via platform button. It prevents the change of the GPIO value on wireless up/down or wireless traffic. Fixes: FS#1129 Signed-off-by: Mathias Kresin <dev@kresin.me>
* mac80211: backport fixes for fix for CVE-2017-13080Jonas Gorski2017-10-262-0/+106
| | | | | | | Backport two fixes for the fix of CVE-2017-13080, preventing side channel attacks and making it work for TKIP. Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
* mac80211: backport kernel fix for CVE-2017-13080Stijn Tintel2017-10-171-0/+81
| | | | Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
* mac80211: fix tx power regressionFelix Fietkau2017-10-131-1/+1
| | | | | | | Revert an accidental change that was introduced by having an old version of the patch in my git tree, which was merged in 609208597b6d Signed-off-by: Felix Fietkau <nbd@nbd.name>
* mac80211: update to wireless-testing 2017-10-06Felix Fietkau2017-10-1315-195/+345
| | | | | | | Rework the code to get rid of some extra kernel module dependencies introduced in the last update. Signed-off-by: Felix Fietkau <nbd@nbd.name>
* mac80211: fix compile error on PowerPC (PPC_85xx)Hauke Mehrtens2017-10-011-0/+81
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Including linux/interrupt.h in linux/hrtimer.h causes this error message on PowerPC builds on x86, ARM and MIPS it works: CC [M] /backports-4.14-rc2-1/compat/main.o In file included from /backports-4.14-rc2-1/backport-include/linux/printk.h:5:0, from ./include/linux/kernel.h:13, from /backports-4.14-rc2-1/backport-include/linux/kernel.h:3, from ./include/linux/list.h:8, from /backports-4.14-rc2-1/backport-include/linux/list.h:3, from ./include/linux/module.h:9, from /backports-4.14-rc2-1/backport-include/linux/module.h:3, from /backports-4.14-rc2-1/compat/main.c:1: ./include/linux/ratelimit.h: In function 'ratelimit_state_exit': ./include/linux/ratelimit.h:62:11: error: dereferencing pointer to incomplete type 'struct task_struct' current->comm, rs->missed); ^ ./include/linux/printk.h:279:37: note: in definition of macro 'pr_warning' printk(KERN_WARNING pr_fmt(fmt), ##__VA_ARGS__) ^ ./include/linux/ratelimit.h:61:3: note: in expansion of macro 'pr_warn' pr_warn("%s: %d output lines suppressed due to ratelimiting\n", ^ The backport of the hrtimer_start() functions needs the linux/interrupt.h because some parts are defined there. Fix this by moving the hrtimer_start() backport to the linux/interrupt.h backport header file. Fixes: a8f63a0717f5: ("mac80211: update to backports-4.14-rc2") Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
* mac80211: update to backports-4.14-rc2Hauke Mehrtens2017-10-01142-7093/+317
| | | | | | | | | | | | | | | | | | | | This updates mac80211 to backprots-4.14-rc2. This was compile and runtime tested with ath9k, ath10k and b43 with multiple stations and ieee80211w and in different scenarios by many other people. To create the backports-4.14-rc2-1.tar.xz use this repository: https://git.kernel.org/pub/scm/linux/kernel/git/backports/backports.git from tag v4.14-rc2-1 Then run this: ./gentree.py --git-revision v4.14-rc2 --clean <path to linux repo> ../backports-4.14-rc2-1 This also adapts the ath10k-ct and mt76 driver to the changed cfg80211 APIs and syncs the nl80211.h file in iw with the new version from backports-4.14-rc2. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
* mac80211: add dev_coredumpm() functionHauke Mehrtens2017-09-171-0/+156
| | | | | | | | | | | | | | | | dev_coredumpm() was added with kernel 4.7, but it is used by iwlwifi. When the dev coredump framework form compat-wireless is used this is not a problem because it already contains this, but this is deactivated if the build system finds out that it is already included in the kernel we compile against. This option was now activated by the bluetooth driver btmrvl. Having dev coredump in the kernel adds about 400 bytes to the lzma compressed kernel for brcm47xx. This is copied from a more recent backports version to add the dev_coredumpm() function when the internal core devdump is not used. Fixes: a5922f6 ("kernel: bluetooth: add marvell sdio bluetooth module") Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
* ath10k: Re-enable intermediate softqueues for all devicesToke Høiland-Jørgensen2017-09-112-2/+29
| | | | | | | | | | | | The upstream ath10k driver disables the intermediate softqueues for some devices. This patch reverts that behaviour and always enables the softqueues (and associated bufferbloat fixes). We have had reports of people running this with good results: https://lists.bufferbloat.net/pipermail/make-wifi-fast/2017-September/001497.html This also refreshes mac80211 patches. Signed-off-by: Toke Høiland-Jørgensen <toke@toke.dk>
* ath9k: fix regression in multicast buffering fixFelix Fietkau2017-07-251-1/+3
| | | | | | | Update the more data flag on the last frame, but tx from the first frame on. Signed-off-by: Felix Fietkau <nbd@nbd.name>
* ath9k: fix typo in US tx power reduction fixFelix Fietkau2017-07-251-1/+1
| | | | | | Use max_t instead of min_t to prevent the value from going below zero Signed-off-by: Felix Fietkau <nbd@nbd.name>
* ath9k: fix more-data flag for buffered multicast packetsFelix Fietkau2017-07-241-0/+38
| | | | | | | | The flag needs to be cleared for the last packet in the list, not the first one. Fixes some issues with multicast packet loss for powersave clients connected to an ath9k AP. Signed-off-by: Felix Fietkau <nbd@nbd.name>
* ath9k: adjust tx power reduction for US regulatory domainFelix Fietkau2017-07-241-0/+23
| | | | | | | FCC regulatory rules allow for up to 3 dBi antenna gain. Account for this in the EEPROM based tx power reduction code. Signed-off-by: Felix Fietkau <nbd@nbd.name>
* mac80211: refresh patchesFelix Fietkau2017-06-1744-323/+144
| | | | Signed-off-by: Felix Fietkau <nbd@nbd.name>
* ath10k: increase bmi timeout to fix OTP on qca99xx boards and add bmi ↵Pavel Kubelun2017-06-177-11/+196
| | | | | | | | | identification through pre-cal file Backporting upstream patches. Signed-off-by: Pavel Kubelun <be.dissent@gmail.com> Signed-off-by: Felix Fietkau <nbd@nbd.name> [refresh, rename patches]
* mac80211: use KERNEL_MAKEOPTSFelix Fietkau2017-06-071-0/+11
| | | | Signed-off-by: Felix Fietkau <nbd@nbd.name>
* mac80211: rt2x00: remove unneccessary codeDaniel Golle2017-05-181-0/+134
| | | | | | | | Use chanreg and dccal helpers to reduce the size of ePA code. Signed-off-by: Tomislav Požega <pozega.tomislav@gmail.com> Signed-off-by: Daniel Golle <daniel@makrotopia.org> [daniel@makrotopia.org: fixed white-space so patch applies]
* mac80211: Backport AR934x OTP PatchChris Blake2017-04-261-0/+42
| | | | | | | | | Merged upstream in https://patchwork.kernel.org/patch/9572541/, this patch fixes the OTP offset used by the AR934x and AR955X to properly enable reading from the OTP. Signed-off-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Chris Blake <chrisrblake93@gmail.com>
* mac80211: rt2x00: add incomplete support for external PA on MT7620Daniel Golle2017-04-241-0/+125
| | | | | | | | | | | | | | Do as the vendor driver does -- however, some devices apparently patched support for external PA into the driver similar to how it was done on Rt3352, using EEPROM_NIC_CONF1 rather than EEPROM_NIC_CONF2, hence we check for both fields. Somehow the vendor driver also no longer offers the option of only one of the TX paths having an external PA (which was probably to weird to ever be implemented in practise, though it doesn't seem like a particularly bad idea to me). Do the same in rt2x00 and enable support for external PA on both TX paths whenever it is set for TX0 in EEPROM. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* mac80211: rt2x00: reorder patches and prepare for MT7620 external PADaniel Golle2017-04-245-0/+128
| | | | | | | | | Import change to make external PA capability consistent with the vendor driver instead of having the logic inverted. While at it, apply patches in the same order as they got merged upstream. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* mac80211: rt2800: fix mt7620 E2 channel registersTomislav Požega2017-04-181-0/+41
| | | | | | | | update RF register 47 and 54 values according to vendor driver Signed-off-by: Tomislav Požega <pozega.tomislav@gmail.com> Signed-off-by: Daniel Golle <daniel@makrotopia.org> [daniel@makrotopia.org: moved changes into a separate patch]
* mac80211: rt2800: fix mt7620 vco calibration registersTomislav Požega2017-04-181-0/+50
| | | | | | | | | | Use register values from init LNA function instead of the ones from restore LNA function. Apply register values based on rx path configuration. Signed-off-by: Tomislav Požega <pozega.tomislav@gmail.com> Signed-off-by: Daniel Golle <daniel@makrotopia.org> [daniel@makrotopia.org: moved changes into a separate patch]
* mac80211: rt2x00: fix MT7620 LNA gain and VCO-after-ALCDaniel Golle2017-04-172-0/+88
| | | | | | | This should fix issues with bad RX as well as AP not coming up and/or scanning failing. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* ath9k: drop obsolete patchMathias Kresin2017-04-084-43/+4
| | | | | | | Now that the wireless LEDs are added via platform leds this patch isn't required any longer. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ath9k: ignore led_pin if ath9k GPIO controller is used with DTMathias Kresin2017-04-082-6/+8
| | | | | | | | Don't setup the default led pin if the ath9k GPIO controller is used via device tree to prevent collision. In case any of the pins exposed by the ath9k is used, the phyNtpt trigger needs to be set in userspace. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ath9k: enable GPIO chip only if requested via DTMathias Kresin2017-04-082-10/+21
| | | | | | | | In case that the atheros device tree binding is used, enable access to the GPIO chip only if the gpio-controller device tree parameter is used for the ath9k node. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ath9k: unset the default LED pin if used by platform ledsMathias Kresin2017-04-084-31/+27
| | | | | | | | | Unset the default LED gpio pin if the same gpio pin is used by a LED defined via platform LED. This prevents that the default led trigger gets assigned to this LED and the GPIO value gets changed on wifi up/down in case the led is not used for signaling the wifi state. Signed-off-by: Mathias Kresin <dev@kresin.me>
* mac80211: backport an upstream fix for queue start/stop handlingFelix Fietkau2017-04-031-0/+29
| | | | | | Fixes issues with 802.11s Signed-off-by: Felix Fietkau <nbd@nbd.name>
* mac80211: rt2x00: import upstream changes and rebase our patchesDaniel Golle2017-03-3049-189/+1676
| | | | | | | | Some of our local patches have been accepted upstream. And there are some more relevant changes (mostly for rt2800usb). Import them and rebase our remaining local patches on top. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* mac80211: ath10k: allow failure getting board id via otpHannu Nyman2017-03-281-0/+11
| | | | | | | | | | | | | | | ath10k tries to fetch board id via otp, but that fails for many chips like QCA988x, QCA9984 etc. Recent commit cc189c0b7f removed the earlier hack that had allowed QCA radios to work, as that hack was incompatible with the new wifi chips being introduced to the source tree. Restore functionality for the existing wifi chips by modifying the return value of the 'board id via otp' function to a value that is recognised as a harmless error, so that name evaluation continues by using the board file. Patch originally suggested by Christian Lamparter in forum discussion. Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
* ath9k: fix power limits on initFelix Fietkau2017-03-221-0/+47
| | | | | | | | | | | | | | | The tx power applied by set_txpower is limited by the CTL (conformance test limit) entries in the EEPROM. These can change based on the user configured regulatory domain. Depending on the EEPROM data this can cause the tx power to become too limited, if the original regdomain CTLs impose lowr limits than the CTLs of the user configured regdomain. To fix this issue, set the initial channel limits without any CTL restrictions and only apply the CTL at run time when setting the channel and the real tx power. Signed-off-by: Felix Fietkau <nbd@nbd.name>
* ath: do not apply broken power limits with ATH_USER_REGDFelix Fietkau2017-03-223-12/+44
| | | | | | | | | If a device uses the default EEPROM code, typically only the main CTLs are valid, and they do not apply properly when switching to a different regulatory domain. If the regdomain deviates from the EEPROM one, force the world roaming regdomain to ensure that power limits are sane Signed-off-by: Felix Fietkau <nbd@nbd.name>
* mac80211: enable ath10k AHB support for QCA4019Christian Lamparter2017-03-223-51/+49
| | | | | | | | | | | | | | | | This patch enables the ATH10K_AHB support for the QCA4019 devices on the AHB bus. This patch also removes 936-ath10k_skip_otp_check.patch because it breaks the AHB device identification. "Patch is wrong. I find it frustrating OpenWRT/LEDE doesn't try to work with upstream on ixing these things right." [1] <https://www.mail-archive.com/ath10k@lists.infradead.org/msg05896.html> It also limits ath10k memory hunger (This is a problem with 128MiB RAM) Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
* mac80211: brcmfmac: backport patches pushed on 2017-03-20Rafał Miłecki2017-03-2111-5/+756
| | | | Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* rt2x00: mt7620: make fixes requested upstreamDaniel Golle2017-03-111-170/+674
| | | | | | | | Introduce RT6352 instead of matching against RF7620. Clean up channel setting rfvals. Port bandwidth filter calibration. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* rt2x00: mt7620: yet another beauty sessionDaniel Golle2017-03-091-171/+524
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | So here is another round of improvements for MT7620 WiFi. This commit fixes a few significant issues related to TX_PWR_CFG_x and TX_ALC and also makes the code more readable by adding register descriptions for things added for MT7620 and use the usual bit-field access macros and the now defined macros instead of plain bit-ops and magic numbers. Properly describe EEPROM_TARGET_POWER at word 0x68 (== byte 0xD0) and thereby fix internal TXALC which would otherwise just read out-of-bounds of the EEPROM map. Split-out tx-power/ALC related stuff into an additional function. Fix VCO calibration, it was carried out properly in the channel switching but incomplete in the actual VCO calibration function. Also there is no need to trigger VCO calibration in channel switching, the VCO calibration function is already being called at this point. Remove it from channel switching function to avoid redundant code. The TX power calibration differs significantly from all other Mediatek/Ralink chips: They finally allow 0.5dB steps stored as 8-bit values for (almost) each bitrate -- and promptly ran out of space and for some reason didn't want to change the EEPROM layout. The hence opted for a scheme of sharing values for some adjecent bitrates and a highly over-complicated (or obfuscated?) way to populate the TX_PWR_CFG_x registers with the values stored in the EEPROM. The code here now looks much less complicated than what you see in the vendor's driver, however, it does the exact same thing: bGpwrdeltaMinus is a constant and always TRUE, hence half of the code was dead. Gpwrdelta is always 0 (rather than using the value read from the EEPROM). What remains is some very grotesque effort to avoid 0x20, probably some hardware bug related to some misunderstanding of what a singed 8-bit value is (imagine: if it was a signed 6-bit value then someone could believe that 0x20 == 0x0). And then they didn't clean it up once they later on anandonned that whole story of having a constant offset for 40 MHz channels and just set the offset to be constant 0 -- there is no effort for avoiding 0x20 for the 20 MHz values stored in the EEPROM, hence that's probably just a forbidden value in the EEPROM specs and won't appear anyway... Anyway, the whole thing felt like solving some college math test where in the end everything cancels out and the result equals 0 ;) To make sure that channel bandwidth power compensation really doesn't need to be taken care of, output a warning when the corresponding value stored in the EEPROM is non-zero. Also there is no apparent reason to refrain from initializing RFCSR register 13, it doesn't fail what-so-ever. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* mac80211: brcmfmac: always print error when PSM's watchdog firesRafał Miłecki2017-03-012-1/+148
| | | | | | This error is important enough to be displayed even without debugging. Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* mac80211: disable potentially harmful PS software retry for A-MPDU sessionsFelix Fietkau2017-02-231-0/+28
| | | | Signed-off-by: Felix Fietkau <nbd@nbd.name>
* mac80211: rename patch to avoid duplicate numberFelix Fietkau2017-02-221-0/+0
| | | | Signed-off-by: Felix Fietkau <nbd@nbd.name>