Anda di halaman 1dari 4

ath9k and ath9k_htc debugging

This page documents the debugging facilities available for ath9k and
ath9k_htc

1. ath9k and ath9k htc debugging


2. Enabling debug
3. Debugfs files
1. Debugfs files for ath9k
2. Debugfs files for ath9k htc

Enabling debug
If you have issues with ath9k or ath9k_htc you can enable debug. You will first
need to enable the Kconfig option (CONFIG_ATH_DEBUG):
Device Drivers --->
[*] Network device support --->
Wireless LAN --->
<M>
Atheros Wireless Cards --->
[*] Atheros wireless debugging

Then you can use the module parameter debug. We cover below the different
available debug levels you can use.
enum ATH_DEBUG {
ATH- DBG- RESET
ATH- DBG- QUEUE
ATH DBG EEPROM
ATH DBG CALIBRATE
ATH DBG INTERRUPT
ATH- DBG- REGULATORY
ATH DBG ANI
ATH DBG XMIT
ATH DBG BEACON
ATH DBG CONFIG
ATH- DBG- FATAL
ATH DBG PS
ATH DBG BTCOEX
ATH DBG WMI

OxOOOOOOOl,
Ox00000002,
Ox00000004,
Ox00000008,
= OxOOOOOOlO,
= Ox00000020,
= Ox00000040,
= Ox00000080,
Ox00000100,
= Ox00000200,
= Ox00000400,
= Ox00000800,
= OxOOOOlOOO,
= Ox00002000,

ATH
ATHATH
ATH
ATH

DBG BSTUCK
DBG- MCI
DBG DFS
DBG WOW
DBG ANY

= Ox00004000,
Ox00008000,
Ox00010000,
Ox00020000,

Oxf fffff ff

};

If you want to debug calibration (Ox00000008) and resets (Ox00000001) for


example you would use (Ox00000008 I Ox00000001) = Ox00000009. To debug
everything just use Oxffffffff. Below is an example of how to enable debug for
just configuration changes:
modprobe ath9k debug=Ox00000200 (or) modprobe ath9k htc
debug=Ox00000200
You can also use modprobe.d configuration files, for example to enable
ATH_DBG_CONFIG (Ox00000200) and ATH_DBG_PS (Ox00000800) you
would have a file /etc/modprobe.d/atheros.conf with this:
options ath9k debug=OxaOO (or) options ath9k_htc debug=OxaOO

Debugfs files
To get debugfs you will need to mount it first. You can do so as follows:
mount -t debugfs debugfs /sys/kernel/debug/

Debugfs files for ath9k


ath9k has several debugfs files which you can query for information and some
which allow you to insert data. This can be enabled as:
Device Drivers --->
[*] Network device support --->
Wireless LAN --->
<M>
Atheros Wireless Cards --->
[M] Atheros 802.lln wireless cards support
[*]
Atheros ath9k debugging

Once the config options are enabled and debugfs is mounted, these would be
seen:
/sys/kernel/debug/ieee80211/phy0/ath9k/btcoex
/sys/kernel/debug/ieee80211/phy0/ath9k/diversity
/sys/kernel/debug/ieee80211/phy0/ath9k/gpio_val
/sys/kernel/debug/ieee80211/phy0/ath9k/gpio_mask
/sys/kernel/debug/ieee80211/phy0/ath9k/spectral_fft_perio
d

/sys/kernel/debug/ieee80211/phy0/ath9k/spectral_period
/sys/kernel/debug/ieee80211/phy0/ath9k/spectral_count
/sys/kernel/debug/ieee80211/phy0/ath9k/spectral short_rep
eat
/sys/kernel/debug/ieee80211/phy0/ath9k/spectral scan_ctl
/sys/kernel/debug/ieee80211/phy0/ath9k/spectral scanO
/sys/kernel/debug/ieee80211/phy0/ath9k/modal_eeprom
/sys/kernel/debug/ieee80211/phy0/ath9k/base_eeprom
/sys/kernel/debug/ieee80211/phy0/ath9k/dump_nfcal
/sys/kernel/debug/ieee80211/phy0/ath9k/regdump
/sys/kernel/debug/ieee80211/phy0/ath9k/ignore_extcca
/sys/kernel/debug/ieee80211/phy0/ath9k/regval
/sys/kernel/debug/ieee80211/phy0/ath9k/regidx
/sys/kernel/debug/ieee80211/phy0/ath9k/paprd
/sys/kernel/debug/ieee80211/phy0/ath9k/ani
/sys/kernel/debug/ieee80211/phy0/ath9k/tx_chainmask
/sys/kernel/debug/ieee80211/phy0/ath9k/rx_chainmask
/sys/kernel/debug/ieee80211/phy0/ath9k/recv
/sys/kernel/debug/ieee80211/phy0/ath9k/reset
/sys/kernel/debug/ieee80211/phy0/ath9k/misc
/sys/kernel/debug/ieee80211/phy0/ath9k/qlen_vo
/sys/kernel/debug/ieee80211/phy0/ath9k/qlen_vi
/sys/kernel/debug/ieee80211/phy0/ath9k/qlen_be
/sys/kernel/debug/ieee80211/phy0/ath9k/qlen_bk
/sys/kernel/debug/ieee80211/phy0/ath9k/queues
/sys/kernel/debug/ieee80211/phy0/ath9k/xmit
/sys/kernel/debug/ieee80211/phy0/ath9k/interrupt
/sys/kernel/debug/ieee80211/phy0/ath9k/dma

Debugfs files for ath9k_ htc


ath9k_htc has a few debugfs files which show driver statistics. Enable it as:

I Device

Drivers

--->

[*] Network device support --->


Wireless LAN --->
<M>
Atheros Wireless Cards --->
[M] Atheros 802.lln wireless cards support
[*]
Atheros ath9k htc debugging

Once enabled, these are available:


/sys/kernel/debug/ieee80211/phyl/ath9k_htc/modal eeprom
/sys/kernel/debug/ieee80211/phyl/ath9k_htc/base_eeprom
/sys/kernel/debug/ieee80211/phyl/ath9k_htc/debug
/sys/kernel/debug/ieee80211/phyl/ath9k_htc/queue
/sys/kernel/debug/ieee80211/phyl/ath9k_htc/slot
/sys/kernel/debug/ieee80211/phyl/ath9k_htc/recv
/sys/kernel/debug/ieee80211/phyl/ath9k_htc/xmit
/sys/kernel/debug/ieee80211/phyl/ath9k_htc/tgt_rx_stats
/sys/kernel/debug/ieee80211/phyl/ath9k_htc/tgt_tx_stats
/sys/kernel/debug/ieee80211/phyl/ath9k_htc/tgt_int stats

Anda mungkin juga menyukai