ath10k driver failing with wireless pcie card on TX1

I have built and installed the ath10k kernel driver on a Jetson TX1 (running a custom L4T r28.1 with kernel based on 4.4) dev kit by adding the following configuration:

# enabling the ath10k wireless driver
CONFIG_ATH_CARDS=m
CONFIG_ATH_DEBUG=y
CONFIG_ATH_TRACEPOINTS=y
CONFIG_ATH10K=m
CONFIG_ATH10K_PCI=m
CONFIG_ATH10K_DEBUG=y
CONFIG_ATH10K_DEBUGFS=y
CONFIG_ATH10K_TRACING=y

# the mac80211 library is a dependency for the atheros driver
CONFIG_EXPERT=y
CONFIG_MAC80211=m
CONFIG_MAC80211_HAS_RC=y
CONFIG_MAC80211_RC_MINSTREL=y
CONFIG_MAC80211_RC_MINSTREL_HT=y
CONFIG_MAC80211_RC_MINSTREL_VHT=y
CONFIG_MAC80211_RC_DEFAULT_MINSTREL=y
CONFIG_MAC80211_RC_DEFAULT="minstrel_ht"
# CONFIG_MAC80211_MESH is not set
# CONFIG_MAC80211_LEDS is not set
CONFIG_MAC80211_DEBUGFS=y
CONFIG_MAC80211_MESSAGE_TRACING=y
CONFIG_MAC80211_DEBUG_MENU=y
# CONFIG_MAC80211_NOINLINE is not set
# CONFIG_MAC80211_VERBOSE_DEBUG is not set
# CONFIG_MAC80211_MLME_DEBUG is not set
# CONFIG_MAC80211_STA_DEBUG is not set
# CONFIG_MAC80211_HT_DEBUG is not set
# CONFIG_MAC80211_OCB_DEBUG is not set
# CONFIG_MAC80211_IBSS_DEBUG is not set
# CONFIG_MAC80211_PS_DEBUG is not set
# CONFIG_MAC80211_TDLS_DEBUG is not set
# CONFIG_MAC80211_DEBUG_COUNTERS is not set
CONFIG_MAC80211_STA_HASH_MAX_SIZE=0
# CONFIG_MAC80211_HWSIM is not set

I’m using a QCA6174 based pci wireless card and have downloaded the firmware here:

Source: ath10k-firmware/QCA6174/hw3.0 at master · kvalo/ath10k-firmware · GitHub
- firmware-4.bin_WLAN.RM.2.0-00180-QCARMSWPZ-1
- board.bin

I have added the following kernel driver options to get the driver to work properly:

echo “options ath10k_core skip_otp=y debug_mask=0x16” | sudo tee /etc/modprobe.d/ath10k.conf

I have copied the firmwares mentioned above to the following locations:

  • firmware-4.bin_WLAN.RM.2.0-00180-QCARMSWPZ-1 —> /lib/firmware/ath10k/QCA6174/hw3.0/firmware-5.bin
  • board.bin —> /lib/firmware/ath10k/QCA6174/hw3.0/board.bin

The output of lspci is:

00:01.0 PCI bridge: NVIDIA Corporation Device 0fae (rev a1) (prog-if 00 [Normal decode])
	Flags: bus master, fast devsel, latency 0, IRQ 369
	Bus: primary=00, secondary=01, subordinate=01, sec-latency=0
	Memory behind bridge: 13000000-131fffff
	Capabilities: [40] Subsystem: NVIDIA Corporation Device 0000
	Capabilities: [48] Power Management version 3
	Capabilities: [50] MSI: Enable- Count=1/2 Maskable- 64bit+
	Capabilities: [60] HyperTransport: MSI Mapping Enable- Fixed-
	Capabilities: [80] Express Root Port (Slot+), MSI 00
	Capabilities: [100] Advanced Error Reporting
	Capabilities: [140] L1 PM Substates
	Kernel driver in use: pcieport

01:00.0 Network controller: Qualcomm Atheros QCA6174 802.11ac Wireless Network Adapter (rev 32)
	Flags: bus master, fast devsel, latency 0, IRQ 439
	Memory at 13000000 (64-bit, non-prefetchable) 
	Capabilities: [40] Power Management version 3
	Capabilities: [50] MSI: Enable+ Count=1/8 Maskable+ 64bit-
	Capabilities: [70] Express Endpoint, MSI 00
	Capabilities: [100] Advanced Error Reporting
	Capabilities: [148] Virtual Channel
	Capabilities: [168] Device Serial Number 00-00-00-00-00-00-00-00
	Capabilities: [178] Latency Tolerance Reporting
	Capabilities: [180] L1 PM Substates
	Kernel driver in use: ath10k_pci
	Kernel modules: ath10k_pci

so I do know the kernel sees the wireless card via PCIE; however, the wlan0 interface never gets brought up, and it seems to be due to some sort of pcie errors. Here is relevant kernel log output:

[  +2.304536] ath10k_pci 0000:01:00.0: Target ready! transmit resources: 2 size:1792
[  +0.000010] ath10k_pci 0000:01:00.0: ath10k_htc_build_tx_ctrl_skb: skb ffffffc079983200
[  +0.000060] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 0 skb ffffffc079983200
[  +0.000055] ath10k_pci 0000:01:00.0: HTC Service HTT Data connect response: status: 0x0, assigned ep: 0x1
[  +0.000007] ath10k_pci 0000:01:00.0: ath10k_htc_build_tx_ctrl_skb: skb ffffffc079983900
[  +0.000054] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 0 skb ffffffc079983900
[  +0.000055] ath10k_pci 0000:01:00.0: HTC Service WMI connect response: status: 0x0, assigned ep: 0x2
[  +0.000007] ath10k_pci 0000:01:00.0: ath10k_htc_build_tx_ctrl_skb: skb ffffffc079983a00
[  +0.000004] ath10k_pci 0000:01:00.0: HTC is using TX credit flow control
[  +0.000055] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 0 skb ffffffc079983a00
[  +0.000382] ath10k_pci 0000:01:00.0: htc rx completion ep 2 skb ffffffc0f42e8900
[  +0.000057] ath10k_pci 0000:01:00.0: wmi tlv abi 0x01000000 ?= 0x01000000, 0x5f414351 ?= 0x5f414351, 0x00004c4d ?= 0x00004c4d, 0x00000000 ?= 0x00000000, 0x00000000 ?= 0x00000000
[  +0.000008] ath10k_pci 0000:01:00.0: wmi svc: 00000000: 0d 00 00 00 07 00 00 00 0f 00 00 00 03 00 00 00  ................
[  +0.000004] ath10k_pci 0000:01:00.0: wmi svc: 00000010: 0f 00 00 00 0f 00 00 00 0b 00 00 00 0f 00 00 00  ................
[  +0.000004] ath10k_pci 0000:01:00.0: wmi svc: 00000020: 0b 00 00 00 0b 00 00 00 00 00 00 00 0a 00 00 00  ................
[  +0.000003] ath10k_pci 0000:01:00.0: wmi svc: 00000030: 00 00 00 00 04 00 00 00 0f 00 00 00 0f 00 00 00  ................
[  +0.000003] ath10k_pci 0000:01:00.0: wmi svc: 00000040: 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
[  +0.000004] ath10k_pci 0000:01:00.0: wmi svc: 00000050: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
[  +0.000003] ath10k_pci 0000:01:00.0: wmi svc: 00000060: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
[  +0.000003] ath10k_pci 0000:01:00.0: wmi svc: 00000070: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
[  +0.000008] ath10k_pci 0000:01:00.0: wmi event service ready min_tx_power 0x0000003f max_tx_power 0x0000003f ht_cap 0x0000085b vht_cap 0x339011b2 sw_ver0 0x01000000 sw_ver1 0x0000008f fw_build 0x200700b4 phy_capab 0x00000003 num_rf_chains 0x00000002 eeprom_rd 0x00000000 num_mem_reqs 0x00000000
[  +0.000042] ath10k_pci 0000:01:00.0: wmi tlv init
[  +0.000006] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 1)
[  +0.000035] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079983100
[  +0.016722] ath10k_pci 0000:01:00.0: htc rx completion ep 2 skb ffffffc0f42e8f00
[  +0.000019] ath10k_pci 0000:01:00.0: wmi event ready sw_version 16777216 abi_version 143 mac_addr b0:41:1d:16:07:25 status 0
[  +0.000008] ath10k_pci 0000:01:00.0: htc rx completion ep 2 skb ffffffc0f42e8b00
[  +0.000006] ath10k_pci 0000:01:00.0: wmi tlv diag event len 1288
[  +0.001679] ath10k_pci 0000:01:00.0: htc ep 2 got 1 credits (total 2)
[  +0.014318] ath10k_pci 0000:01:00.0: htc rx completion ep 1 skb ffffffc073148600
[  +0.000078] ath10k_pci 0000:01:00.0: wmi tlv pktlog disable
[  +0.000007] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 1)
[  +0.000023] ath10k_pci 0000:01:00.0: wmi tlv pdev set param
[  +0.000003] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000013] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0300
[  +0.000010] ath10k_pci 0000:01:00.0: wmi tlv pdev set param
[  +0.000016] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0900
[  +0.000364] ath10k_pci 0000:01:00.0: htc ep 2 got 1 credits (total 1)
[  +0.000019] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000010] ath10k_pci 0000:01:00.0: wmi tlv adaptive qcs 1
[  +0.000017] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0100
[  +0.000312] ath10k_pci 0000:01:00.0: htc ep 2 got 2 credits (total 2)
[  +0.000016] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 1)
[  +0.000013] ath10k_pci 0000:01:00.0: wmi tlv pdev set param
[  +0.000005] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000012] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0e00
[  +0.000013] ath10k_pci 0000:01:00.0: wmi tlv pdev set param
[  +0.000016] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0700
[  +0.000301] ath10k_pci 0000:01:00.0: htc ep 2 got 1 credits (total 1)
[  +0.000015] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000012] ath10k_pci 0000:01:00.0: wmi tlv pdev set param
[  +0.000017] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0c00
[  +0.005661] ath10k_pci 0000:01:00.0: htc ep 2 got 2 credits (total 2)
[  +0.000056] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 1)
[  +0.000013] ath10k_pci 0000:01:00.0: wmi tlv pdev set param
[  +0.000004] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000011] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0800
[  +0.000011] ath10k_pci 0000:01:00.0: wmi tlv pdev set param
[  +0.000017] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0600
[  +0.000294] ath10k_pci 0000:01:00.0: htc ep 2 got 1 credits (total 1)
[  +0.000052] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000030] ath10k_pci 0000:01:00.0: mac channel [0/26] freq 2412 maxpower 40 regpower 40 antenna 0 mode 1
[  +0.000005] ath10k_pci 0000:01:00.0: mac channel [1/26] freq 2417 maxpower 40 regpower 40 antenna 0 mode 1
[  +0.000004] ath10k_pci 0000:01:00.0: mac channel [2/26] freq 2422 maxpower 40 regpower 40 antenna 0 mode 1
[  +0.000003] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0f00
[  +0.000002] ath10k_pci 0000:01:00.0: mac channel [3/26] freq 2427 maxpower 40 regpower 40 antenna 0 mode 1
[  +0.000003] ath10k_pci 0000:01:00.0: mac channel [4/26] freq 2432 maxpower 40 regpower 40 antenna 0 mode 1
[  +0.000003] ath10k_pci 0000:01:00.0: mac channel [5/26] freq 2437 maxpower 40 regpower 40 antenna 0 mode 1
[  +0.000003] ath10k_pci 0000:01:00.0: mac channel [6/26] freq 2442 maxpower 40 regpower 40 antenna 0 mode 1
[  +0.000002] ath10k_pci 0000:01:00.0: mac channel [7/26] freq 2447 maxpower 40 regpower 40 antenna 0 mode 1
[  +0.000003] ath10k_pci 0000:01:00.0: mac channel [8/26] freq 2452 maxpower 40 regpower 40 antenna 0 mode 1
[  +0.000002] ath10k_pci 0000:01:00.0: mac channel [9/26] freq 2457 maxpower 40 regpower 40 antenna 0 mode 1
[  +0.000003] ath10k_pci 0000:01:00.0: mac channel [10/26] freq 2462 maxpower 40 regpower 40 antenna 0 mode 1
[  +0.000002] ath10k_pci 0000:01:00.0: mac channel [11/26] freq 2467 maxpower 40 regpower 40 antenna 0 mode 1
[  +0.000003] ath10k_pci 0000:01:00.0: mac channel [12/26] freq 5180 maxpower 60 regpower 60 antenna 0 mode 0
[  +0.000002] ath10k_pci 0000:01:00.0: mac channel [13/26] freq 5200 maxpower 60 regpower 60 antenna 0 mode 0
[  +0.000003] ath10k_pci 0000:01:00.0: mac channel [14/26] freq 5220 maxpower 60 regpower 60 antenna 0 mode 0
[  +0.000002] ath10k_pci 0000:01:00.0: mac channel [15/26] freq 5240 maxpower 60 regpower 60 antenna 0 mode 0
[  +0.000003] ath10k_pci 0000:01:00.0: mac channel [16/26] freq 5260 maxpower 60 regpower 60 antenna 0 mode 0
[  +0.000002] ath10k_pci 0000:01:00.0: mac channel [17/26] freq 5280 maxpower 60 regpower 60 antenna 0 mode 0
[  +0.000003] ath10k_pci 0000:01:00.0: mac channel [18/26] freq 5300 maxpower 60 regpower 60 antenna 0 mode 0
[  +0.000002] ath10k_pci 0000:01:00.0: mac channel [19/26] freq 5320 maxpower 60 regpower 60 antenna 0 mode 0
[  +0.000003] ath10k_pci 0000:01:00.0: mac channel [20/26] freq 5720 maxpower 60 regpower 60 antenna 0 mode 0
[  +0.000002] ath10k_pci 0000:01:00.0: mac channel [21/26] freq 5745 maxpower 60 regpower 60 antenna 0 mode 0
[  +0.000003] ath10k_pci 0000:01:00.0: mac channel [22/26] freq 5765 maxpower 60 regpower 60 antenna 0 mode 0
[  +0.000002] ath10k_pci 0000:01:00.0: mac channel [23/26] freq 5785 maxpower 60 regpower 60 antenna 0 mode 0
[  +0.000002] ath10k_pci 0000:01:00.0: mac channel [24/26] freq 5805 maxpower 60 regpower 60 antenna 0 mode 0
[  +0.000003] ath10k_pci 0000:01:00.0: mac channel [25/26] freq 5825 maxpower 60 regpower 60 antenna 0 mode 0
[  +0.000003] ath10k_pci 0000:01:00.0: wmi tlv scan chan list
[  +0.000255] ath10k_pci 0000:01:00.0: htc ep 2 got 2 credits (total 2)
[  +0.000016] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 1)
[  +0.000035] ath10k_pci 0000:01:00.0: wmi tlv pdev set rd
[  +0.000004] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000011] ath10k_pci 0000:01:00.0: mac create vdev 0 map f
[  +0.000019] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0200
[  +0.000007] ath10k_pci 0000:01:00.0: mac vdev create 0 (add interface) type 1 subtype 0 bcnmode single-buf
[  +0.000002] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0000
[  +0.000004] ath10k_pci 0000:01:00.0: wmi tlv vdev create
[  +0.000341] ath10k_pci 0000:01:00.0: htc ep 2 got 1 credits (total 1)
[  +0.000016] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000014] ath10k_pci 0000:01:00.0: wmi tlv vdev set param
[  +0.000016] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0200
[  +0.000436] ath10k_pci 0000:01:00.0: htc rx completion ep 1 skb ffffffc073148a00
[  +0.000011] ath10k_pci 0000:01:00.0: htc rx completion ep 1 skb ffffffc073148200
[  +0.000008] ath10k_pci 0000:01:00.0: htc ep 2 got 2 credits (total 2)
[  +0.000011] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 1)
[  +0.000010] ath10k_pci 0000:01:00.0: wmi tlv vdev set param
[  +0.000004] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000013] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0f00
[  +0.000010] ath10k_pci 0000:01:00.0: wmi tlv peer create
[  +0.000016] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0600
[  +0.000290] ath10k_pci 0000:01:00.0: htc ep 2 got 1 credits (total 1)
[  +0.000016] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000026] ath10k_pci 0000:01:00.0: wmi tlv pdev set param
[  +0.000017] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0800
[  +0.000323] ath10k_pci 0000:01:00.0: htc ep 2 got 2 credits (total 2)
[  +0.000128] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 1)
[  +0.000009] ath10k_pci 0000:01:00.0: wmi tlv vdev set param
[  +0.000004] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000007] ath10k_pci 0000:01:00.0: wmi tlv vdev set param
[  +0.000012] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0c00
[  +0.000009] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0700
[  +0.000159] ath10k_pci 0000:01:00.0: htc ep 2 got 1 credits (total 1)
[  +0.000044] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000012] ath10k_pci 0000:01:00.0: wmi tlv vdev set param
[  +0.000016] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0e00
[  +0.000179] ath10k_pci 0000:01:00.0: htc ep 2 got 2 credits (total 2)
[  +0.000046] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 1)
[  +0.000013] ath10k_pci 0000:01:00.0: wmi tlv vdev set param
[  +0.000005] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000009] ath10k_pci 0000:01:00.0: mac txpower 0
[  +0.000003] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0100
[  +0.000004] ath10k_pci 0000:01:00.0: wmi tlv pdev set param
[  +0.000016] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0500
[  +0.000149] ath10k_pci 0000:01:00.0: htc ep 2 got 1 credits (total 1)
[  +0.000046] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000012] ath10k_pci 0000:01:00.0: wmi tlv pdev set param
[  +0.000017] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0400
[  +0.000312] ath10k_pci 0000:01:00.0: htc ep 2 got 2 credits (total 2)
[  +0.000012] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 1)
[  +0.000013] ath10k_pci 0000:01:00.0: mac monitor recalc started? 0 needed? 0 allowed? 1
[  +0.000005] ath10k_pci 0000:01:00.0: mac vdev 0 cts_prot 0
[  +0.000004] ath10k_pci 0000:01:00.0: wmi tlv vdev set param
[  +0.000003] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0900
[  +0.000004] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000008] ath10k_pci 0000:01:00.0: wmi tlv vdev set param
[  +0.000017] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0300
[  +0.000151] ath10k_pci 0000:01:00.0: htc ep 2 got 1 credits (total 1)
[  +0.000010] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000009] ath10k_pci 0000:01:00.0: mac vdev 0 slot_time 1
[  +0.000004] ath10k_pci 0000:01:00.0: wmi tlv vdev set param
[  +0.000013] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0a00
[  +0.000080] ath10k_pci 0000:01:00.0: htc ep 2 got 2 credits (total 2)
[  +0.000011] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 1)
[  +0.000008] ath10k_pci 0000:01:00.0: mac vdev 0 preamble 1n
[  +0.000003] ath10k_pci 0000:01:00.0: wmi tlv vdev set param
[  +0.000007] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000007] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0300
[  +0.000003] ath10k_pci 0000:01:00.0: wmi tlv vdev wmm conf
[  +0.000022] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0900
[  +0.000167] ath10k_pci 0000:01:00.0: htc ep 2 got 1 credits (total 1)
[  +0.000011] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000009] ath10k_pci 0000:01:00.0: wmi tlv vdev wmm conf
[  +0.000019] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0400
[  +0.000143] ath10k_pci 0000:01:00.0: htc ep 2 got 2 credits (total 2)
[  +0.000010] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 1)
[  +0.000009] ath10k_pci 0000:01:00.0: wmi tlv vdev wmm conf
[  +0.000004] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000007] ath10k_pci 0000:01:00.0: wmi tlv vdev wmm conf
[  +0.000015] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0500
[  +0.000009] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0100
[  +0.000225] ath10k_pci 0000:01:00.0: htc ep 2 got 1 credits (total 1)
[  +0.000011] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000010] ath10k_pci 0000:01:00.0: mac monitor recalc started? 0 needed? 0 allowed? 1
[  +0.000013] ath10k_pci 0000:01:00.0: mac monitor recalc started? 0 needed? 0 allowed? 1
[  +0.000006] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc079ab0e00
[  +0.000027] ath10k_pci 0000:01:00.0: mac monitor recalc started? 0 needed? 0 allowed? 1
[  +0.000030] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
[  +0.000157] ath10k_pci 0000:01:00.0: htc ep 2 got 2 credits (total 2)
[  +0.000049] ath10k_pci 0000:01:00.0: mac monitor recalc started? 0 needed? 0 allowed? 1
[  +0.973115] ath10k_pci 0000:01:00.0: htc rx completion ep 2 skb ffffffc0f42e8400
[  +0.000012] ath10k_pci 0000:01:00.0: wmi tlv diag event len 496
[  +4.076546] ath10k_pci 0000:01:00.0: wmi tlv peer delete
[  +0.000011] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 1)
[  +0.002505] ath10k_pci 0000:01:00.0: mac vdev 0 delete (remove interface)
[  +0.000005] ath10k_pci 0000:01:00.0: wmi tlv vdev delete
[  +0.000005] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000016] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc07ccd7800
[  +0.000027] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc07ccd7f00
[  +0.000146] ath10k_pci 0000:01:00.0: htc ep 2 got 1 credits (total 1)
[  +0.000209] ath10k_pci 0000:01:00.0: htc rx completion ep 1 skb ffffffc0f1371f00
[  +0.000034] ath10k_pci 0000:01:00.0: htc rx completion ep 1 skb ffffffc00eb0cb00
[  +0.000044] ath10k_pci 0000:01:00.0: mac monitor recalc started? 0 needed? 0 allowed? 1
[  +0.000024] ath10k_pci 0000:01:00.0: wmi tlv pktlog disable
[  +0.000006] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 0)
[  +0.000011] ath10k_pci 0000:01:00.0: wmi tlv pdev suspend
[  +0.000018] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc098f6ea00
[  +0.000057] ath10k_pci 0000:01:00.0: htc ep 2 got 2 credits (total 2)
[  +0.000014] ath10k_pci 0000:01:00.0: htc ep 2 consumed 1 credits (total 1)
[  +0.000031] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 2 skb ffffffc0df141100
[  +0.000266] ath10k_pci 0000:01:00.0: htc rx completion ep 2 skb ffffffc0f2ce7900
[  +0.000015] ath10k_pci 0000:01:00.0: wmi tlv diag event len 32
[  +0.000035] ath10k_pci 0000:01:00.0: htc ep 2 got 1 credits (total 2)
[  +0.191704] ath10k_pci 0000:01:00.0: failed to read diag value at 0x4008cc: -12
[  +0.000009] ath10k_pci 0000:01:00.0: Failed to get option val: -12
[  +0.000008] ath10k_pci 0000:01:00.0: failed to setup init config: -12
[  +0.000072] ath10k_pci 0000:01:00.0: Could not init hif: -12
[  +5.738803] ath10k_pci 0000:01:00.0: failed to read diag value at 0x4008f8: -12
[  +0.000008] ath10k_pci 0000:01:00.0: Failed to get pcie state addr: -12
[  +0.000007] ath10k_pci 0000:01:00.0: failed to setup init config: -12
[  +0.000072] ath10k_pci 0000:01:00.0: Could not init hif: -12
[  +5.835812] ath10k_pci 0000:01:00.0: failed to read diag value at 0x4008f8: -12
[  +0.000009] ath10k_pci 0000:01:00.0: Failed to get pcie state addr: -12
[  +0.000008] ath10k_pci 0000:01:00.0: failed to setup init config: -12
[  +0.000072] ath10k_pci 0000:01:00.0: Could not init hif: -12
[Apr10 12:07] ath10k_pci 0000:01:00.0: failed to read diag value at 0x4008f8: -12
[  +0.000008] ath10k_pci 0000:01:00.0: Failed to get pcie state addr: -12
[  +0.000007] ath10k_pci 0000:01:00.0: failed to setup init config: -12
[  +0.000072] ath10k_pci 0000:01:00.0: Could not init hif: -12
[  +5.507912] ath10k_pci 0000:01:00.0: failed to read diag value at 0x4008f8: -12
[  +0.000007] ath10k_pci 0000:01:00.0: Failed to get pcie state addr: -12
[  +0.000007] ath10k_pci 0000:01:00.0: failed to setup init config: -12
[  +0.000073] ath10k_pci 0000:01:00.0: Could not init hif: -12
[  +5.739913] ath10k_pci 0000:01:00.0: failed to read diag value at 0x4008f8: -12
[  +0.000007] ath10k_pci 0000:01:00.0: Failed to get pcie state addr: -12
[  +0.000007] ath10k_pci 0000:01:00.0: failed to setup init config: -12
[  +0.000072] ath10k_pci 0000:01:00.0: Could not init hif: -12
[  +5.511919] ath10k_pci 0000:01:00.0: failed to read diag value at 0x4008f8: -12
[  +0.000008] ath10k_pci 0000:01:00.0: Failed to get pcie state addr: -12
[  +0.000007] ath10k_pci 0000:01:00.0: failed to setup init config: -12
[  +0.000072] ath10k_pci 0000:01:00.0: Could not init hif: -12
[  +5.735904] ath10k_pci 0000:01:00.0: failed to read diag value at 0x4008f8: -12
[  +0.000008] ath10k_pci 0000:01:00.0: Failed to get pcie state addr: -12
[  +0.000007] ath10k_pci 0000:01:00.0: failed to setup init config: -12
[  +0.000072] ath10k_pci 0000:01:00.0: Could not init hif: -12
[  +5.511916] ath10k_pci 0000:01:00.0: failed to read diag value at 0x4008f8: -12
[  +0.000009] ath10k_pci 0000:01:00.0: Failed to get pcie state addr: -12
[  +0.000007] ath10k_pci 0000:01:00.0: failed to setup init config: -12
[  +0.000072] ath10k_pci 0000:01:00.0: Could not init hif: -12

There are also other times where I see the following before the failure message:

[  +0.999340] smmu_dump_pagetable(): fault_address=0x0000000072c26000 pa=0xffffffffffffffff bytes=ffffffffffffffff #pte=0 in L2
[  +0.000012] mc-err: (0) csw_afiw: EMEM decode error on PDE or PTE entry
[  +0.000007] mc-err:   status = 0x60010031; addr = 0x72c26000
[  +0.000006] mc-err:   secure: no, access-type: write, SMMU fault: nr-nw-s
[  +0.000020] smmu_dump_pagetable(): fault_address=0x0000000072c26000 pa=0xffffffffffffffff bytes=ffffffffffffffff #pte=0 in L2
[  +0.000006] mc-err: (0) csw_afiw: EMEM decode error on PDE or PTE entry
[  +0.000005] mc-err:   status = 0x60010031; addr = 0x72c26000
[  +0.000005] mc-err:   secure: no, access-type: write, SMMU fault: nr-nw-s
[  +0.000015] smmu_dump_pagetable(): fault_address=0x0000000072c26000 pa=0xffffffffffffffff bytes=ffffffffffffffff #pte=0 in L2
[  +0.000005] mc-err: (0) csw_afiw: EMEM decode error on PDE or PTE entry
[  +0.000005] mc-err:   status = 0x60010031; addr = 0x72c26000
[  +0.000005] mc-err:   secure: no, access-type: write, SMMU fault: nr-nw-s
[  +0.000014] smmu_dump_pagetable(): fault_address=0x0000000072c26000 pa=0xffffffffffffffff bytes=ffffffffffffffff #pte=0 in L2
[  +0.000005] mc-err: (0) csw_afiw: EMEM decode error on PDE or PTE entry
[  +0.000005] mc-err:   status = 0x60010031; addr = 0x72c26000
[  +0.000004] mc-err:   secure: no, access-type: write, SMMU fault: nr-nw-s
[  +0.000012] mc-err: Too many MC errors; throttling prints
[  +1.003110] ath10k_pci 0000:01:00.0: failed to receive control response completion, polling..
[  +0.000060] ath10k_pci 0000:01:00.0: Target ready! transmit resources: 2 size:1792
[  +0.000007] ath10k_pci 0000:01:00.0: ath10k_htc_build_tx_ctrl_skb: skb ffffffc0f433c700
[  +0.000084] smmu_dump_pagetable(): fault_address=0x0000000072c26000 pa=0xffffffffffffffff bytes=ffffffffffffffff #pte=0 in L2
[  +0.000009] mc-err: (0) csw_afiw: EMEM decode error on PDE or PTE entry
[  +0.000004] mc-err:   status = 0x60010031; addr = 0x72c26000
[  +0.000005] mc-err:   secure: no, access-type: write, SMMU fault: nr-nw-s
[  +0.000015] smmu_dump_pagetable(): fault_address=0x0000000072c26000 pa=0xffffffffffffffff bytes=ffffffffffffffff #pte=0 in L2
[  +0.000005] mc-err: (0) csw_afiw: EMEM decode error on PDE or PTE entry
[  +0.000004] mc-err:   status = 0x60010031; addr = 0x72c26000
[  +0.000004] mc-err:   secure: no, access-type: write, SMMU fault: nr-nw-s
[  +0.000024] smmu_dump_pagetable(): fault_address=0x0000000072c26000 pa=0xffffffffffffffff bytes=ffffffffffffffff #pte=0 in L2
[  +0.000005] mc-err: (0) csw_afiw: EMEM decode error on PDE or PTE entry
[  +0.000003] mc-err:   status = 0x60010031; addr = 0x72c26000
[  +0.000004] mc-err:   secure: no, access-type: write, SMMU fault: nr-nw-s
[  +0.000022] smmu_dump_pagetable(): fault_address=0x0000000072c26000 pa=0xffffffffffffffff bytes=ffffffffffffffff #pte=0 in L2
[  +0.000004] mc-err: (0) csw_afiw: EMEM decode error on PDE or PTE entry
[  +0.000004] mc-err:   status = 0x60010031; addr = 0x72c26000
[  +0.000003] mc-err:   secure: no, access-type: write, SMMU fault: nr-nw-s
[  +0.000019] mc-err: Too many MC errors; throttling prints
[  +0.999560] ath10k_pci 0000:01:00.0: Service connect timeout
[  +0.000011] ath10k_pci 0000:01:00.0: failed to connect htt (-110)
[  +0.066201] ath10k_pci 0000:01:00.0: ath10k_htc_notify_tx_completion: ep 0 skb ffffffc0f433c700
[  +0.002525] ath10k_pci 0000:01:00.0: could not init core (-110)
[  +0.000075] ath10k_pci 0000:01:00.0: could not probe fw (-110)

And more with more verbose debugging output:

[  +5.633112] ath10k_pci 0000:01:00.0: boot hif power up
[  +0.000013] ath10k_pci 0000:01:00.0: boot qca6174 chip reset
[  +0.000005] ath10k_pci 0000:01:00.0: boot cold reset
[  +0.044486] ath10k_pci 0000:01:00.0: boot cold reset complete
[  +0.000008] ath10k_pci 0000:01:00.0: boot waiting target to initialise
[  +0.000007] ath10k_pci 0000:01:00.0: boot target indicator 2
[  +0.000009] ath10k_pci 0000:01:00.0: boot target initialised
[  +0.000004] ath10k_pci 0000:01:00.0: boot warm reset
[  +0.031986] ath10k_pci 0000:01:00.0: boot init ce src ring id 0 entries 16 base_addr ffffff80099a1000
[  +0.000018] ath10k_pci 0000:01:00.0: boot ce dest ring id 1 entries 512 base_addr ffffff80099a3000
[  +0.000015] ath10k_pci 0000:01:00.0: boot ce dest ring id 2 entries 128 base_addr ffffff80099a6000
[  +0.000018] ath10k_pci 0000:01:00.0: boot init ce src ring id 3 entries 32 base_addr ffffff80099a8000
[  +0.000020] ath10k_pci 0000:01:00.0: boot init ce src ring id 4 entries 4096 base_addr ffffff80099aa000
[  +0.000018] ath10k_pci 0000:01:00.0: boot init ce src ring id 7 entries 2 base_addr ffffff80099b4000
[  +0.000015] ath10k_pci 0000:01:00.0: boot ce dest ring id 7 entries 2 base_addr ffffff80099b6000
[  +0.000003] ath10k_pci 0000:01:00.0: boot waiting target to initialise
[  +0.000005] ath10k_pci 0000:01:00.0: boot target indicator 0
[  +0.010008] ath10k_pci 0000:01:00.0: boot target indicator 2
[  +0.000009] ath10k_pci 0000:01:00.0: boot target initialised
[  +0.013875] ath10k_pci 0000:01:00.0: boot init ce src ring id 0 entries 16 base_addr ffffff80099a1000
[  +0.000017] ath10k_pci 0000:01:00.0: boot ce dest ring id 1 entries 512 base_addr ffffff80099a3000
[  +0.000015] ath10k_pci 0000:01:00.0: boot ce dest ring id 2 entries 128 base_addr ffffff80099a6000
[  +0.000017] ath10k_pci 0000:01:00.0: boot init ce src ring id 3 entries 32 base_addr ffffff80099a8000
[  +0.000020] ath10k_pci 0000:01:00.0: boot init ce src ring id 4 entries 4096 base_addr ffffff80099aa000
[  +0.000017] ath10k_pci 0000:01:00.0: boot init ce src ring id 7 entries 2 base_addr ffffff80099b4000
[  +0.000014] ath10k_pci 0000:01:00.0: boot ce dest ring id 7 entries 2 base_addr ffffff80099b6000
[  +0.000003] ath10k_pci 0000:01:00.0: boot waiting target to initialise
[  +0.000005] ath10k_pci 0000:01:00.0: boot target indicator 0
[  +0.010009] ath10k_pci 0000:01:00.0: boot target indicator 2
[  +0.000009] ath10k_pci 0000:01:00.0: boot target initialised
[  +0.000005] ath10k_pci 0000:01:00.0: boot warm reset complete
[  +0.000003] ath10k_pci 0000:01:00.0: boot qca6174 chip reset complete (cold)
[  +0.000019] ath10k_pci 0000:01:00.0: boot init ce src ring id 0 entries 16 base_addr ffffff80099a1000
[  +0.000016] ath10k_pci 0000:01:00.0: boot ce dest ring id 1 entries 512 base_addr ffffff80099a3000
[  +0.000015] ath10k_pci 0000:01:00.0: boot ce dest ring id 2 entries 128 base_addr ffffff80099a6000
[  +0.000018] ath10k_pci 0000:01:00.0: boot init ce src ring id 3 entries 32 base_addr ffffff80099a8000
[  +0.000021] ath10k_pci 0000:01:00.0: boot init ce src ring id 4 entries 4096 base_addr ffffff80099aa000
[  +0.000018] ath10k_pci 0000:01:00.0: boot init ce src ring id 7 entries 2 base_addr ffffff80099b4000
[  +0.000015] ath10k_pci 0000:01:00.0: boot ce dest ring id 7 entries 2 base_addr ffffff80099b6000
[  +0.000007] ath10k_pci 0000:01:00.0: failed dma_alloc_coherent of 4 bytes
[  +0.000005] ath10k_pci 0000:01:00.0: failed to read diag value at 0x4008f8: -12
[  +0.000004] ath10k_pci 0000:01:00.0: Failed to get pcie state addr: -12
[  +0.000006] ath10k_pci 0000:01:00.0: failed to setup init config: -12
[  +0.000072] ath10k_pci 0000:01:00.0: Could not init hif: -12

Any help on how to fix this and get the device running properly?

Also, I’m using the

tegra210-jetson-tx1-p2597-2180-a01-devkit.dtb

device tree configuration and plugging in the card to the only PCIE slot on the dev kit.

I also have verified that the card works by plugging it into my Ubuntu 16.04 workstation and using it successfully as a STA using the ath10k driver + firmwares.

It seems that:

failed to read diag value at 0x4008cc: -12

is due to an ENOMEM error from the dma allocation. Is this actually from a lack of allocation space (https://devtalk.nvidia.com/default/topic/770634/large-coherent-dma-blocks/?offset=5) or is it due to some configuration issue involving DMA? I added in some debug prints and the module is only requesting 4 bytes of memory during these allocations, so I imagine something else is causing this problem…

Code from drivers/net/wireless/ath/ath10k/pci.c:

orig_nbytes = nbytes;
data_buf = (unsigned char *)dma_alloc_coherent(ar->dev,
					       orig_nbytes,
					       &ce_data_base,
					       GFP_ATOMIC);

if (!data_buf) {
	ret = -ENOMEM;
	goto done;
}

Seems that despite only requesting 4 bytes during this allocation the CMA was disabled. The fix seems to be setting the CMA_SIZE_MBYTES to a reasonable non-zero value. Slightly disturbing that a used module that needs CMA does not automatically enable that feature…

That seems to allow the driver to sometimes work, but I will still frequently (about every other boot) get the memory errors mentioned above (reposting here) that prevent it from working:

[    4.031311] serial-tegra 70006200.serial: configured rate out of supported range by -0.29 %
[    4.879170] ath10k_pci 0000:01:00.0: pci hif get default pipe
[    4.879177] ath10k_pci 0000:01:00.0: pci hif map service
[    4.881859] smmu_dump_pagetable(): fault_address=0x00000000728ce000 pa=0xffffffffffffffff bytes=ffffffffffffffff #pte=0 in L2
[    4.881870] mc-err: (0) csw_afiw: EMEM decode error on PDE or PTE entry
[    4.881875] mc-err:   status = 0x60010031; addr = 0x728ce000
[    4.881880] mc-err:   secure: no, access-type: write, SMMU fault: nr-nw-s
[    4.881898] smmu_dump_pagetable(): fault_address=0x00000000728ce000 pa=0xffffffffffffffff bytes=ffffffffffffffff #pte=0 in L2
[    4.881904] mc-err: (0) csw_afiw: EMEM decode error on PDE or PTE entry
[    4.881908] mc-err:   status = 0x60010031; addr = 0x728ce000
[    4.881913] mc-err:   secure: no, access-type: write, SMMU fault: nr-nw-s
[    4.881929] smmu_dump_pagetable(): fault_address=0x00000000728ce000 pa=0xffffffffffffffff bytes=ffffffffffffffff #pte=0 in L2
[    4.881935] mc-err: (0) csw_afiw: EMEM decode error on PDE or PTE entry
[    4.881939] mc-err:   status = 0x60010031; addr = 0x728ce000
[    4.881944] mc-err:   secure: no, access-type: write, SMMU fault: nr-nw-s
[    4.881961] smmu_dump_pagetable(): fault_address=0x00000000728ce000 pa=0xffffffffffffffff bytes=ffffffffffffffff #pte=0 in L2
[    4.881967] mc-err: (0) csw_afiw: EMEM decode error on PDE or PTE entry
[    4.881971] mc-err:   status = 0x60010031; addr = 0x728ce000
[    4.881975] mc-err:   secure: no, access-type: write, SMMU fault: nr-nw-s
[    4.881987] mc-err: Too many MC errors; throttling prints

I do not know anything about this card, but you should know that the firmware has to work with the drivers being used…if the driver and firmware are not meant to work together (usually because they are different versions when multiple versions have been made available over time), then you might get some failures such as this. Research to know if that firmware is used with this kernel series driver (e.g., you likely could not use firmware meant for a 3.x kernel in a 4.x kernel).

There also times when a driver has been ported from 32-bit to 64-bit and DMA was not modified to work with the change in how DMA addresses are used. This is also a good possibility…but I have no way to tell you how to test if this is the case.

Hi ryeager12,

Can you still reproduce this issue after upgraded to R28.2?
Any result can be shared?

Thanks

Hi,

I have similar issues like you had with the ath10k:
https://devtalk.nvidia.com/default/topic/1070115/jetson-tx2/ath10k-driver-problems-with-mikrotik-r11e-5hact/

Any luck?