309-v4.16-0002-ath10k-move-spectral-scan-support-under-a-separate-c.patch 3.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091
  1. From 42e01cb9cb109fb0bb4743f6c54d6aa67ac39b61 Mon Sep 17 00:00:00 2001
  2. Message-Id: <42e01cb9cb109fb0bb4743f6c54d6aa67ac39b61.1515610034.git.mschiffer@universe-factory.net>
  3. In-Reply-To: <9df7ddc3ed25b7d3473f117a0680b9418adb5753.1515610034.git.mschiffer@universe-factory.net>
  4. References: <9df7ddc3ed25b7d3473f117a0680b9418adb5753.1515610034.git.mschiffer@universe-factory.net>
  5. From: Matthias Schiffer <[email protected]>
  6. Date: Mon, 27 Nov 2017 18:56:23 +0100
  7. Subject: [PATCH 2/2] ath10k: move spectral scan support under a separate
  8. config symbol
  9. At the moment, spectral scan support, and with it RELAY, is always enabled
  10. with ATH10K_DEBUGFS. Spectral scan support is currently the only user of
  11. RELAY in ath10k, and it unconditionally reserves a relay channel.
  12. Having debugfs support in ath10k is often useful even on very small
  13. embedded routers, where we'd rather like to avoid the code size and RAM
  14. usage of the relay support. While ath10k-based devices usually have more
  15. resources than ath9k-based ones, it makes sense to keep the configuration
  16. symmetric to ath9k, so the same base kernel without RELAY can be used for
  17. both ath9k and ath10k hardware.
  18. Signed-off-by: Matthias Schiffer <[email protected]>
  19. Signed-off-by: Kalle Valo <[email protected]>
  20. ---
  21. drivers/net/wireless/ath/ath10k/Kconfig | 9 ++++++++-
  22. drivers/net/wireless/ath/ath10k/Makefile | 2 +-
  23. drivers/net/wireless/ath/ath10k/spectral.h | 4 ++--
  24. 3 files changed, 11 insertions(+), 4 deletions(-)
  25. --- a/drivers/net/wireless/ath/ath10k/Kconfig
  26. +++ b/drivers/net/wireless/ath/ath10k/Kconfig
  27. @@ -51,12 +51,19 @@ config ATH10K_DEBUG
  28. config ATH10K_DEBUGFS
  29. bool "Atheros ath10k debugfs support"
  30. depends on ATH10K && DEBUG_FS
  31. - depends on RELAY
  32. ---help---
  33. Enabled debugfs support
  34. If unsure, say Y to make it easier to debug problems.
  35. +config ATH10K_SPECTRAL
  36. + bool "Atheros ath10k spectral scan support"
  37. + depends on ATH10K_DEBUGFS
  38. + depends on RELAY
  39. + default n
  40. + ---help---
  41. + Say Y to enable access to the FFT/spectral data via debugfs.
  42. +
  43. config ATH10K_TRACING
  44. depends on !KERNEL_3_4
  45. bool "Atheros ath10k tracing support"
  46. --- a/drivers/net/wireless/ath/ath10k/Makefile
  47. +++ b/drivers/net/wireless/ath/ath10k/Makefile
  48. @@ -14,7 +14,7 @@ ath10k_core-y += mac.o \
  49. p2p.o \
  50. swap.o
  51. -ath10k_core-$(CPTCFG_ATH10K_DEBUGFS) += spectral.o
  52. +ath10k_core-$(CPTCFG_ATH10K_SPECTRAL) += spectral.o
  53. ath10k_core-$(CPTCFG_NL80211_TESTMODE) += testmode.o
  54. ath10k_core-$(CPTCFG_ATH10K_TRACING) += trace.o
  55. ath10k_core-$(CPTCFG_ATH10K_THERMAL) += thermal.o
  56. --- a/drivers/net/wireless/ath/ath10k/spectral.h
  57. +++ b/drivers/net/wireless/ath/ath10k/spectral.h
  58. @@ -44,7 +44,7 @@ enum ath10k_spectral_mode {
  59. SPECTRAL_MANUAL,
  60. };
  61. -#ifdef CPTCFG_ATH10K_DEBUGFS
  62. +#ifdef CPTCFG_ATH10K_SPECTRAL
  63. int ath10k_spectral_process_fft(struct ath10k *ar,
  64. struct wmi_phyerr_ev_arg *phyerr,
  65. @@ -85,6 +85,6 @@ static inline void ath10k_spectral_destr
  66. {
  67. }
  68. -#endif /* CPTCFG_ATH10K_DEBUGFS */
  69. +#endif /* CPTCFG_ATH10K_SPECTRAL */
  70. #endif /* SPECTRAL_H */
  71. --- a/local-symbols
  72. +++ b/local-symbols
  73. @@ -140,6 +140,7 @@ ATH10K_SDIO=
  74. ATH10K_USB=
  75. ATH10K_DEBUG=
  76. ATH10K_DEBUGFS=
  77. +ATH10K_SPECTRAL=
  78. ATH10K_THERMAL=
  79. ATH10K_TRACING=
  80. ATH10K_DFS_CERTIFIED=