Skip to content
Permalink
Emmanuel-Grumb…
Switch branches/tags

Commits on Jun 21, 2021

  1. iwlwifi: mvm: add vendor commands needed for iwlmei

    Add the vendor commands that must be used by the network manager
    to allow proper operation of iwlmei.
    
    * Send information on the AP CSME is connected to
    * Notify the userspace when roaming is forbidden
    * Allow the userspace to require ownership
    
    Co-Developed-by: Ayala Beker <ayala.beker@intel.com>
    Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
    egrumbach authored and intel-lab-lkp committed Jun 21, 2021
  2. nl80211: vendor-cmd: add Intel vendor commands for iwlmei usage

    iwlmei allows to integrate with the CSME firmware. There are
    flows that are prioprietary for this purpose:
    
    * Get the information the AP, the CSME firmware is connected
      to. This is useful when we need to speed up the connection
      process in case the CSME firmware has an TCP connection
      that must be kept alive across the ownership transition.
    * Forbid roaming, which will happen when the CSME firmware
      wants to tell the user space not disrupt the connection.
    * Request ownership, upon driver boot when the CSME firmware
      owns the device.
    
    Co-Developed-by: Ayala Beker <ayala.beker@intel.com>
    Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
    egrumbach authored and intel-lab-lkp committed Jun 21, 2021
  3. iwlwifi: integrate with iwlmei

    iwlmei needs to know about the follwing events:
    
    * Association
    * De-association
    * Country Code change
    * SW Rfkill change
    * SAR table changes
    
    iwlmei can take the device away from us, so report the new
    rfkill type when this happens.
    Advertise the required data from the CSME firmware to the
    usersapce: mostly, the AP that the CSME firmware is currently
    associated to in case there is an active link protection
    session.
    Generate the HOST_ASSOC / HOST_DISSASSOC messages.
    
    Don't support WPA1 (non-RSNA) for now.
    Don't support shared wep either.
    We can then determine the AUTH parameter by checking the AKM.
    Feed the cipher from the key installation.
    
    SW Rfkill will be implemented later when cfg80211 will
    allow us to read the SW Rfkill state.
    
    Co-Developed-by: Ayala Beker <ayala.beker@intel.com>
    Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
    Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
    egrumbach authored and intel-lab-lkp committed Jun 21, 2021
  4. iwlwifi: mei: add the driver to allow cooperation with CSME

    iwlmei is a driver that handles the communication with the
    Wireless driver of the CSME firmware.
    More details in the documentation included in this patch.
    
    Co-Developed-by: Ayala Beker <ayala.beker@intel.com>
    Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
    egrumbach authored and intel-lab-lkp committed Jun 21, 2021

Commits on Jun 19, 2021

  1. rtl8xxxu: avoid parsing short RX packet

    One USB data buffer can contain multiple received network
    packets. If that's the case, they're processed this way:
    1. Original buffer is cloned
    2. Original buffer is trimmed to contain only the first
       network packet
    3. This first network packet is passed to network stack
    4. Cloned buffer is trimmed to eliminate the first network
       packet
    5. Repeat with the cloned buffer until there are no more
       network packets inside
    
    However, if the space remaining in original buffer after
    the first network packet is not enough to contain at least
    another network packet descriptor, it is not cloned.
    
    The loop parsing this packets ended if remaining space == 0.
    But if the remaining space was > 0 but < packet descriptor
    size, another iteration of the loop was done, processing again
    the previous packet because cloning didn't happen. Moreover,
    the ownership of this packet had been passed to network
    stack in the previous iteration.
    
    This patch ensures that no extra iteration is done if the
    remaining size is not enough for one packet, and also avoid
    the first iteration for the same reason.
    
    Probably this doesn't happen in practice, but can happen
    theoretically.
    
    Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
    Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
    Link: https://lore.kernel.org/r/20210511071926.8951-1-ihuguet@redhat.com
    Íñigo Huguet authored and Kalle Valo committed Jun 19, 2021
  2. rtl8xxxu: Fix device info for RTL8192EU devices

    Based on 2001:3319 and 2357:0109 which I used to test the fix and
    0bda:818b and 2357:0108 for which I found efuse dumps online.
    
    == 2357:0109 ==
    === Before ===
    Vendor: Realtek
    Product: \x03802.11n NI
    Serial:
    === After ===
    Vendor: Realtek
    Product: 802.11n NIC
    Serial not available.
    
    == 2001:3319 ==
    === Before ===
    Vendor: Realtek
    Product: Wireless N
    Serial: no USB Adap
    === After ===
    Vendor: Realtek
    Product: Wireless N Nano USB Adapter
    Serial not available.
    
    Signed-off-by: Pascal Terjan <pterjan@google.com>
    Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
    Link: https://lore.kernel.org/r/20210424172959.1559890-1-pterjan@google.com
    pterjan authored and Kalle Valo committed Jun 19, 2021
  3. Merge tag 'mt76-for-kvalo-2021-06-18' of https://github.com/nbd168/wi…

    …reless into pending
    
    mt76 patches for 5.14
    
    * mt7915 MSI support
    * disable ASPM on mt7915
    * mt7915 tx status reporting
    * mt7921 decap offload
    * driver fixes
    * cleanups
    * mt7921 runtime power management improvements
    * testmode improvements/fixes
    * runtime PM improvements
    Kalle Valo committed Jun 19, 2021
  4. mt76: mt7921: allow chip reset during device restart

    Disable chip full reset just during device probing but allow
    it during hw restart.
    
    Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    LorenzoBianconi authored and nbd168 committed Jun 19, 2021
  5. mt76: mt7615: set macwork timeout according to runtime-pm

    Set macwork timeout value according to runtime-pm in order to reduce
    power consumption
    
    Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    LorenzoBianconi authored and nbd168 committed Jun 19, 2021
  6. mt76: mt7663s: enable runtime-pm

    Allow the user to enable runtime-pm for mt7663s driver
    
    Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    LorenzoBianconi authored and nbd168 committed Jun 19, 2021
  7. mt76: mt7663s: rely on mt76_connac_pm_ref/mt76_connac_pm_unref in tx …

    …path
    
    Similar to mt7663e, rely on mt76_connac_pm_ref/mt76_connac_pm_unref to
    check PM state and increment/decrement wake counter
    
    Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    LorenzoBianconi authored and nbd168 committed Jun 19, 2021
  8. mt76: mt7663s: rely on pm reference counting

    As already done for mt7921 and mt7663e, rely on pm reference counting in
    drv/fw_own
    
    Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    LorenzoBianconi authored and nbd168 committed Jun 19, 2021
  9. mt76: sdio: do not run mt76_txq_schedule directly

    In order to support runtime-pm for sdio, do not run mt76_txq_schedule
    directly, but schedule tx_worker instead
    
    Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    LorenzoBianconi authored and nbd168 committed Jun 19, 2021
  10. mt76: mt7921: enable HE BFee capability

    Enables HE MU/SU beamformee functionality
    
    Signed-off-by: Eric-SY Chang <Eric-SY.Chang@mediatek.com>
    Signed-off-by: Deren Wu <deren.wu@mediatek.com>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    deren authored and nbd168 committed Jun 19, 2021
  11. mt76: disable TWT capabilities for the moment

    Disable TWT REQ/RES mac capabilities since TWT is not supported
    yet in mt7915/mt7921.
    
    Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    LorenzoBianconi authored and nbd168 committed Jun 19, 2021
  12. mt76: fix iv and CCMP header insertion

    The iv from RXD is only for TKIP_RSC/CCMP_PN/GCMP_PN, and it needs a
    check for CCMP header insertion. Move mt76_cipher_type to mt76.h to
    reduce duplicated code.
    
    Signed-off-by: Xing Song <xing.song@mediatek.com>
    Signed-off-by: Ryder Lee <ryder.lee@mediatek.com>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    ryderlee1110 authored and nbd168 committed Jun 19, 2021
  13. mt76: mt7921: fix the coredump is being truncated

    Fix the maximum size of the coredump generated with current mt7921
    firmware. Otherwise, a truncated coredump would be reported to userland
    via dev_coredumpv.
    
    Also, there is an additional error handling enhanced in the patch to avoid
    the possible invalid buffer access when the system failed to create the
    buffer to hold the coredump.
    
    Fixes: 0da3c79 ("mt76: mt7921: add coredump support")
    Co-developed-by: YN Chen <YN.Chen@mediatek.com>
    Signed-off-by: YN Chen <YN.Chen@mediatek.com>
    Signed-off-by: Sean Wang <sean.wang@mediatek.com>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    moore-bros authored and nbd168 committed Jun 19, 2021
  14. mt76: mt7921: fix kernel warning when reset on vif is not sta

    ieee80211_disconnect is only called for the staton mode.
    
    [  714.050429] WARNING: CPU: 1 PID: 382 at net/mac80211/mlme.c:2787
    ieee80211_disconnect+0x108/0x118 [mac80211]
    [  714.116704] Hardware name: MediaTek Asurada rev1 board (DT)
    [  714.122303] Workqueue: mt76 mt7921_mac_reset_work [mt7921e]
    [  714.127877] pstate: 20c00009 (nzCv daif +PAN +UAO)
    [  714.132761] pc : ieee80211_disconnect+0x108/0x118 [mac80211]
    [  714.138430] lr : mt7921_vif_connect_iter+0x28/0x54 [mt7921e]
    [  714.144083] sp : ffffffc0107cbbd0
    [  714.147394] x29: ffffffc0107cbbd0 x28: ffffffb26c9cb928
    [  714.152706] x27: ffffffb26c9cbd98 x26: 0000000000000000
    [  714.158017] x25: 0000000000000003 x24: ffffffb26c9c9c38
    [  714.163328] x23: ffffffb26c9c9c38 x22: ffffffb26c9c8860
    [  714.168639] x21: ffffffb23b940000 x20: ffffffb26c9c8860
    [  714.173950] x19: 0000000000000001 x18: 000000000000b67e
    [  714.179261] x17: 00000000064dd409 x16: ffffffd739cb28f0
    [  714.184571] x15: 0000000000000000 x14: 0000000000000227
    [  714.189881] x13: 0000000000000400 x12: ffffffd73a4eb060
    [  714.195191] x11: 0000000000000000 x10: 0000000000000000
    [  714.200502] x9 : ffffffd703a0a000 x8 : 0000000000000006
    [  714.205812] x7 : 2828282828282828 x6 : ffffffb200440396
    [  714.211122] x5 : 0000000000000000 x4 : 0000000000000004
    [  714.216432] x3 : 0000000000000000 x2 : ffffffb23b940c90
    [  714.221743] x1 : 0000000000000001 x0 : ffffffb23b940c90
    [  714.227054] Call trace:
    [  714.229594]  ieee80211_disconnect+0x108/0x118 [mac80211]
    [  714.234913]  mt7921_vif_connect_iter+0x28/0x54 [mt7921e]
    [  714.240313]  __iterate_interfaces+0xc4/0xdc [mac80211]
    [  714.245541]  ieee80211_iterate_interfaces+0x4c/0x68 [mac80211]
    [  714.251381]  mt7921_mac_reset_work+0x410/0x468 [mt7921e]
    [  714.256696]  process_one_work+0x208/0x3c8
    [  714.260706]  worker_thread+0x23c/0x3e8
    [  714.264456]  kthread+0x140/0x17c
    [  714.267685]  ret_from_fork+0x10/0x18
    
    Fixes: 0c1ce98 ("mt76: mt7921: add wifi reset support")
    Signed-off-by: Sean Wang <sean.wang@mediatek.com>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    moore-bros authored and nbd168 committed Jun 19, 2021
  15. mt76: mt7921: introduce dedicated control for deep_sleep

    Introduce ds_enable switch to fully control fw deep_sleep capability
    
    Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    LorenzoBianconi authored and nbd168 committed Jun 19, 2021
  16. mt76: mt7921: limit txpower according to userlevel power

    Limit tx power for single-sku according to userlevel power.
    
    Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    LorenzoBianconi authored and nbd168 committed Jun 19, 2021
  17. mt76: mt7921: improve code readability for mt7921_update_txs

    Introduce mt7921_update_txs routine in order to improve code readability
    for tx timestamp parsing/configuration.
    
    Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    LorenzoBianconi authored and nbd168 committed Jun 19, 2021
  18. mt76: mt7921: add deep sleep control to runtime-pm knob

    Add addtional the deep sleep control to runtime-pm knob to
    allow us to control driver switching between the full power
    mode and the deep sleep mode the firmware is able to support.
    
    Reviewed-by: Lorenzo Bianconi <lorenzo@kernel.org>
    Signed-off-by: Sean Wang <sean.wang@mediatek.com>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    moore-bros authored and nbd168 committed Jun 19, 2021
  19. mt76: mt7921: enable deep sleep at runtime

    Enable the deep sleep mode with that firmware is able to trap into
    the doze state at runtime to reduce the power consumption further.
    
    The deep sleep mode is not allowed in the STA state transition with
    the firmware to have the fast connection experience as we've done in
    the full power mode
    
    Reviewed-by: Lorenzo Bianconi <lorenzo@kernel.org>
    Signed-off-by: Sean Wang <sean.wang@mediatek.com>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    moore-bros authored and nbd168 committed Jun 19, 2021
  20. mt76: mt7915: fix IEEE80211_HE_PHY_CAP7_MAX_NC for station mode

    The value of station mode is always 0.
    
    Fixed: 00b2e16 ("mt76: mt7915: add TxBF capabilities")
    Signed-off-by: Ryder Lee <ryder.lee@mediatek.com>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    ryderlee1110 authored and nbd168 committed Jun 19, 2021
  21. mt76: use SPDX header file comment style

    header files should use '/* SPDX ... */
    Change from c file comment syle to header style
    
    Signed-off-by: Tom Rix <trix@redhat.com>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    trixirt authored and nbd168 committed Jun 19, 2021
  22. mt76: add a space between comment char and SPDX tag

    checkpatch expects a space between '#' and 'SPDX...'
    Add a space.
    
    Signed-off-by: Tom Rix <trix@redhat.com>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    trixirt authored and nbd168 committed Jun 19, 2021
  23. mt76: mt7915: improve MU stability

    - Adjust starec flow since VHT MU group is only updated by starec_vht
      follows starec_bf settings.
    - Drop unnecessary MU BF checks.
    
    TX MPDU PER (Status = Success):
                                               TOT_MPDU_CNT  FAIL_MPDU_CNT  TX_PER
    WCID Rate
    1      VHT_BW80_2SS_MCS7_LGI_LDPC_MUBF              114              0   0.00%
           VHT_BW80_2SS_MCS7_LGI_LDPC_MUBF_MU            64              0   0.00%
           VHT_BW80_2SS_MCS7_SGI_LDPC_MUBF              128              0   0.00%
           VHT_BW80_2SS_MCS7_SGI_LDPC_MUBF_MU           745              0   0.00%
           VHT_BW80_2SS_MCS8_LGI_LDPC_MUBF_MU           856              0   0.00%
           VHT_BW80_2SS_MCS8_SGI_LDPC_MUBF_MU          1430              4   0.28%
           VHT_BW80_2SS_MCS9_LGI_LDPC_MUBF_MU          5220             31   0.59%
           VHT_BW80_2SS_MCS9_LGI_LDPC_iBF                59              0   0.00%
           VHT_BW80_2SS_MCS9_SGI_LDPC_MUBF               64              2   3.12%
           VHT_BW80_2SS_MCS9_SGI_LDPC_MUBF_MU         22132             76   0.34%
           VHT_BW80_2SS_MCS9_SGI_LDPC_iBF              2866              1   0.03%
    2      VHT_BW80_2SS_MCS7_LGI_LDPC_MUBF_MU          3781              5   0.13%
           VHT_BW80_2SS_MCS7_SGI_LDPC_MUBF_MU           735              0   0.00%
           VHT_BW80_2SS_MCS8_LGI_LDPC_MUBF_MU          1270            365  28.74%
           VHT_BW80_2SS_MCS8_SGI_LDPC_MUBF_MU          3420             57   1.67%
           VHT_BW80_2SS_MCS9_LGI_LDPC_MUBF              128              0   0.00%
           VHT_BW80_2SS_MCS9_LGI_LDPC_MUBF_MU            64              0   0.00%
           VHT_BW80_2SS_MCS9_SGI_LDPC_MUBF              191              0   0.00%
           VHT_BW80_2SS_MCS9_SGI_LDPC_MUBF_MU         18833            320   1.70%
           VHT_BW80_2SS_MCS9_SGI_LDPC_iBF              6040              0   0.00%
    287    OFDM 6M
    
    Tested-by: Evelyn Tsai <evelyn.tsai@mediatek.com>
    Signed-off-by: Ryder Lee <ryder.lee@mediatek.com>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    ryderlee1110 authored and nbd168 committed Jun 19, 2021
  24. mt76: mt7915: introduce mt7915_mcu_set_txbf()

    Use mt7915_mcu_set_txbf() to reduce global functions. This can be
    easily extended to support other TxBF commands in further patches.
    
    Signed-off-by: Ryder Lee <ryder.lee@mediatek.com>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    ryderlee1110 authored and nbd168 committed Jun 19, 2021
  25. mt76: make mt76_update_survey() per phy

    Reduce duplicated survey for DBDC.
    
    Signed-off-by: Ryder Lee <ryder.lee@mediatek.com>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    ryderlee1110 authored and nbd168 committed Jun 19, 2021
  26. mt76: mt7915: drop the use of repeater entries for station interfaces

    There are firmware or hardware issues, which are currently causing tx hangs
    when attempting to use these interfaces
    
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    nbd168 committed Jun 19, 2021
  27. mt76: connac: check band caps in mt76_connac_mcu_set_rate_txpower

    Check device band capabilities before configuring single-sku
    
    Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    LorenzoBianconi authored and nbd168 committed Jun 19, 2021
  28. mt76: move mt76_get_next_pkt_id in mt76.h

    In order to remove duplicated code, move mt76_get_next_pkt_id routine
    in mt76.h
    
    Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    LorenzoBianconi authored and nbd168 committed Jun 19, 2021
  29. mt76: reduce rx buffer size to 2048

    Reduce rx buffer size to 2048 for mt7921/mt7915/mt7615 since we
    now support rx amsdu offload
    
    Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    LorenzoBianconi authored and nbd168 committed Jun 19, 2021
  30. mt76: connac: fix the maximum interval schedule scan can support

    Maximum interval (in seconds) for schedule scan plan supported by
    the offload firmware can be U16_MAX.
    
    Signed-off-by: Sean Wang <sean.wang@mediatek.com>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    moore-bros authored and nbd168 committed Jun 19, 2021
  31. mt76: mt7915: fix rx fcs error count in testmode

    FCS error packets are filtered by default and won't be reported to
    driver, so that RX fcs error and PER in testmode always show zero.
    Fix this issue by reading fcs error count from hw counter.
    
    We did't fix this issue by disabling fcs error rx filter since it may
    let HW suffer some SER errors.
    
    Fixes: 5d8a83f ("mt76: mt7915: implement testmode rx support")
    Signed-off-by: Shayne Chen <shayne.chen@mediatek.com>
    Signed-off-by: Felix Fietkau <nbd@nbd.name>
    csyuanc authored and nbd168 committed Jun 19, 2021
Older