1. 17 Mar, 2020 4 commits
    • Felix Fietkau's avatar
      mt76: mt7615: fix antenna mask initialization in DBDC mode · 1a7d3f47
      Felix Fietkau authored
      Update wiphy available antenna mask, and fix chainmask setting on 3x3 hardware
      Signed-off-by: default avatarFelix Fietkau <nbd@nbd.name>
      1a7d3f47
    • Lorenzo Bianconi's avatar
      mt76: mt76u: rely only on data buffer for usb control messagges · b2c4d95c
      Lorenzo Bianconi authored
      Starting from commit 'a6bfb6d1 ("mt76: usb: use max packet length
      for m76u_copy")' reg_val does not share memory with usb data buffer.
      On non-coherent devices this approach can corrupt data pointer since data
      and reg_val share the same cache-line, resulting in the following crash:
      
      [  371.544901] CPU 0 Unable to handle kernel paging request at virtual address 00000000, epc == 8042fbb0
      [  371.558521] CPU: 0 PID: 11 Comm: kworker/u2:2 Not tainted 4.14.160 #0
      [  371.565204] Workqueue: mt76u mt76u_deinit [mt76_usb]
      [  371.570331] task: 83823ac0 task.stack: 8386c000
      [  371.575004] $ 0   : 00000000 80590000 00000000 00000000
      [  371.580407] $ 4   : 82edaad0 00000002 83823ac0 fffffff8
      [  371.585810] $ 8   : fffffffd 0000fc00 8052da00 00000000
      [  371.591212] $12   : 000b2285 ae53a1a9 00108845 89da44c4
      [  371.596615] $16   : 82edaad0 82ed9d20 00001798 832edf00
      [  371.602019] $20   : 00000000 8386dda8 80530000 fffffffe
      [  371.607421] $24   : 8051d040 76274d1b
      [  371.612824] $28   : 8386c000 8386dd88 82edaad4 830d4d50
      [  371.618228] Hi    : 000000f7
      [  371.621203] Lo    : 33333371
      [  371.624196] epc   : 8042fbb0 __mutex_lock.isra.2+0x134/0x378
      [  371.630043] ra    : 830d4d50 mt76u_deinit+0x418/0xa6c [mt76_usb]
      [  371.636237] Status: 1000fc03KERNEL EXL IE
      [  371.640557] Cause : 0080000c (ExcCode 03)
      [  371.644696] BadVA : 00000000
      [  371.647671] PrId  : 00019374 (MIPS 24Kc)
      [  371.726123]  usbcore nls_base usb_common
      [  371.730180] Process kworker/u2:2 (pid: 11, threadinfo=8386c000, task=83823ac0, tls=00000000)
      [  371.738884] Stack : 833d009c 83210b4c 82ed8bc0 8386ddac 000001ff 8008ac50 8386ddac 83b74b00
      [  371.747519]         82edaad4 00000000 83b74b48 83210c38 82edaad0 82ed9d20 00001798 832edf00
      [  371.756157]         00000000 00000000 80530000 fffffffe 80530000 830d4d50 00000040 8389d850
      [  371.764794]         8052d9d8 8389d850 8386de30 82ed9d20 8386de5f 831c27bc 833d48ec 8052d9d8
      [  371.773431]         83823ac0 83823af0 82edab00 82ed9d20 8386de5f 831c5c30 00000000 8052d9a8
      [  371.782069]         ...
      [  371.784598] Call Trace:
      [  371.787130] [<8042fbb0>] __mutex_lock.isra.2+0x134/0x378
      [  371.792622] [<830d4d50>] mt76u_deinit+0x418/0xa6c [mt76_usb]
      [  371.808546]
      [  371.810920] ---[ end trace c62f0601f6730eb0 ]---
      [  371.818101] Kernel panic - not syncing: Fatal exception
      [  371.824420] Rebooting in 3 seconds..
      
      Fix the issue relying only on data buffer to send/receive usb control messages
      
      Fixes: a6bfb6d1 ("mt76: usb: use max packet length for m76u_copy")
      Signed-off-by: default avatarLorenzo Bianconi <lorenzo@kernel.org>
      Signed-off-by: default avatarFelix Fietkau <nbd@nbd.name>
      b2c4d95c
    • Lorenzo Bianconi's avatar
      mt76: mt76u: fix a possible memory leak in mt76u_init · 2da7cc7d
      Lorenzo Bianconi authored
      Remove usb workqueue if mt76u_set_endpoints fails.
      
      Fixes: 284efb47 ("mt76: mt76u: rely on a dedicated stats workqueue")
      Signed-off-by: default avatarLorenzo Bianconi <lorenzo@kernel.org>
      Signed-off-by: default avatarFelix Fietkau <nbd@nbd.name>
      2da7cc7d
    • Lorenzo Bianconi's avatar
      mt76: mt76u: loop over all possible rx queues in mt76u_rx_tasklet · 44e8f8ef
      Lorenzo Bianconi authored
      Loop over all possible hw rx queues in mt76u_rx_tasklet since new
      devices will report mcu events through mcu hw queue
      Signed-off-by: default avatarLorenzo Bianconi <lorenzo@kernel.org>
      Signed-off-by: default avatarFelix Fietkau <nbd@nbd.name>
      44e8f8ef
  2. 16 Mar, 2020 1 commit
  3. 12 Mar, 2020 31 commits
  4. 11 Mar, 2020 4 commits
    • tangbin's avatar
      ftgmac100: Remove redundant judgement · 86eeb97d
      tangbin authored
      In this function, ftgmac100_probe() can be triggered only
      if the platform_device and platform_driver matches, so the
      judgement at the beginning is redundant.
      Signed-off-by: default avatartangbin <tangbin@cmss.chinamobile.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      86eeb97d
    • Remi Pommarel's avatar
      ath9k: Handle txpower changes even when TPC is disabled · 968ae2ca
      Remi Pommarel authored
      When TPC is disabled IEEE80211_CONF_CHANGE_POWER event can be handled to
      reconfigure HW's maximum txpower.
      
      This fixes 0dBm txpower setting when user attaches to an interface for
      the first time with the following scenario:
      
      ieee80211_do_open()
          ath9k_add_interface()
              ath9k_set_txpower() /* Set TX power with not yet initialized
                                     sc->hw->conf.power_level */
      
          ieee80211_hw_config() /* Iniatilize sc->hw->conf.power_level and
                                   raise IEEE80211_CONF_CHANGE_POWER */
      
          ath9k_config() /* IEEE80211_CONF_CHANGE_POWER is ignored */
      
      This issue can be reproduced with the following:
      
        $ modprobe -r ath9k
        $ modprobe ath9k
        $ wpa_supplicant -i wlan0 -c /tmp/wpa.conf &
        $ iw dev /* Here TX power is either 0 or 3 depending on RF chain */
        $ killall wpa_supplicant
        $ iw dev /* TX power goes back to calibrated value and subsequent
                    calls will be fine */
      
      Fixes: 283dd119 ("ath9k: add per-vif TX power capability")
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarRemi Pommarel <repk@triplefau.lt>
      Signed-off-by: default avatarKalle Valo <kvalo@codeaurora.org>
      968ae2ca
    • Krzysztof Kozlowski's avatar
      ath5k: Add proper dependency for ATH5K_AHB · c98cdaef
      Krzysztof Kozlowski authored
      The CONFIG_ATH5K_AHB could be enabled on ATH25 system without enabling
      ATH5K driver itself.  This does not make sense because CONFIG_ATH5K_AHB
      controls object build within drivers/net/wireless/ath/ath5k/ so enabling
      it without CONFIG_ATH5K brings nothing.
      
      Add proper dependency to CONFIG_ATH5K_AHB.
      Signed-off-by: default avatarKrzysztof Kozlowski <krzk@kernel.org>
      Signed-off-by: default avatarKalle Valo <kvalo@codeaurora.org>
      c98cdaef
    • Pradeep Kumar Chitrapu's avatar
      ath11k: add thermal sensor device support · a41d1034
      Pradeep Kumar Chitrapu authored
      Temperature sensor generates electrical analog voltage from temperature
      of each chain. The analog voltage is converted to digital value through
      ADC. For reading temperature values fom user space, hw monitoring device
      is used.
      
      Whenever the user requests for current temperature, the driver sends WMI
      command and wait for response. For reading temperature,
      
      cat /sys/class/ieee80211/phy*/device/hwmon/hwmon2/temp1_input
      Signed-off-by: default avatarPradeep Kumar Chitrapu <pradeepc@codeaurora.org>
      Signed-off-by: default avatarKalle Valo <kvalo@codeaurora.org>
      a41d1034