Commit Graph
2068 Commits
Author SHA1 Message Date
Felix Fietkau 750797b61b mt76: fix copy&paste error in mt76_testmode_cmd
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-13 09:17:24 +02:00
Dan CarpenterandFelix Fietkau 379445b4aa mt76: mt7915: potential array overflow in mt7915_mcu_tx_rate_report()
Smatch complains that "wcidx" value comes from the network and thus
cannot be trusted.  In this case, it actually seems to come from the
firmware.  If your wireless firmware is malicious then probably no
amount of carefulness can protect you.

On the other hand, these days we still try to check the firmware as much
as possible.  Verifying that the index is within bounds will silence a
static checker warning.  And it's harmless and a good exercise in kernel
hardening.  So I suggest that we do add a bounds check.

Fixes: e57b7901469f ("mt76: add mac80211 driver for MT7915 PCIe-based chipsets")
Signed-off-by: Dan Carpenter <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-11 18:17:14 +02:00
Sean WangandFelix Fietkau 4c9309f47d mt76: mt7615: fix potential memory leak in mcu message handler
Fix potential memory leak in mcu message handler on error condition.

Fixes: 0e6a29e477f3 ("mt76: mt7615: add support to read temperature from mcu")
Acked-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Sean Wang <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:30 +02:00
Sean WangandFelix Fietkau afff00ad2b mt76: mt7663u: fix potential memory leak in mcu message handler
Fix potential memory leak in mcu message handler on error condition.

Fixes: eb99cc95c3b6 ("mt76: mt7615: introduce mt7663u support")
Acked-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Sean Wang <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:30 +02:00
Sean WangandFelix Fietkau 1f670a5344 mt76: mt7663u: fix memory leak in set key
Fix memory leak in set key.

Fixes: eb99cc95c3b6 ("mt76: mt7615: introduce mt7663u support")
Signed-off-by: Sean Wang <[email protected]>
Acked-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:30 +02:00
Lorenzo BianconiandFelix Fietkau f1ff52acb6 mt76: mt7615: reschedule ps work according to last activity
Reschedule runtime-pm delayed work if there is a new activity when ps
delayed work is already scheduled

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:30 +02:00
Lorenzo BianconiandFelix Fietkau b469c59c61 mt76: mt7615: avoid scheduling runtime-pm during hw scan
Do not schedule ps_work during hw scanning or hw scheduled frequency
scan

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:30 +02:00
Lorenzo BianconiandFelix Fietkau a873b7c8e3 mt76: mt7663u: sync probe sampling with rate configuration
On usb device rate configuration for sampling is performed relying on a
workqueue since it is not possible to access the device in the interrupt
context. Move the configuration of the probe_rate flag in the workqueue
in order to keep probe sampling in sync with actual rate configuration

Fixes: eb99cc95c3b6 ("mt76: mt7615: introduce mt7663u support")
Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:30 +02:00
Lorenzo BianconiandFelix Fietkau 58057d1f23 mt76: mt7615: improve mt7615_driver_own reliability
mt7615_driver_own can fail if it runs too close to mt7615_fw_own. In
order to improve mt7615_driver_own reliability, retry to get runtime-pm
ownership if mt7615_driver_own fails

Co-developed-by: Sean Wang <[email protected]>
Signed-off-by: Sean Wang <[email protected]>
Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:30 +02:00
Lorenzo BianconiandFelix Fietkau 29f2bebe1a mt76: mt7615: add idle-timeout knob in mt7615 debugfs
Introduce idle-timeout knob in mt7615 debugfs in order to configure the
idle time to switch to low-power state

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:30 +02:00
Lorenzo BianconiandFelix Fietkau ccc90dafea mt76: mt7615: enable beacon hw filter for runtime-pm
In order to reduce number of received interrupts and power consumption,
enable hw beacon filter if runtime-pm is enabled

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:30 +02:00
Lorenzo BianconiandFelix Fietkau 94519eac69 mt76: mt7615: add runtime-pm knob in mt7615 debugfs
Introduce runtime-pm knob in mt7615 debugfs in order to enable/disable
runtime pm available in offload firmware

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:30 +02:00
Lorenzo BianconiandFelix Fietkau 28a2f5fa6e mt76: mt7615: do not request {driver,fw}_own if already granted
Check MT76_STATE_PM in mt7615_driver_own/mt7615_firmware_own
in order to not requested power ownership if it is already granted

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:29 +02:00
Lorenzo BianconiandFelix Fietkau 2107caf92e mt76: mt7615: check MT76_STATE_PM flag before accessing the device
Double-check if the device is in low-power state before accessing
registermap in mt7615_sta_rate_tbl_update() and in
mt7615_led_set_config()

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:29 +02:00
Lorenzo BianconiandFelix Fietkau 65ccc40c14 mt76: mt7615: run mt7615_pm_wake in mt7615_mac_sta_{add,remove}
Run mt7615_pm_wake()/mt7615_pm_power_save_sched() directly in order to
wake the device from low power state in mt7615_mac_sta_{add,remove}
since they run holding mt76 mutex in common mt76 code

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:29 +02:00
Lorenzo BianconiandFelix Fietkau 82e8e0525d mt76: mt7615: wake device before pushing frames in mt7615_tx
Queue frames pushed by mac80211 running mt7615_tx if the device is
low-power state. Run wake workqueue in order to swicth to full-power
before transmitting pending frames

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:29 +02:00
Lorenzo BianconiandFelix Fietkau b8cdce45c1 mt76: mt7615: wake device before pulling packets from mac80211 queues
Make sure the device is in full-power before pulling frames from
mac80211 queues

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:29 +02:00
Lorenzo BianconiandFelix Fietkau 36a789c00e mt76: mt7615: run mt7615_mcu_set_roc holding mt76 mutex
Make sure to run mt7615_mcu_set_roc() holding mt76 mutex in order to
wake the device from low power state and avoid races

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:29 +02:00
Lorenzo BianconiandFelix Fietkau 6fdb20a025 mt76: mt7615: run mt7615_mcu_set_wmm holding mt76 mutex
Make sure to run mt7615_mcu_set_wmm() holding mt76 mutex in order to
wake the device from low power state and avoid races

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:29 +02:00
Lorenzo BianconiandFelix Fietkau 2c188db1f7 mt76: mt7615: add missing lock in mt7615_regd_notifier
Make sure to run mt7615_dfs_init_radar_detector in mt7615_regd_notifier
holding mt76 mutex in order to avoid races and set the device in full
power

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:29 +02:00
Lorenzo BianconiandFelix Fietkau 58369fdce2 mt76: mt7615: wake device before performing freq scan
Set device in full power before performing hw scan or hw scheduled scan

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:29 +02:00
Lorenzo BianconiandFelix Fietkau b0bcdd66cc mt76: mt7615: acquire driver_own before configuring device for suspend
Make sure to wake the device in mt7615_pci_suspend in order to properly
configure device registers before suspend

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:29 +02:00
Lorenzo BianconiandFelix Fietkau 56779a6c7d mt76: mt7615: wake device in mt7615_update_channel before access regmap
Introduce mt7615_update_survey utility routine in order to compute
survey stats without waking up the device since it runs holding mt76 lock.
Run mt7615_pm_wake directly in mt7615_update_channel since it can run
with mt76.mutex held if called by mac80211

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:29 +02:00
Lorenzo BianconiandFelix Fietkau 050f8cd9cb mt76: mt7615: introduce pm_power_save delayed work
Introduce runtime-pm power_save delayed work used to enable
low-power after an inactivity period

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:29 +02:00
Lorenzo BianconiandFelix Fietkau e6dcb71d79 mt76: mt7615: wake device before configuring hw keys
Make sure the device is in full-power before uploading keys to the hw

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:29 +02:00
Lorenzo BianconiandFelix Fietkau e3850966d7 mt76: mt7615: wake device before accessing regmap in debugfs
Make sure the device is in full-power before reading regs in debugfs

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:29 +02:00
Lorenzo BianconiandFelix Fietkau 091e9b5df6 mt76: mt7615: introduce mt7615_mutex_{acquire,release} utilities
Introduce mt7615_mutex_{acquire,release} utility routines in order to
switch in full-power/low-power before/after accessing device register-map

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:29 +02:00
Lorenzo BianconiandFelix Fietkau 0bf8227056 mt76: mt7615: add mt7615_pm_wake utility routine
Introduce mt7615_pm_wake utility routine to wake the device from
runtime low-power state (lower-power state is currently supported by
offload firmware for pcie devices).

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:10 +02:00
Lorenzo BianconiandFelix Fietkau ec303bfad2 mt76: move mt76 workqueue in common code
Move mt76 workqueue from usb to common code in order to be reused adding
low-power support for mt7663 chipset

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:10 +02:00
Lorenzo BianconiandFelix Fietkau dad3f93e8f mt76: mt7615: avoid polling in fw_own for mt7663
According to the vendor sdk, mt7663 does not need to poll register after
firmware own. Since just mt7622 polls status register, set proper
timeout value according to the vendor sdk

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:10 +02:00
Ryder LeeandFelix Fietkau ca2b797ee5 mt76: mt7915: avoid memcpy in rxv operation
Avoid memcpy in Rx hot path to slightly improve performance.

Signed-off-by: Ryder Lee <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:10 +02:00
Lorenzo BianconiandFelix Fietkau c605f2b694 mt76: mt76x2u: enable HC-M7662BU1
Enable support for HC-M7662BU1 module on mt76x2u driver

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:10 +02:00
Lorenzo BianconiandFelix Fietkau 3f0e66dc25 mt76: mt76x2: fix pci suspend/resume on mt7612e
Fix the following mt7612e hw hangs during suspend/resume reported on
Dell Vostro 3360

mt76x2e 0000:01:00.0: MCU message 2 (seq 11) timed out
mt76x2e 0000:01:00.0: MCU message 30 (seq 12) timed out
mt76x2e 0000:01:00.0: MCU message 30 (seq 13) timed out
mt76x2e 0000:01:00.0: Firmware Version: 0.0.00
mt76x2e 0000:01:00.0: Build: 1
mt76x2e 0000:01:00.0: Build Time: 201507311614____
mt76x2e 0000:01:00.0: Firmware running!
ieee80211 phy0: Hardware restart was requested
mt76x2e 0000:01:00.0: MCU message 2 (seq 1) timed out
mt76x2e 0000:01:00.0: MCU message 30 (seq 2) timed out
mt76x2e 0000:01:00.0: MCU message 30 (seq 3) timed out
mt76x2e 0000:01:00.0: Firmware Version: 0.0.00
mt76x2e 0000:01:00.0: Build: 1
mt76x2e 0000:01:00.0: Build Time: 201507311614____
mt76x2e 0000:01:00.0: Firmware running!
ieee80211 phy0: Hardware restart was requested
mt76x2e 0000:01:00.0: MCU message 31 (seq 5) timed out
mt76x2e 0000:01:00.0: MCU message 31 (seq 6) timed out
mt76x2e 0000:01:00.0: MCU message 31 (seq 7) timed out
mt76x2e 0000:01:00.0: MCU message 31 (seq 8) timed out
mt76x2e 0000:01:00.0: MCU message 31 (seq 9) timed out
mt76x2e 0000:01:00.0: MCU message 31 (seq 10) timed out
mt76x2e 0000:01:00.0: MCU message 31 (seq 11) timed out
mt76x2e 0000:01:00.0: Firmware Version: 0.0.00
mt76x2e 0000:01:00.0: Build: 1
mt76x2e 0000:01:00.0: Build Time: 201507311614____
mt76x2e 0000:01:00.0: Firmware running!
ieee80211 phy0: Hardware restart was requested
------------[ cut here ]-----------
CPU: 3 PID: 11956 Comm: kworker/3:1 Not tainted 5.7.0-pf2 #1
Hardware name: Dell Inc.          Vostro 3360/0F5DWF, BIOS A18 09/25/2013
Workqueue: events_freezable ieee80211_restart_work [mac80211]
RIP: 0010:ieee80211_reconfig+0x234/0x1700 [mac80211]
RSP: 0018:ffffb803c23ffdf0 EFLAGS: 00010286
RAX: 00000000fffffff0 RBX: ffff9595a7564900 RCX: 0000000000000008
RDX: 0000000000000000 RSI: 0000000000000100 RDI: 0000000000000100
RBP: ffff9595a7ec07e0 R08: 0000000000000000 R09: 0000000000000001
R10: 0000000000000001 R11: 0000000000000000 R12: ffff9595a7ec18d0
R13: 00000000ffffffff R14: 0000000000000000 R15: 00000000fffffff0
FS:  0000000000000000(0000) GS:ffff9595af2c0000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000055e56d7de000 CR3: 000000042200a001 CR4: 00000000001706e0
Call Trace:
 ieee80211_restart_work+0xb7/0xe0 [mac80211]
 process_one_work+0x1d4/0x3c0
 worker_thread+0x228/0x470
 ? process_one_work+0x3c0/0x3c0
 kthread+0x19c/0x1c0
 ? __kthread_init_worker+0x30/0x30
 ret_from_fork+0x35/0x40
wlp1s0:  Failed check-sdata-in-driver check, flags: 0x0
CPU: 3 PID: 11956 Comm: kworker/3:1 Tainted: G        W         5.7.0-pf2 #1
Hardware name: Dell Inc.          Vostro 3360/0F5DWF, BIOS A18 09/25/2013
Workqueue: events_freezable ieee80211_restart_work [mac80211]
RIP: 0010:drv_remove_interface+0x11f/0x130 [mac80211]
RSP: 0018:ffffb803c23ffc80 EFLAGS: 00010282
RAX: 0000000000000000 RBX: ffff9595a7564900 RCX: 0000000000000000
RDX: 0000000000000001 RSI: 0000000000000082 RDI: 00000000ffffffff
RBP: ffff9595a7ec1930 R08: 00000000000004b6 R09: 0000000000000001
R10: 0000000000000001 R11: 0000000000006f08 R12: ffff9595a7ec1000
R13: ffff9595a75654b8 R14: ffff9595a7ec0ca0 R15: ffff9595a7ec07e0
FS:  0000000000000000(0000) GS:ffff9595af2c0000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000055e56d7de000 CR3: 000000042200a001 CR4: 00000000001706e0
Call Trace:
 ieee80211_do_stop+0x5af/0x8c0 [mac80211]
 ieee80211_stop+0x16/0x20 [mac80211]
 __dev_close_many+0xaa/0x120
 dev_close_many+0xa1/0x2b0
 dev_close+0x6d/0x90
 cfg80211_shutdown_all_interfaces+0x71/0xd0 [cfg80211]
 ieee80211_reconfig+0xa2/0x1700 [mac80211]
 ieee80211_restart_work+0xb7/0xe0 [mac80211]
 process_one_work+0x1d4/0x3c0
 worker_thread+0x228/0x470
 ? process_one_work+0x3c0/0x3c0
 kthread+0x19c/0x1c0
 ? __kthread_init_worker+0x30/0x30
 ret_from_fork+0x35/0x40

Fixes: 7bc04215a66b ("mt76: add driver code for MT76x2e")
Tested-by: Oleksandr Natalenko <[email protected]>
Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:10 +02:00
Ryder LeeandFelix Fietkau 13ab1d6486 mt76: mt7915: update HE capabilities
Sync from SDK to update HE capabilities.

Signed-off-by: Ryder Lee <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:10 +02:00
Shayne ChenandFelix Fietkau 7941217ffe mt76: mt7915: remove unused parameters in mt7915_puts_rate_txpower()
Simplify and remove unused parameters in mt7915_puts_rate_txpower()
function.

Signed-off-by: Shayne Chen <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-10 14:45:10 +02:00
Felix Fietkau 6789a2db72 mt7615: fix getting wideband RSSI in test mode
Signed-off-by: Felix Fietkau <[email protected]>
2020-07-09 22:06:43 +02:00
Felix Fietkau 3ea5da1639 add utility for using testmode support
Signed-off-by: Felix Fietkau <[email protected]>
2020-06-22 21:32:26 +02:00
Felix Fietkau d7467bc018 mt76: mt7615: implement testmode support
Supports sending a configurable number of packets with a specific rate
and configurable tx power levels / antenna settings, as well as displaying
rx statistics.

Signed-off-by: Felix Fietkau <[email protected]>
2020-06-22 21:32:02 +02:00
Felix Fietkau 3a1ea7287e mt76: add API for testmode support
This can be used for calibration in the manufacturing process.
It supports sending a configurable number of packets with a specific rate
and configurable tx power levels / antenna settings.
It also supports receiving packets and showing some statistics, including
packet counters and detailed RSSI information.
It will only be compiled in if CONFIG_NL80211_TESTMODE is enabled

Signed-off-by: Felix Fietkau <[email protected]>
2020-06-22 21:31:02 +02:00
Felix Fietkau b1ddb8e35c mt76: vif_mask to struct mt76_phy
All drivers use this in pretty much the same way. Moving it to core helps with
some checks for the upcoming testmode support

Signed-off-by: Felix Fietkau <[email protected]>
2020-06-22 21:28:35 +02:00
Felix Fietkau 882cec4206 mt76: mt7615: use full on-chip memory address for WF_PHY registers
Now that the bus access functions can use mapping for accessing full
register addresses, use it for WF_PHY registers to keep them constant.
Needed for follow-up work on testmode support

Signed-off-by: Felix Fietkau <[email protected]>
2020-06-22 21:28:35 +02:00
Felix Fietkau 46bc8a0b53 mt76: mt7615: add support for accessing RF registers via MCU
Includes debugfs files for testing it.
Will be used for testmode support.

Signed-off-by: Felix Fietkau <[email protected]>
2020-06-22 21:28:35 +02:00
Felix Fietkau 72f3410724 mt76: mt7615: add support for accessing mapped registers via bus ops
Makes it possible to read/write them via debugfs, similar to mt7603

Signed-off-by: Felix Fietkau <[email protected]>
2020-06-22 21:28:35 +02:00
Felix Fietkau b5eee1b522 mt76: mt7615: schedule tx tasklet and sta poll on mac tx free
Unlike on earlier chips, DMA completion on MT7615 does not imply actually
having sent out any packets.
Since AQL will prevent filling the hardware queues and will only allow more
packets to be passed to the driver after tx completion, it makes much more
sense to schedule the tx tasklet there.
This is also needed for scheduling tx in testmode support

Signed-off-by: Felix Fietkau <[email protected]>
2020-06-22 21:28:35 +02:00
Lorenzo BianconiandFelix Fietkau 740b0bfdf2 mt76: mt76x2e: rename routines in pci.c
Rely on mt76x2e prefix in mt76x2/pci.c and align to the rest of
mt76 code

Signed-off-by: Lorenzo Bianconi <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-06-22 21:28:21 +02:00
Ryder LeeandFelix Fietkau 8ae83adc73 mt76: mt7915: overwrite qid for non-bufferable mgmt frames
Overwrite hw queue id for non-bufferable management frames if the hw/fw
support always txq (altxq) in order to be in sync with mac txwi code

Signed-off-by: Ryder Lee <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-06-22 21:26:16 +02:00
Shayne ChenandFelix Fietkau c6ea163c01 mt76: mt7915: directly read per-rate tx power from registers
Since driver no longer handler per-rate tx power setting, we need to
read the power values directly from registers.

Tested-by: Evelyn Tsai <[email protected]>
Signed-off-by: Shayne Chen <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-06-22 21:26:16 +02:00
Shayne ChenandFelix Fietkau b3a4d78914 mt76: mt7915: rework the flow of txpower setting
Clean up the flow of per-rate txpower limit setting to get rid of
dulplicate work since it has already been handled by firmware, and set
proper max_power based on different channels and regdomains.

Signed-off-by: Shayne Chen <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-06-22 21:26:16 +02:00
Shayne ChenandFelix Fietkau 53891242a6 mt76: mt7915: add support for DT rate power limits
Enable to limit per-rate max txpower from DT.

Tested-by: Evelyn Tsai <[email protected]>
Signed-off-by: Shayne Chen <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-06-22 21:26:16 +02:00
Ryder LeeandFelix Fietkau 1ce4660a0e mt76: mt7915: use ieee80211_tx_queue_params to avoid open coded
This is easy to add MU EDCA parameters in the future. This patch
also fixes a wrong cw_min assignment.

Signed-off-by: Ryder Lee <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
2020-06-22 21:26:16 +02:00