diff options
author | Simon Wunderlich <sw@simonwunderlich.de> | 2014-08-02 09:12:54 +0300 |
---|---|---|
committer | Kalle Valo <kvalo@qca.qualcomm.com> | 2014-08-04 09:07:54 +0300 |
commit | 855aed1220d2c94425ab01a85fe7a6f5c436940f (patch) | |
tree | 9d94bc1928b1dd95b4d807d751b1618a69964f7c /drivers/net/wireless/ath/ath10k/core.c | |
parent | 95752b759e2e1d9c590252a92e080eeb611fdbcd (diff) |
ath10k: add spectral scan feature
Adds the spectral scan feature for ath10k. The spectral scan is triggered by
configuring a mode through a debugfs control file. Samples can be gathered via
another relay debugfs file.
Essentially, to try it out:
ip link set dev wlan0 up
echo background > /sys/kernel/debug/ieee80211/phy0/ath10k/spectral_scan_ctl
echo trigger > /sys/kernel/debug/ieee80211/phy0/ath10k/spectral_scan_ctl
iw dev wlan0 scan
echo disable > /sys/kernel/debug/ieee80211/phy0/ath10k/spectral_scan_ctl
cat /sys/kernel/debug/ieee80211/phy0/ath10k/spectral_scan0 > samples
This feature is still experimental. Based on the original RFC patch of
Sven Eckelmann.
Signed-off-by: Simon Wunderlich <sw@simonwunderlich.de>
Signed-off-by: Mathias Kretschmer <mathias.kretschmer@fokus.fraunhofer.de>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath10k/core.c')
-rw-r--r-- | drivers/net/wireless/ath/ath10k/core.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath10k/core.c b/drivers/net/wireless/ath/ath10k/core.c index bef797d5f4d3..440c3ff03aec 100644 --- a/drivers/net/wireless/ath/ath10k/core.c +++ b/drivers/net/wireless/ath/ath10k/core.c @@ -1000,9 +1000,17 @@ static void ath10k_core_register_work(struct work_struct *work) goto err_unregister_mac; } + status = ath10k_spectral_create(ar); + if (status) { + ath10k_err("failed to initialize spectral\n"); + goto err_debug_destroy; + } + set_bit(ATH10K_FLAG_CORE_REGISTERED, &ar->dev_flags); return; +err_debug_destroy: + ath10k_debug_destroy(ar); err_unregister_mac: ath10k_mac_unregister(ar); err_release_fw: @@ -1046,6 +1054,8 @@ void ath10k_core_unregister(struct ath10k *ar) ath10k_core_free_firmware_files(ar); + ath10k_spectral_destroy(ar); + ath10k_debug_destroy(ar); } EXPORT_SYMBOL(ath10k_core_unregister); |