Hi Kalle, Here's another large batch of mt76 code cleanup / deduplication / fixes - Felix The following changes since commit 93ed990e3a6e722b7b1e1d59b3ceb8d91e36e682: qtnfmac: remove set but not used variable 'vif' (2018-09-20 15:12:13 +0300) are available in the Git repository at: https://github.com/nbd168/wireless tags/mt76-for-kvalo-2018-10-01 for you to fetch changes up to 5289976ad887deb07c76df7eecf553c264aeebed: mt76: mt76x2: fix multi-interface beacon configuration (2018-10-01 13:26:21 +0200) ---------------------------------------------------------------- mt76 patches for 4.20 * unify code between mt76x0, mt76x2 * mt76x0 fixes * tx power configuration fix for 76x2 * more progress on mt76x0e support * support for getting firmware version via ethtool * fix for rx buffer allocation regression on usb * fix for handling powersave responses * fix for mt76x2 beacon transmission ---------------------------------------------------------------- Davide Caratti (1): mt76: report firmware version using ethtool Felix Fietkau (6): mt76: add stbc entries to mt76_rate_power mt76: include linux/module.h in files using MODULE_* mt76x2: disable WLAN core before probe mt76: fix handling ps-poll frames mt76: check aggregation sequence number for frames sent via drv_tx mt76: mt76x2: fix multi-interface beacon configuration Hauke Mehrtens (1): mt76: use skb_pad() instead of __skb_pad() Lorenzo Bianconi (54): mt76x2: fix tx power configuration for VHT mcs 9 mt76x0: pci: add mt7650 PCI ID mt76x0: pci: add fw uploading routine mt76: move seq_put_array in mt76-core module mt76: move common eeprom definitions in mt76x02-lib module mt76: move eeprom utility routines in mt76x02_eeprom.h mt76: move mt76x2_eeprom_get in mt76x02_eeprom.h mt76: move mt76x02_mac_setaddr in mt76x02-lib module mt76: move mt76x2_get_efuse_data in mt76x02-lib module mt76: move mt76x2_ext_pa_enabled routine in mt76x02_eeprom.c mt76x0: remove mt76x0_set_country_reg routine mt76: add mt76x02_get_rx_gain and mt76x02_get_lna_gain utility routines mt76x0: unify lna_gain parsing mt76x0: unify rssi_offset parsing mt76x0: unify temperature offset parsing mt76x0: unify freq offset parsing mt76: move mt76x02_eeprom_parse_hw_cap in mt76x02-lib module mt76x0: unify parse hw capabilities mt76: move mt76x2_tssi_enabled in mt76x02_eeprom.h mt76: usb: remove WARN_ON in mt76u_get_rx_entry_len mt76: move mt76_rate_power in mt76_dev mt76: add mt76x02_phy_set_txpower utility routine mt76: move rate_txpower handler in mt76 debugfs mt76: move mt76x02_rate_power_val in mt76x02-lib module mt76x0: remove mt76x0_phy_set_tx_power and mt76x0_extra_power_over_mac mt76x0: remove eeprom dependency from mt76x0_set_tx_power_per_rate mt76x0: remove eeprom dependency from mt76x0_get_power_info mt76x0: use shared debugfs implementation mt76x0: phy: introduce mt76x0_phy_set_txpower routine mt76: usb: make rx page_frag_cache access atomic mt76x0: use mt76_poll in mt76x0_set_wlan_state mt76: move wait_for_wpdma in mt76x02_dma.h mt76: add mt76x02_dma_enable/mt76x02_dma_disable utility routines mt76: move mt76x02_set_irq_mask in mt76x02_mmio.c mt76: move queue initialization in mt76x02_mmio.c mt76: move mt76x02_beacon_offset in mt76x02_util.c mt76: mmio: add implementation of wr_rp and rd_rp mt76: move mt76x2_wait_for_bbp in mt76x02-lib module mt76x0: update initvals to latest version of vendor driver mt76x0: pci: move mcu code in pci_mcu.c mt76x0: usb: move mcu code in usb_mcu.c mt76x0: use mt76x02 utility routines in mt76x0 init code mt76x0: init: remove duplicated initialization mt76x0: init: remove MT_PBF_SYS_CTRL configuration in mt76x0_reset_csr_bbp mt76x0: init rx filter in mt76x0_init_hardware mt76: add mt76x02_mac_start routine mt76x0: usb: move initialization code in usb.c mt76x0: pci: add hw initialization at bootstrap mt76x0: phy: set antenna parameter according to wireless band mt76: move set_{tx,rx}_path routines in mt76x02-lib module mt76x0: add ieee80211_ops ops pointer to mt76x0_alloc_device signature mt76x0: pci: add mt76x0e_{start/stop} callbacks mt76x0: eeprom: load eeprom data from mtd by default mt76x0: usb: move mt76x0u_tx_prepare_skb in usb.c Stanislaw Gruszka (2): mt76: fix return value of mt76x02_wait_for_mac mt76x0: add quirk to disable 2.4GHz band for Archer T1U drivers/net/wireless/mediatek/mt76/Makefile | 3 +- drivers/net/wireless/mediatek/mt76/debugfs.c | 31 ++++++ drivers/net/wireless/mediatek/mt76/mac80211.c | 6 + drivers/net/wireless/mediatek/mt76/mmio.c | 27 +++++ drivers/net/wireless/mediatek/mt76/mt76.h | 39 ++++--- drivers/net/wireless/mediatek/mt76/mt76x0/Makefile | 4 +- drivers/net/wireless/mediatek/mt76/mt76x0/debugfs.c | 81 +------------- drivers/net/wireless/mediatek/mt76/mt76x0/eeprom.c | 566 +++++++++++++++++++++++++++++++++++++++------------------------------------------------------- drivers/net/wireless/mediatek/mt76/mt76x0/eeprom.h | 132 +++------------------- drivers/net/wireless/mediatek/mt76/mt76x0/init.c | 191 +++++--------------------------- drivers/net/wireless/mediatek/mt76/mt76x0/initvals.h | 405 ++++++++++++++++++++++++++++++------------------------------------- drivers/net/wireless/mediatek/mt76/mt76x0/main.c | 98 +++++------------ drivers/net/wireless/mediatek/mt76/mt76x0/mcu.h | 7 ++ drivers/net/wireless/mediatek/mt76/mt76x0/mt76x0.h | 36 +++--- drivers/net/wireless/mediatek/mt76/mt76x0/pci.c | 111 ++++++++++++++++++- drivers/net/wireless/mediatek/mt76/mt76x0/pci_mcu.c | 146 ++++++++++++++++++++++++ drivers/net/wireless/mediatek/mt76/mt76x0/phy.c | 176 +++++++---------------------- drivers/net/wireless/mediatek/mt76/mt76x0/tx.c | 24 +--- drivers/net/wireless/mediatek/mt76/mt76x0/usb.c | 306 ++++++++++++++++++++++++++------------------------- drivers/net/wireless/mediatek/mt76/mt76x0/usb_mcu.c | 176 +++++++++++++++++++++++++++++ drivers/net/wireless/mediatek/mt76/mt76x02_dma.h | 17 +++ drivers/net/wireless/mediatek/mt76/mt76x02_eeprom.c | 156 ++++++++++++++++++++++++++ drivers/net/wireless/mediatek/mt76/mt76x02_eeprom.h | 211 +++++++++++++++++++++++++++++++++++ drivers/net/wireless/mediatek/mt76/mt76x02_mac.c | 18 +++ drivers/net/wireless/mediatek/mt76/mt76x02_mac.h | 3 +- drivers/net/wireless/mediatek/mt76/mt76x02_mcu.c | 13 +++ drivers/net/wireless/mediatek/mt76/mt76x02_mcu.h | 11 ++ drivers/net/wireless/mediatek/mt76/mt76x02_mmio.c | 161 +++++++++++++++++++++++++++ drivers/net/wireless/mediatek/mt76/mt76x02_phy.c | 135 +++++++++++++++++++++++ drivers/net/wireless/mediatek/mt76/mt76x02_phy.h | 29 +++++ drivers/net/wireless/mediatek/mt76/mt76x02_usb_core.c | 2 +- drivers/net/wireless/mediatek/mt76/mt76x02_usb_mcu.c | 1 + drivers/net/wireless/mediatek/mt76/mt76x02_util.c | 39 +++++++ drivers/net/wireless/mediatek/mt76/mt76x02_util.h | 24 ++++ drivers/net/wireless/mediatek/mt76/mt76x2.h | 42 +------ drivers/net/wireless/mediatek/mt76/mt76x2_core.c | 28 ++--- drivers/net/wireless/mediatek/mt76/mt76x2_debugfs.c | 23 +--- drivers/net/wireless/mediatek/mt76/mt76x2_dfs.c | 7 +- drivers/net/wireless/mediatek/mt76/mt76x2_dma.c | 91 +-------------- drivers/net/wireless/mediatek/mt76/mt76x2_eeprom.c | 316 +++++++++++++++------------------------------------- drivers/net/wireless/mediatek/mt76/mt76x2_eeprom.h | 123 +-------------------- drivers/net/wireless/mediatek/mt76/mt76x2_init.c | 81 ++------------ drivers/net/wireless/mediatek/mt76/mt76x2_init_common.c | 24 ++-- drivers/net/wireless/mediatek/mt76/mt76x2_mac.c | 17 ++- drivers/net/wireless/mediatek/mt76/mt76x2_mac_common.c | 2 +- drivers/net/wireless/mediatek/mt76/mt76x2_main.c | 10 +- drivers/net/wireless/mediatek/mt76/mt76x2_mcu.c | 3 +- drivers/net/wireless/mediatek/mt76/mt76x2_mcu.h | 7 -- drivers/net/wireless/mediatek/mt76/mt76x2_mcu_common.c | 7 +- drivers/net/wireless/mediatek/mt76/mt76x2_pci.c | 1 + drivers/net/wireless/mediatek/mt76/mt76x2_phy.c | 8 +- drivers/net/wireless/mediatek/mt76/mt76x2_phy_common.c | 76 +++---------- drivers/net/wireless/mediatek/mt76/mt76x2_tx_common.c | 14 +-- drivers/net/wireless/mediatek/mt76/mt76x2u.h | 3 - drivers/net/wireless/mediatek/mt76/mt76x2u_init.c | 29 ++--- drivers/net/wireless/mediatek/mt76/mt76x2u_mac.c | 26 +---- drivers/net/wireless/mediatek/mt76/mt76x2u_main.c | 6 +- drivers/net/wireless/mediatek/mt76/mt76x2u_mcu.c | 1 + drivers/net/wireless/mediatek/mt76/mt76x2u_phy.c | 39 +------ drivers/net/wireless/mediatek/mt76/tx.c | 36 ++++-- drivers/net/wireless/mediatek/mt76/usb.c | 15 ++- 61 files changed, 2289 insertions(+), 2131 deletions(-) create mode 100644 drivers/net/wireless/mediatek/mt76/mt76x0/pci_mcu.c create mode 100644 drivers/net/wireless/mediatek/mt76/mt76x0/usb_mcu.c create mode 100644 drivers/net/wireless/mediatek/mt76/mt76x02_eeprom.c create mode 100644 drivers/net/wireless/mediatek/mt76/mt76x02_eeprom.h create mode 100644 drivers/net/wireless/mediatek/mt76/mt76x02_mmio.c create mode 100644 drivers/net/wireless/mediatek/mt76/mt76x02_phy.c create mode 100644 drivers/net/wireless/mediatek/mt76/mt76x02_phy.h