Felix Fietkau
170f3341c6
mt76x2: remove MAC address limitation for multi-vif setups
...
The hardware has a separate set of registers to configure a
per-interface MAC address.
Signed-off-by: Lorenzo Bianconi <[email protected] >
Signed-off-by: Felix Fietkau <[email protected] >
2017-12-07 19:50:46 +01:00
Felix Fietkau
4d4cd05966
Partially revert "mt7603: use mcu command to set timing registers, fix OFDM timeout values"
...
This reverts commit 268467b9a4 .
It is unnecessary to go through the MCU for this.
Signed-off-by: Felix Fietkau <[email protected] >
2017-12-07 17:09:28 +01:00
Felix Fietkau
d02a05b0b3
mt7603: update firmware to version 20160107100755
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-12-03 22:30:14 +01:00
Felix Fietkau
8e17d36381
mt7603: remove some harmless WARN_ONs in rx path
...
Discard affected packets instead. Should reduce the frequency of bogus
bug reports
Signed-off-by: Felix Fietkau <[email protected] >
2017-12-03 18:15:05 +01:00
Felix Fietkau
b4034cf325
mt76x2: remove some harmless WARN_ONs in tx status and rx path
...
Discard affected packets instead. Should reduce the frequency of bogus
bug reports
Signed-off-by: Felix Fietkau <[email protected] >
2017-12-03 18:14:12 +01:00
Felix Fietkau
c8e5ab19ea
mt7603: initialize wtbl ps flag on station add
...
Ensure that the firmware hasn't changed anything
Signed-off-by: Felix Fietkau <[email protected] >
2017-12-03 17:32:34 +01:00
Felix Fietkau
57a2e334ec
mt7603: set tx-skip flag for powersave clients
...
Helps flush out frames faster
Signed-off-by: Felix Fietkau <[email protected] >
2017-12-03 17:32:34 +01:00
Felix Fietkau
e953c78806
mt7603: clear wtbl PS bit for powersave responses
...
Avoids filtering frames that are supposed to be sent
Signed-off-by: Felix Fietkau <[email protected] >
2017-12-03 16:49:02 +01:00
Felix Fietkau
96817d63ea
mt7603: make mt7603_mac_watchdog_reset() static
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-12-03 16:49:02 +01:00
Felix Fietkau
c079960b59
mt7603: clean up dma debug reads
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-12-02 11:11:58 +01:00
Felix Fietkau
d8a59901ec
mt7603: warn if PSE reset fails
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-12-02 10:50:08 +01:00
Felix Fietkau
c8807b4a3c
mt7603: simplify PSE reset
...
Skip PSE client reset, it is done by the firmware already
Signed-off-by: Felix Fietkau <[email protected] >
2017-12-02 10:49:14 +01:00
Felix Fietkau
d99092baab
mt7603: remove WARN_ON_ONCE for workaround checks
...
It can happen during normal operation and it confuses users more than it
actually helps. workaround trigger counts are still available via
debugfs
Signed-off-by: Felix Fietkau <[email protected] >
2017-12-02 10:43:39 +01:00
Felix Fietkau
c4dd32abb5
mt7603: remove watchdog reset on interface stop
...
It can be harmful in some cases
Signed-off-by: Felix Fietkau <[email protected] >
2017-12-01 17:51:44 +01:00
Felix Fietkau
8026638543
mt7603: rename MT_PSE_RESET register
...
It is actually a dummy control register used for communicating reset
state with the MCU firmware
Signed-off-by: Felix Fietkau <[email protected] >
2017-12-01 17:50:59 +01:00
Felix Fietkau
737cf2b6f7
mt7603: rename mt7603_mac_reset to mt7603_pse_reset
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-12-01 17:38:39 +01:00
Felix Fietkau
19fff41338
mt76x2: convert between per-chain tx power and combined output
...
Using both chains adds max. 3 dBm.
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-30 12:59:31 +01:00
Felix Fietkau
3bd7e76e2d
mt76x2: initialize channel power limits
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-30 12:33:47 +01:00
Felix Fietkau
11f42a8aab
mt76x2: add channel argument to eeprom tx power functions
...
Preparation for exposing maximum power to mac80211
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-30 12:16:39 +01:00
Felix Fietkau
a51358e3ae
mt76x2: increase OFDM SIFS time
...
Fixes throughput issues in combination with LDPC
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-29 13:14:45 +01:00
Felix Fietkau
792859b237
mt76x2: fix transmission of encrypted management frames
...
Hardware encryption seems to break encrypted unicast mgmt tx.
Unfortunately the hardware TXWI header does not have a bit to indicate
that a frame is software encrypted, so sw-encrypted frames need to use a
different WCID. For that to work, the CCMP PN needs to be generated in
software, which makes things a bit slower, so only do it for keys that
also need to tx management frames.
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-29 12:18:34 +01:00
Felix Fietkau
a4c82cad00
mt7603: add missing include required on newer kernels
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-29 10:07:24 +01:00
Felix Fietkau
fc28872399
mac80211: add missing include
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-21 09:48:19 +01:00
Felix Fietkau
8f1c8abdf7
mt76x2: sync tx power related values with reference driver
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-16 19:48:52 +01:00
Felix Fietkau
70f2002651
mt76x2: add more gain tuning based on the latest reference driver
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-16 19:25:33 +01:00
Felix Fietkau
4af37bd999
mt76x2: implement dynamic AGC tuning based on false packet detection count
...
Significantly improves radio performance
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-16 19:12:01 +01:00
Felix Fietkau
efd7724b1a
mt76x2: sync channel gain value with latest reference driver
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-16 18:31:06 +01:00
Felix Fietkau
af425def8c
mt76x2: fix LNA gain register annotation
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-16 18:09:43 +01:00
Felix Fietkau
b57ada5d54
mt76x2: add rx statistics registers
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-16 17:47:18 +01:00
Felix Fietkau
ff60d1482c
mt76: increase rx ring size for mt76x2
...
Should improve performance under load
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-16 16:26:45 +01:00
Felix Fietkau
ccc4baf446
mt76x2: clear drop mask when sending a PS response
...
Should make handling powersave clients more reliable
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-16 14:14:08 +01:00
Felix Fietkau
0ce792337d
mt76x2: add helper function for setting drop mask
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-16 14:07:03 +01:00
Felix Fietkau
d8140b6f40
mt76x2: clear per-WCID tx rate lookup register
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-15 18:07:39 +01:00
Felix Fietkau
60172cc63c
mt76x2: clear drop flag for all WCIDs on init
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-15 18:00:10 +01:00
Felix Fietkau
e4e773440a
mt76x2: limit client WCID entries to 0-127
...
The rx WCID lookup table and the per-WCID rate table only have 128
entries. All further WCID entries are tx-only.
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-15 17:59:48 +01:00
Felix Fietkau
cc02e495cd
mac80211: move DT led configuration to the "led" child node
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-07 12:42:18 +01:00
Felix Fietkau
fbdbf656ce
debugfs: add support for changing the LED pin
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-07 12:18:56 +01:00
Felix Fietkau
51a67644b8
mt7603: remove unnecessary mcu register read function
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-11-01 09:11:03 +01:00
Kristian Evensen and Felix Fietkau
ded88cd552
mt76x2: Add PCI identifier for MT7602
...
MT7602 is also available as a PCI card, so add the missing identifier.
Signed-off-by: Kristian Evensen <[email protected] >
2017-11-01 09:10:00 +01:00
Lorenzo Bianconi and Felix Fietkau
8ea8da3a23
mt7603: init: add ma80211 led callbacks
...
Signed-off-by: Lorenzo Bianconi <[email protected] >
2017-10-31 10:22:21 +01:00
Lorenzo Bianconi and Felix Fietkau
58e9138323
mt76x2: init: add ma80211 led callbacks
...
Signed-off-by: Lorenzo Bianconi <[email protected] >
2017-10-31 10:22:15 +01:00
Lorenzo Bianconi and Felix Fietkau
c9bdcd850d
mt76: add led support using mac80211 led framework
...
use tpt-trigger as default trigger
Signed-off-by: Lorenzo Bianconi <[email protected] >
Signed-off-by: Felix Fietkau <[email protected] >
2017-10-31 10:21:14 +01:00
Kristian Evensen and Felix Fietkau
f6a021d15a
mt76x2: Support using PCI ID as chip ID
...
On some routers, the manufacturer has made a mistake and left the chip
ID part of the EEPROM empty (it is set to 0x0000). One such router is
the ZBT-WE1026-5G (equipped with MT7612), and the consequence is that
the EEPROM check fails and the 5GHz wifi does not work at all. When
setting the chip ID to 0x7612 manually, the 5GHz wifi works fine.
When looking at EEPROM of the WE1026 (and other devices equipped with
mt76x2), I see that the PCI ID is always set to a valid value (7612 or
7662). This PR works around the issue of an empty chip ID by using the
PCI ID, if chip ID is 0. After applying this PR/patch manually to mt76,
the 5GHz on the WE1026 works out of the box. Since the PCI ID is only
used if chip ID is empty, devices with correct EEPROMs are not affected.
Signed-off-by: Kristian Evensen <[email protected] >
2017-10-27 12:26:33 +02:00
Felix Fietkau
f658dd21d7
mt76x2: add LED register definitions
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-10-27 12:15:53 +02:00
Felix Fietkau
a6fce8a34c
mt7603: add LED definition registers
...
Signed-off-by: Felix Fietkau <[email protected] >
2017-10-27 12:15:53 +02:00
Rosen Penev and Felix Fietkau
e7647871da
Fix errors found by cppcheck
...
Mismatching declarations as well as unused results.
Signed-off-by: Rosen Penev <[email protected] >
2017-10-27 12:15:53 +02:00
Lorenzo Bianconi and Felix Fietkau
758376dea6
mt7603: mcu: remove unused parameter in mt7603_mcu_msg_alloc() signature
...
Signed-off-by: Lorenzo Bianconi <[email protected] >
2017-10-27 12:15:53 +02:00
Lorenzo Bianconi and Felix Fietkau
266ef38ca8
mt76x2: mcu: remove unused parameter in mt76x2_mcu_msg_alloc signature
...
Signed-off-by: Lorenzo Bianconi <[email protected] >
2017-10-27 09:50:07 +02:00
Felix Fietkau
37654d7047
mt76x2: fix tx status ampdu length corner case
...
Sometimes the code would return a status update to mac80211 with a-mpdu
length of 0, leading to a crash in minstrel.
Make the logic of counting a-mpdu burst length easier to follow and add
an extra check to prevent this issue from happening.
Signed-off-by: Felix Fietkau <[email protected] >
2017-10-12 12:24:12 +02:00
Felix Fietkau
e78156982f
update to latest mac80211/cfg80211 API changes
...
Signed-off-by: Hauke Mehrtens <[email protected] >
Signed-off-by: Felix Fietkau <[email protected] >
2017-10-05 20:50:48 +02:00