1. 29 3月, 2018 9 次提交
    • Y
      ath10k: avoid to set WEP key for TDLS peer · c3816c9e
      Yingying Tang 提交于
      TDLS peer do not need WEP key. Setting WEP key will lead
      to TDLS setup failure. Add fix to avoid setting WEP key
      for TDLS peer.
      Signed-off-by: NYingying Tang <yintang@qti.qualcomm.com>
      Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
      c3816c9e
    • Y
      ath10k: enable TDLS peer inactivity detection · 4c9f8d11
      Yingying Tang 提交于
      Enable TDLS peer inactivity detetion feature.
      QCA6174 firmware(version: WLAN.RM.4.4) support TDLS link inactivity detecting.
      Set related parameters in TDLS WMI command to enable this feature.
      Signed-off-by: NYingying Tang <yintang@qti.qualcomm.com>
      Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
      4c9f8d11
    • Y
      ath10k: enable TDLS peer buffer STA feature · 802ca335
      Yingying Tang 提交于
      Enable TDLS peer buffer STA feature.
      QCA6174 firmware(version: WLAN.RM.4.4) support TDLS peer buffer STA,
      it reports this capability through wmi service map in wmi service ready
      event. Set related parameter in TDLS WMI command to enable this feature.
      Signed-off-by: NYingying Tang <yintang@qti.qualcomm.com>
      Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
      802ca335
    • A
      ath10k: add memory dump support QCA9984 · 219cc084
      Anilkumar Kolli 提交于
      QCA9984/QCA99X0/QCA4019 chipsets have 8 memory regions, dump all of them to the
      firmware coredump file. Some of the regions need to be read using ioread() so
      add new region types for them.
      Signed-off-by: NAnilkumar Kolli <akolli@codeaurora.org>
      [kvalo: refactoring etc]
      Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
      219cc084
    • K
      ath10k: refactor ath10k_pci_dump_memory() in preparation for QCA9984 support · 10c22884
      Kalle Valo 提交于
      As QCA9984 needs two region types refactor the code to make it easier add the
      new types. No functional changes.
      Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
      10c22884
    • S
      ath10k: suppress "Unknown eventid: 36925" warnings · 606204bb
      Sathishkumar Muruganandam 提交于
      FW has Smart Logging feature enabled by default for detecting failures
      and processing FATAL_CONDITION_EVENTID (36925 - 0x903D) back to host.
      
      Since ath10k doesn't implement the Smart Logging and FATAL CONDITION
      EVENT processing yet, suppressing the unknown event ID warning by moving
      this under ATH10K_DBG_WMI.
      
      Simulated the same issue by having associated STA powered off when
      ping flood was running from AP backbone. This triggerd STA KICKOUT
      in AP followed by FATAL CONDITION event 36925.
      
      Issue was reproduced and verified in below DUT
      ------------------------------------------------
      AP mode of OpenWRT QCA9984 running 6.0.8 with FW ver 10.4-3.5.3-00053
      Signed-off-by: NSathishkumar Muruganandam <murugana@codeaurora.org>
      Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
      606204bb
    • R
      ath10k: add FW API 6 firmware image for QCA9377 · e3814bec
      Ryan Hsu 提交于
      Firmware WLAN.TF.2.1-00014-QCARMSWP-1 now supports reading the board ID
      information and also required 9 IRAM bank, which older ath10k version
      don't have the support will fail to be enabled, so in order to maintain
      the backward compatibility, we need to update the FW API to 6.
      Signed-off-by: NRyan Hsu <ryanhsu@codeaurora.org>
      Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
      e3814bec
    • R
      ath10k: enable QCA6174/QCA9377 to read the chip temperature · e98199a8
      Ryan Hsu 提交于
      The firmware of QCA6174/QCA9377 already support the feature, just enable
      it to be able to handle the get_temperature command and process the event.
      
      You can read the temperature by using the hwmon interface,
      
      cat /sys/class/ieee80211/phy*/device/hwmon/hwmon2/temp1_input
      
      Verified with the following hardware and software combination,
      QCA6174, only firmware-4.bin doesn't support this, otherwise all support.
      QCA9377, all the firmwares upstreamed support this command
      Signed-off-by: NRyan Hsu <ryanhsu@codeaurora.org>
      Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
      e98199a8
    • K
      Revert "ath10k: send (re)assoc peer command when NSS changed" · 55cc11da
      Karthikeyan Periyasamy 提交于
      This reverts commit 55884c04.
      
      When Ath10k is in AP mode and an unassociated STA sends a VHT action frame
      (Operating Mode Notification for the NSS change) periodically to AP this causes
      ath10k to call ath10k_station_assoc() which sends WMI_PEER_ASSOC_CMDID during
      NSS update. Over the time (with a certain client it can happen within 15 mins
      when there are over 500 of these VHT action frames) continuous calls of
      WMI_PEER_ASSOC_CMDID cause firmware to assert due to resource exhaust.
      
      To my knowledge setting WMI_PEER_NSS peer param itself enough to handle NSS
      updates and no need to call ath10k_station_assoc(). So revert the original
      commit from 2014 as it's unclear why the change was really needed.
      Now the firmware assert doesn't happen anymore.
      
      Issue observed in QCA9984 platform with firmware version:10.4-3.5.3-00053.
      This Change tested in QCA9984 with firmware version: 10.4-3.5.3-00053 and
      QCA988x platform with firmware version: 10.2.4-1.0-00036.
      
      Firmware Assert log:
      
      ath10k_pci 0002:01:00.0: firmware crashed! (guid e61f1274-9acd-4c5b-bcca-e032ea6e723c)
      ath10k_pci 0002:01:00.0: qca9984/qca9994 hw1.0 target 0x01000000 chip_id 0x00000000 sub 168c:cafe
      ath10k_pci 0002:01:00.0: kconfig debug 1 debugfs 1 tracing 0 dfs 1 testmode 1
      ath10k_pci 0002:01:00.0: firmware ver 10.4-3.5.3-00053 api 5 features no-p2p,mfp,peer-flow-ctrl,btcoex-param,allows-mesh-bcast crc32 4c56a386
      ath10k_pci 0002:01:00.0: board_file api 2 bmi_id 0:4 crc32 c2271344
      ath10k_pci 0002:01:00.0: htt-ver 2.2 wmi-op 6 htt-op 4 cal otp max-sta 512 raw 0 hwcrypto 1
      ath10k_pci 0002:01:00.0: firmware register dump:
      ath10k_pci 0002:01:00.0: [00]: 0x0000000A 0x000015B3 0x00981E5F 0x00975B31
      ath10k_pci 0002:01:00.0: [04]: 0x00981E5F 0x00060530 0x00000011 0x00446C60
      ath10k_pci 0002:01:00.0: [08]: 0x0042F1FC 0x00458080 0x00000017 0x00000000
      ath10k_pci 0002:01:00.0: [12]: 0x00000009 0x00000000 0x00973ABC 0x00973AD2
      ath10k_pci 0002:01:00.0: [16]: 0x00973AB0 0x00960E62 0x009606CA 0x00000000
      ath10k_pci 0002:01:00.0: [20]: 0x40981E5F 0x004066DC 0x00400000 0x00981E34
      ath10k_pci 0002:01:00.0: [24]: 0x80983B48 0x0040673C 0x000000C0 0xC0981E5F
      ath10k_pci 0002:01:00.0: [28]: 0x80993DEB 0x0040676C 0x00431AB8 0x0045D0C4
      ath10k_pci 0002:01:00.0: [32]: 0x80993E5C 0x004067AC 0x004303C0 0x0045D0C4
      ath10k_pci 0002:01:00.0: [36]: 0x80994AAB 0x004067DC 0x00000000 0x0045D0C4
      ath10k_pci 0002:01:00.0: [40]: 0x809971A0 0x0040681C 0x004303C0 0x00441B00
      ath10k_pci 0002:01:00.0: [44]: 0x80991904 0x0040688C 0x004303C0 0x0045D0C4
      ath10k_pci 0002:01:00.0: [48]: 0x80963AD3 0x00406A7C 0x004303C0 0x009918FC
      ath10k_pci 0002:01:00.0: [52]: 0x80960E80 0x00406A9C 0x0000001F 0x00400000
      ath10k_pci 0002:01:00.0: [56]: 0x80960E51 0x00406ACC 0x00400000 0x00000000
      ath10k_pci 0002:01:00.0: Copy Engine register dump:
      ath10k_pci 0002:01:00.0: index: addr: sr_wr_idx: sr_r_idx: dst_wr_idx: dst_r_idx:
      ath10k_pci 0002:01:00.0: [00]: 0x0004a000 15 15 3 3
      ath10k_pci 0002:01:00.0: [01]: 0x0004a400 17 17 212 213
      ath10k_pci 0002:01:00.0: [02]: 0x0004a800 21 21 20 21
      ath10k_pci 0002:01:00.0: [03]: 0x0004ac00 25 25 27 25
      ath10k_pci 0002:01:00.0: [04]: 0x0004b000 515 515 144 104
      ath10k_pci 0002:01:00.0: [05]: 0x0004b400 28 28 155 156
      ath10k_pci 0002:01:00.0: [06]: 0x0004b800 12 12 12 12
      ath10k_pci 0002:01:00.0: [07]: 0x0004bc00 1 1 1 1
      ath10k_pci 0002:01:00.0: [08]: 0x0004c000 0 0 127 0
      ath10k_pci 0002:01:00.0: [09]: 0x0004c400 1 1 1 1
      ath10k_pci 0002:01:00.0: [10]: 0x0004c800 0 0 0 0
      ath10k_pci 0002:01:00.0: [11]: 0x0004cc00 0 0 0 0
      ath10k_pci 0002:01:00.0: CE[1] write_index 212 sw_index 213 hw_index 0 nentries_mask 0x000001ff
      ath10k_pci 0002:01:00.0: CE[2] write_index 20 sw_index 21 hw_index 0 nentries_mask 0x0000007f
      ath10k_pci 0002:01:00.0: CE[5] write_index 155 sw_index 156 hw_index 0 nentries_mask 0x000001ff
      ath10k_pci 0002:01:00.0: DMA addr: nbytes: meta data: byte swap: gather:
      ath10k_pci 0002:01:00.0: [455]: 0x580c0042 0 0 0 0
      ath10k_pci 0002:01:00.0: [456]: 0x594a0010 0 0 0 1
      ath10k_pci 0002:01:00.0: [457]: 0x580c0042 0 0 0 0
      ath10k_pci 0002:01:00.0: [458]: 0x594a0038 0 0 0 1
      ath10k_pci 0002:01:00.0: [459]: 0x580c0a42 0 0 0 0
      ath10k_pci 0002:01:00.0: [460]: 0x594a0060 0 0 0 1
      ath10k_pci 0002:01:00.0: [461]: 0x580c0c42 0 0 0 0
      ath10k_pci 0002:01:00.0: [462]: 0x594a0010 0 0 0 1
      ath10k_pci 0002:01:00.0: [463]: 0x580c0c42 0 0 0 0
      ath10k_pci 0002:01:00.0: [464]: 0x594a0038 0 0 0 1
      ath10k_pci 0002:01:00.0: [465]: 0x580c0a42 0 0 0 0
      ath10k_pci 0002:01:00.0: [466]: 0x594a0060 0 0 0 1
      ath10k_pci 0002:01:00.0: [467]: 0x580c0042 0 0 0 0
      ath10k_pci 0002:01:00.0: [468]: 0x594a0010 0 0 0 1
      ath10k_pci 0002:01:00.0: [469]: 0x580c1c42 0 0 0 0
      ath10k_pci 0002:01:00.0: [470]: 0x594a0010 0 0 0 1
      ath10k_pci 0002:01:00.0: [471]: 0x580c1c42 0 0 0 0
      ath10k_pci 0002:01:00.0: [472]: 0x594a0010 0 0 0 1
      ath10k_pci 0002:01:00.0: [473]: 0x580c1c42 0 0 0 0
      ath10k_pci 0002:01:00.0: [474]: 0x594a0010 0 0 0 1
      ath10k_pci 0002:01:00.0: [475]: 0x580c0642 0 0 0 0
      ath10k_pci 0002:01:00.0: [476]: 0x594a0038 0 0 0 1
      ath10k_pci 0002:01:00.0: [477]: 0x580c0842 0 0 0 0
      ath10k_pci 0002:01:00.0: [478]: 0x594a0060 0 0 0 1
      ath10k_pci 0002:01:00.0: [479]: 0x580c0042 0 0 0 0
      ath10k_pci 0002:01:00.0: [480]: 0x594a0010 0 0 0 1
      ath10k_pci 0002:01:00.0: [481]: 0x580c0042 0 0 0 0
      ath10k_pci 0002:01:00.0: [482]: 0x594a0038 0 0 0 1
      ath10k_pci 0002:01:00.0: [483]: 0x580c0842 0 0 0 0
      ath10k_pci 0002:01:00.0: [484]: 0x594a0060 0 0 0 1
      ath10k_pci 0002:01:00.0: [485]: 0x580c0642 0 0 0 0
      ath10k_pci 0002:01:00.0: [486]: 0x594a0010 0 0 0 1
      ath10k_pci 0002:01:00.0: [487]: 0x580c0642 0 0 0 0
      ath10k_pci 0002:01:00.0: [488]: 0x594a0038 0 0 0 1
      ath10k_pci 0002:01:00.0: [489]: 0x580c0842 0 0 0 0
      ath10k_pci 0002:01:00.0: [490]: 0x594a0060 0 0 0 1
      ath10k_pci 0002:01:00.0: [491]: 0x580c0042 0 0 0 0
      ath10k_pci 0002:01:00.0: [492]: 0x58174040 0 1 0 0
      ath10k_pci 0002:01:00.0: [493]: 0x5a946040 0 1 0 0
      ath10k_pci 0002:01:00.0: [494]: 0x59909040 0 1 0 0
      ath10k_pci 0002:01:00.0: [495]: 0x5ae5a040 0 1 0 0
      ath10k_pci 0002:01:00.0: [496]: 0x58096040 0 1 0 0
      ath10k_pci 0002:01:00.0: [497]: 0x594a0010 0 0 0 1
      ath10k_pci 0002:01:00.0: [498]: 0x580c0642 0 0 0 0
      ath10k_pci 0002:01:00.0: [499]: 0x5c1e0040 0 1 0 0
      ath10k_pci 0002:01:00.0: [500]: 0x58153040 0 1 0 0
      ath10k_pci 0002:01:00.0: [501]: 0x58129040 0 1 0 0
      ath10k_pci 0002:01:00.0: [502]: 0x5952f040 0 1 0 0
      ath10k_pci 0002:01:00.0: [503]: 0x59535040 0 1 0 0
      ath10k_pci 0002:01:00.0: [504]: 0x594a0010 0 0 0 1
      ath10k_pci 0002:01:00.0: [505]: 0x580c0042 0 0 0 0
      ath10k_pci 0002:01:00.0: [506]: 0x594a0010 0 0 0 1
      ath10k_pci 0002:01:00.0: [507]: 0x580c0042 0 0 0 0
      ath10k_pci 0002:01:00.0: [508]: 0x594a0010 0 0 0 1
      ath10k_pci 0002:01:00.0: [509]: 0x580c0042 0 0 0 0
      ath10k_pci 0002:01:00.0: [510]: 0x594a0010 0 0 0 1
      ath10k_pci 0002:01:00.0: [511]: 0x580c0042 0 0 0 0
      ath10k_pci 0002:01:00.0: [512]: 0x5adcc040 0 1 0 0
      ath10k_pci 0002:01:00.0: [513]: 0x5cf3d040 0 1 0 0
      ath10k_pci 0002:01:00.0: [514]: 0x5c1e9040 64 1 0 0
      ath10k_pci 0002:01:00.0: [515]: 0x00000000 0 0 0 0
      Signed-off-by: NKarthikeyan Periyasamy <periyasa@codeaurora.org>
      Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
      55cc11da
  2. 26 3月, 2018 4 次提交
    • K
      ath10k: Fix kernel panic while using worker (ath10k_sta_rc_update_wk) · 8b2d93dd
      Karthikeyan Periyasamy 提交于
      When attempt to run worker (ath10k_sta_rc_update_wk) after the station object
      (ieee80211_sta) delete will trigger the kernel panic.
      
      This problem arise in AP + Mesh configuration, Where the current node AP VAP
      and neighbor node mesh VAP MAC address are same. When the current mesh node
      try to establish the mesh link with neighbor node, driver peer creation for
      the neighbor mesh node fails due to duplication MAC address. Already the AP
      VAP created with same MAC address.
      
      It is caused by the following scenario steps.
      
      Steps:
      1. In above condition, ath10k driver sta_state callback (ath10k_sta_state)
         fails to do the state change for a station from IEEE80211_STA_NOTEXIST
         to IEEE80211_STA_NONE due to peer creation fails. Sta_state callback is
         called from ieee80211_add_station() to handle the new station
         (neighbor mesh node) request from the wpa_supplicant.
      2. Concurrently ath10k receive the sta_rc_update callback notification from
         the mesh_neighbour_update() to handle the beacon frames of the above
         neighbor mesh node. since its atomic callback, ath10k driver queue the
         work (ath10k_sta_rc_update_wk) to handle rc update.
      3. Due to driver sta_state callback fails (step 1), mac80211 free the station
         object.
      4. When the worker (ath10k_sta_rc_update_wk) scheduled to run, it will access
         the station object which is already deleted. so it will trigger kernel
         panic.
      
      Added the peer exist check in sta_rc_update callback before queue the work.
      
      Kernel Panic log:
      
      Unable to handle kernel NULL pointer dereference at virtual address 00000000
      pgd = c0204000
      [00000000] *pgd=00000000
      Internal error: Oops: 17 [#1] PREEMPT SMP ARM
      CPU: 1 PID: 1833 Comm: kworker/u4:2 Not tainted 3.14.77 #1
      task: dcef0000 ti: d72b6000 task.ti: d72b6000
      PC is at pwq_activate_delayed_work+0x10/0x40
      LR is at pwq_activate_delayed_work+0xc/0x40
      pc : [<c023f988>]    lr : [<c023f984>]    psr: 40000193
      sp : d72b7f18  ip : 0000007a  fp : d72b6000
      r10: 00000000  r9 : dd404414  r8 : d8c31998
      r7 : d72b6038  r6 : 00000004  r5 : d4907ec8  r4 : dcee1300
      r3 : ffffffe0  r2 : 00000000  r1 : 00000001  r0 : 00000000
      Flags: nZcv  IRQs off  FIQs on  Mode SVC_32  ISA ARM  Segment kernel
      Control: 10c5787d  Table: 595bc06a  DAC: 00000015
      ...
      Process kworker/u4:2 (pid: 1833, stack limit = 0xd72b6238)
      Stack: (0xd72b7f18 to 0xd72b8000)
      7f00:                                                       00000001 dcee1300
      7f20: 00000001 c02410dc d8c31980 dd404400 dd404400 c0242790 d8c31980 00000089
      7f40: 00000000 d93e1340 00000000 d8c31980 c0242568 00000000 00000000 00000000
      7f60: 00000000 c02474dc 00000000 00000000 000000f8 d8c31980 00000000 00000000
      7f80: d72b7f80 d72b7f80 00000000 00000000 d72b7f90 d72b7f90 d72b7fac d93e1340
      7fa0: c0247404 00000000 00000000 c0208d20 00000000 00000000 00000000 00000000
      7fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
      7fe0: 00000000 00000000 00000000 00000000 00000013 00000000 00000000 00000000
      [<c023f988>] (pwq_activate_delayed_work) from [<c02410dc>] (pwq_dec_nr_in_flight+0x58/0xc4)
      [<c02410dc>] (pwq_dec_nr_in_flight) from [<c0242790>] (worker_thread+0x228/0x360)
      [<c0242790>] (worker_thread) from [<c02474dc>] (kthread+0xd8/0xec)
      [<c02474dc>] (kthread) from [<c0208d20>] (ret_from_fork+0x14/0x34)
      Code: e92d4038 e1a05000 ebffffbc[69210.619376] SMP: failed to stop secondary CPUs
      Rebooting in 3 seconds..
      Signed-off-by: NKarthikeyan Periyasamy <periyasa@codeaurora.org>
      Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
      8b2d93dd
    • C
      ath10k: fix use-after-free in ath10k_wmi_cmd_send_nowait · 9ef0f58e
      Carl Huang 提交于
      The skb may be freed in tx completion context before
      trace_ath10k_wmi_cmd is called. This can be easily captured when
      KASAN(Kernel Address Sanitizer) is enabled. The fix is to move
      trace_ath10k_wmi_cmd before the send operation. As the ret has no
      meaning in trace_ath10k_wmi_cmd then, so remove this parameter too.
      Signed-off-by: NCarl Huang <cjhuang@codeaurora.org>
      Tested-by: NBrian Norris <briannorris@chromium.org>
      Reviewed-by: NBrian Norris <briannorris@chromium.org>
      Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
      9ef0f58e
    • M
      ath10k: debugfs support to get final TPC stats for 10.4 variants · bc64d052
      Maharaja Kennadyrajan 提交于
      Export the final Transmit Power Control (TPC) value, which is the
      minimum of control power and existing TPC value to user space via
      a new debugfs file "tpc_stats_final" to help with debugging.
      It works with the new wmi cmd and event introduced in 10.4 firmware
      branch.
      
      WMI command ID: WMI_PDEV_GET_TPC_TABLE_CMDID
      WMI event ID: WMI_PDEV_TPC_TABLE_EVENTID
      
      cat /sys/kernel/debug/ieee80211/phyX/ath10k/tpc_stats_final
      
      $ cat /sys/kernel/debug/ieee80211/phyX/ath10k/tpc_stats_final
      
      TPC config for channel 5180 mode 10
      
      CTL             =  0x 0 Reg. Domain             = 58
      Antenna Gain    =  0 Reg. Max Antenna Gain      =   0
      Power Limit     = 60 Reg. Max Power             = 60
      Num tx chains   =  2 Num supported rates        = 109
      
      ******************* CDD POWER TABLE ****************
      
      No.  Preamble Rate_code tpc_value1 tpc_value2 tpc_value3
      0    CCK      0x40        0          0
      1    CCK      0x41        0          0
      [...]
      107  HTCUP    0x 0       46          46
      108  HTCUP    0x 0       46          46
      
      ******************* STBC POWER TABLE ****************
      
      No.  Preamble Rate_code tpc_value1 tpc_value2 tpc_value3
      0    CCK      0x40        0          0
      1    CCK      0x41        0          0
      [...]
      107  HTCUP    0x 0        46         46
      108  HTCUP    0x 0        46         46
      
      ***********************************
      TXBF not supported
      **********************************
      
      The existing tpc_stats debugfs file provides the dump
      which is minimum of target power and regulatory domain.
      
      cat /sys/kernel/debug/ieee80211/phyX/ath10k/tpc_stats
      
      Hardware_used: QCA4019
      Firmware version: firmware-5.bin_10.4-3.0-00209
      Signed-off-by: NMaharaja Kennadyrajan <mkenna@codeaurora.org>
      Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
      bc64d052
    • V
      ath10k: add sta rx packet stats per tid · caee728a
      Vasanthakumar Thiagarajan 提交于
      Added per tid sta counters for the following
      
      - Total number MSDUs received from firmware
      - Number of MSDUs received with errors like decryption, crc, mic ,etc.
      - Number of MSDUs dropped in the driver
      - A-MPDU/A-MSDU subframe stats
      - Number of MSDUS passed to mac80211
      
      All stats other than A-MPDU stats are only for received data frames.
      A-MPDU stats might have stats for management frames when monitor
      interface is active where management frames are notified both in wmi
      and HTT interfaces.
      
      These per tid stats can be enabled with tid bitmask through a debugfs
      like below
      
       echo <tid_bitmask> > /sys/kernel/debug/ieee80211/phyX/ath10k/sta_tid_stats_mask
      
       tid 16 (tid_bitmask 0x10000) is used for non-qos data/management frames
      
      The stats are read from
      /sys/kernel/debug/ieee80211/phyX/netdev\:wlanX/stations/<sta_mac>/dump_tid_stats
      
      Sample output:
      
       To enable rx stats for tid 0, 5 and 6,
      
       echo 0x00000061 > /sys/kernel/debug/ieee80211/phy0/ath10k/sta_tid_stats_mask
      
      cat /sys/kernel/debug/ieee80211/phy0/netdev\:wlan15/stations/8c\:fd\:f0\:0a\:8e\:df/dump_tid_stats
      
        		Driver Rx pkt stats per tid, ([tid] count)
                      ------------------------------------------
      MSDUs from FW                   [00] 2567        [05] 3178        [06] 1089
      MSDUs unchained                 [00] 0           [05] 0           [06] 0
      MSDUs locally dropped:chained   [00] 0           [05] 0           [06] 0
      MSDUs locally dropped:filtered  [00] 0           [05] 0           [06] 0
      MSDUs queued for mac80211       [00] 2567        [05] 3178        [06] 1089
      MSDUs with error:fcs_err        [00] 0           [05] 0           [06] 2
      MSDUs with error:tkip_err       [00] 0           [05] 0           [06] 0
      MSDUs with error:crypt_err      [00] 0           [05] 0           [06] 0
      MSDUs with error:peer_idx_inval [00] 0           [05] 0           [06] 0
      
      A-MPDU num subframes upto 10    [00] 2567        [05] 3178        [06] 1087
      A-MPDU num subframes 11-20      [00] 0           [05] 0           [06] 0
      A-MPDU num subframes 21-30      [00] 0           [05] 0           [06] 0
      A-MPDU num subframes 31-40      [00] 0           [05] 0           [06] 0
      A-MPDU num subframes 41-50      [00] 0           [05] 0           [06] 0
      A-MPDU num subframes 51-60      [00] 0           [05] 0           [06] 0
      A-MPDU num subframes >60        [00] 0           [05] 0           [06] 0
      
      A-MSDU num subframes 1          [00] 2567        [05] 3178        [06] 1089
      A-MSDU num subframes 2          [00] 0           [05] 0           [06] 0
      A-MSDU num subframes 3          [00] 0           [05] 0           [06] 0
      A-MSDU num subframes 4          [00] 0           [05] 0           [06] 0
      A-MSDU num subframes >4         [00] 0           [05] 0           [06] 0
      Signed-off-by: NVasanthakumar Thiagarajan <vthiagar@codeaurora.org>
      Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
      caee728a
  3. 14 3月, 2018 1 次提交
    • R
      ath10k: dma unmap mgmt tx buffer if wmi cmd send fails · 38a1390e
      Rakesh Pillai 提交于
      WCN3990 sends mgmt frames by reference via WMI.
      The host dma maps the mgmt frame and sends the physical
      address to the firmware in the wmi command. Since the
      dma mapping is done in the gen_mgmt_tx and if the wmi
      command send fails, the corresponding mgmt frame is
      not being dma unmapped.
      
      Fix the missing dma unmapping of mgmt tx frame when
      wmi command sending fails for mgmt tx by reference
      via WMI. The already exisiting mgmt tx using copy by
      value does not need such dma unmapping.
      Add a separate wmi-tlv op for mgmt tx via ref, which
      takes care of unmapping the dma address, in case of
      wmi command sending failure.
      Signed-off-by: NRakesh Pillai <pillair@codeaurora.org>
      Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
      38a1390e
  4. 28 2月, 2018 2 次提交
  5. 26 2月, 2018 1 次提交
  6. 08 2月, 2018 1 次提交
    • R
      Revert "ath10k: add sanity check to ie_len before parsing fw/board ie" · 9ce8b24a
      Ryan Hsu 提交于
      This reverts commit 9ed4f916.
      
      The commit introduced a regression that over read the ie with
      the padding.
      
      - the expected IE information
      
      ath10k_pci 0000:03:00.0: found firmware features ie (1 B)
      ath10k_pci 0000:03:00.0: Enabling feature bit: 6
      ath10k_pci 0000:03:00.0: Enabling feature bit: 7
      ath10k_pci 0000:03:00.0: features
      ath10k_pci 0000:03:00.0: 00000000: c0 00 00 00 00 00 00 00
      
      - the wrong IE with padding is read (0x77)
      
      ath10k_pci 0000:03:00.0: found firmware features ie (4 B)
      ath10k_pci 0000:03:00.0: Enabling feature bit: 6
      ath10k_pci 0000:03:00.0: Enabling feature bit: 7
      ath10k_pci 0000:03:00.0: Enabling feature bit: 8
      ath10k_pci 0000:03:00.0: Enabling feature bit: 9
      ath10k_pci 0000:03:00.0: Enabling feature bit: 10
      ath10k_pci 0000:03:00.0: Enabling feature bit: 12
      ath10k_pci 0000:03:00.0: Enabling feature bit: 13
      ath10k_pci 0000:03:00.0: Enabling feature bit: 14
      ath10k_pci 0000:03:00.0: Enabling feature bit: 16
      ath10k_pci 0000:03:00.0: Enabling feature bit: 17
      ath10k_pci 0000:03:00.0: Enabling feature bit: 18
      ath10k_pci 0000:03:00.0: features
      ath10k_pci 0000:03:00.0: 00000000: c0 77 07 00 00 00 00 00
      Tested-by: NMike Lothian <mike@fireburn.co.uk>
      Signed-off-by: NRyan Hsu <ryanhsu@codeaurora.org>
      Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
      9ce8b24a
  7. 07 2月, 2018 3 次提交
    • Y
      ath10k: fix kernel panic issue during pci probe · 50e79e25
      Yu Wang 提交于
      If device gone during chip reset, ar->normal_mode_fw.board is not
      initialized, but ath10k_debug_print_hwfw_info() will try to access its
      member, which will cause 'kernel NULL pointer' issue. This was found
      using a faulty device (pci link went down sometimes) in a random
      insmod/rmmod/other-op test.
      To fix it, check ar->normal_mode_fw.board before accessing the member.
      
      pci 0000:02:00.0: BAR 0: assigned [mem 0xf7400000-0xf75fffff 64bit]
      ath10k_pci 0000:02:00.0: enabling device (0000 -> 0002)
      ath10k_pci 0000:02:00.0: pci irq msi oper_irq_mode 2 irq_mode 0 reset_mode 0
      ath10k_pci 0000:02:00.0: failed to read device register, device is gone
      ath10k_pci 0000:02:00.0: failed to wait for target init: -5
      ath10k_pci 0000:02:00.0: failed to warm reset: -5
      ath10k_pci 0000:02:00.0: firmware crashed during chip reset
      ath10k_pci 0000:02:00.0: firmware crashed! (uuid 5d018951-b8e1-404a-8fde-923078b4423a)
      ath10k_pci 0000:02:00.0: (null) target 0x00000000 chip_id 0x00340aff sub 0000:0000
      ath10k_pci 0000:02:00.0: kconfig debug 1 debugfs 1 tracing 1 dfs 1 testmode 1
      ath10k_pci 0000:02:00.0: firmware ver  api 0 features  crc32 00000000
      ...
      BUG: unable to handle kernel NULL pointer dereference at 00000004
      ...
      Call Trace:
       [<fb4e7882>] ath10k_print_driver_info+0x12/0x20 [ath10k_core]
       [<fb62b7dd>] ath10k_pci_fw_crashed_dump+0x6d/0x4d0 [ath10k_pci]
       [<fb629f07>] ? ath10k_pci_sleep.part.19+0x57/0xc0 [ath10k_pci]
       [<fb62c8ee>] ath10k_pci_hif_power_up+0x14e/0x1b0 [ath10k_pci]
       [<c10477fb>] ? do_page_fault+0xb/0x10
       [<fb4eb934>] ath10k_core_register_work+0x24/0x840 [ath10k_core]
       [<c18a00d8>] ? netlbl_unlhsh_remove+0x178/0x410
       [<c10477f0>] ? __do_page_fault+0x480/0x480
       [<c1068e44>] process_one_work+0x114/0x3e0
       [<c1069d07>] worker_thread+0x37/0x4a0
       [<c106e294>] kthread+0xa4/0xc0
       [<c1069cd0>] ? create_worker+0x180/0x180
       [<c106e1f0>] ? kthread_park+0x50/0x50
       [<c18ab4f7>] ret_from_fork+0x1b/0x28
       Code: 78 80 b8 50 09 00 00 00 75 5d 8d 75 94 c7 44 24 08 aa d7 52 fb c7 44 24 04 64 00 00 00
       89 34 24 e8 82 52 e2 c5 8b 83 dc 08 00 00 <8b> 50 04 8b 08 31 c0 e8 20 57 e3 c5 89 44 24 10 8b 83 58 09 00
       EIP: [<fb4e7754>]-
       ath10k_debug_print_board_info+0x34/0xb0 [ath10k_core]
       SS:ESP 0068:f4921d90
       CR2: 0000000000000004
      Signed-off-by: NYu Wang <yyuwang@codeaurora.org>
      Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
      50e79e25
    • T
      ath10k: add support for Ubiquiti rebranded QCA988X v2 · 34f1cb33
      Tobias Schramm 提交于
      Some modern Ubiquiti devices contain a rebranded QCA988X rev2 with
      a custom Ubiquiti vendor and device id. This patch adds support for
      those devices, treating them as a QCA988X v2.
      Signed-off-by: NTobias Schramm <tobleminer@gmail.com>
      [kvalo@codeaurora.org: rebase, add missing fields in hw_params, fix a long line in pci.c:61]
      Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
      34f1cb33
    • Y
      ath10k: correct the length of DRAM dump for QCA6174 hw3.x/QCA9377 hw1.1 · 0a7fe718
      Yu Wang 提交于
      The length of DRAM dump for QCA6174 hw3.0/hw3.2 and QCA9377 hw1.1
      are less than the actual value, some coredump contents are missed.
      To fix it, change the length from 0x90000 to 0xa8000.
      
      Fixes: 703f261d ("ath10k: add memory dump support for QCA6174/QCA9377")
      Signed-off-by: NYu Wang <yyuwang@codeaurora.org>
      Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
      0a7fe718
  8. 16 1月, 2018 4 次提交
  9. 09 1月, 2018 3 次提交
  10. 27 12月, 2017 12 次提交