#
d6e71dd1 |
|
22-Nov-2023 |
Wu Yunchuan <yunchuan@nfschina.com> |
wifi: ath9k: Remove unnecessary (void*) conversions No need cast (void *) to (struct owl_ctx *), (struct ath_hw *), (struct cmd_buf *) or other types. Signed-off-by: Wu Yunchuan <yunchuan@nfschina.com> Reviewed-by: Jeff Johnson <quic_jjohnson@quicinc.com> Acked-by: Toke Høiland-Jørgensen <toke@toke.dk> Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com> Link: https://lore.kernel.org/r/20230919045226.524544-1-yunchuan@nfschina.com
|
#
95f97fe0 |
|
28-Aug-2023 |
Dmitry Antipov <dmantipov@yandex.ru> |
wifi: ath9k: fix clang-specific fortify warnings When compiling with clang 16.0.6 and CONFIG_FORTIFY_SOURCE=y, I've noticed the following (somewhat confusing due to absence of an actual source code location): In file included from drivers/net/wireless/ath/ath9k/debug.c:17: In file included from ./include/linux/slab.h:16: In file included from ./include/linux/gfp.h:7: In file included from ./include/linux/mmzone.h:8: In file included from ./include/linux/spinlock.h:56: In file included from ./include/linux/preempt.h:79: In file included from ./arch/x86/include/asm/preempt.h:9: In file included from ./include/linux/thread_info.h:60: In file included from ./arch/x86/include/asm/thread_info.h:53: In file included from ./arch/x86/include/asm/cpufeature.h:5: In file included from ./arch/x86/include/asm/processor.h:23: In file included from ./arch/x86/include/asm/msr.h:11: In file included from ./arch/x86/include/asm/cpumask.h:5: In file included from ./include/linux/cpumask.h:12: In file included from ./include/linux/bitmap.h:11: In file included from ./include/linux/string.h:254: ./include/linux/fortify-string.h:592:4: warning: call to '__read_overflow2_field' declared with 'warning' attribute: detected read beyond size of field (2nd parameter); maybe use struct_group()? [-Wattribute-warning] __read_overflow2_field(q_size_field, size); In file included from drivers/net/wireless/ath/ath9k/htc_drv_debug.c:17: In file included from drivers/net/wireless/ath/ath9k/htc.h:20: In file included from ./include/linux/module.h:13: In file included from ./include/linux/stat.h:19: In file included from ./include/linux/time.h:60: In file included from ./include/linux/time32.h:13: In file included from ./include/linux/timex.h:67: In file included from ./arch/x86/include/asm/timex.h:5: In file included from ./arch/x86/include/asm/processor.h:23: In file included from ./arch/x86/include/asm/msr.h:11: In file included from ./arch/x86/include/asm/cpumask.h:5: In file included from ./include/linux/cpumask.h:12: In file included from ./include/linux/bitmap.h:11: In file included from ./include/linux/string.h:254: ./include/linux/fortify-string.h:592:4: warning: call to '__read_overflow2_field' declared with 'warning' attribute: detected read beyond size of field (2nd parameter); maybe use struct_group()? [-Wattribute-warning] __read_overflow2_field(q_size_field, size); The compiler actually complains on 'ath9k_get_et_strings()' and 'ath9k_htc_get_et_strings()' due to the same reason: fortification logic inteprets call to 'memcpy()' as an attempt to copy the whole array from it's first member and so issues an overread warning. These warnings may be silenced by passing an address of the whole array and not the first member to 'memcpy()'. Signed-off-by: Dmitry Antipov <dmantipov@yandex.ru> Acked-by: Toke Høiland-Jørgensen <toke@toke.dk> Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com> Link: https://lore.kernel.org/r/20230829093856.234584-1-dmantipov@yandex.ru
|
#
1e413461 |
|
12-Jul-2023 |
Wang Ming <machel@vivo.com> |
wifi: ath9k: use IS_ERR() with debugfs_create_dir() The debugfs_create_dir() function returns error pointers, it never returns NULL. Most incorrect error checks were fixed, but the one in ath9k_htc_init_debug() was forgotten. Fix the remaining error check. Fixes: e5facc75fa91 ("ath9k_htc: Cleanup HTC debugfs") Signed-off-by: Wang Ming <machel@vivo.com> Acked-by: Toke Høiland-Jørgensen <toke@toke.dk> Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com> Link: https://lore.kernel.org/r/20230713030358.12379-1-machel@vivo.com
|
#
8b804643 |
|
26-Jul-2023 |
Dmitry Antipov <dmantipov@yandex.ru> |
wifi: ath9k: consistently use kstrtoX_from_user() functions Use 'kstrtoul_from_user()' and 'kstrtobool_from_user()' where appropriate and thus avoid some code duplication. Signed-off-by: Dmitry Antipov <dmantipov@yandex.ru> Acked-by: Toke Høiland-Jørgensen <toke@toke.dk> Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com> Link: https://lore.kernel.org/r/20230726185046.188225-1-dmantipov@yandex.ru
|
#
4dea97f8 |
|
01-Jul-2022 |
Yury Norov <yury.norov@gmail.com> |
lib/bitmap: change type of bitmap_weight to unsigned long bitmap_weight() doesn't return negative values, so change it's type to unsigned long. It may help compiler to generate better code and catch bugs. Signed-off-by: Yury Norov <yury.norov@gmail.com>
|
#
2ef00c53 |
|
23-Mar-2018 |
Joe Perches <joe@perches.com> |
wireless: Use octal not symbolic permissions Prefer the direct use of octal for permissions. Done with checkpatch -f --types=SYMBOLIC_PERMS --fix-inplace and some typing. Miscellanea: o Whitespace neatening around these conversions. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
|
#
89860038 |
|
13-Feb-2015 |
Tejun Heo <tj@kernel.org> |
wireless: use %*pb[l] to print bitmaps including cpumasks and nodemasks printk and friends can now format bitmaps using '%*pb[l]'. cpumask and nodemask also provide cpumask_pr_args() and nodemask_pr_args() respectively which can be used to generate the two printf arguments necessary to format the specified cpu/nodemask. Signed-off-by: Tejun Heo <tj@kernel.org> Cc: "John W. Linville" <linville@tuxdriver.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
|
#
3f2aa13f |
|
06-Nov-2014 |
Oleksij Rempel <linux@rempel-privat.de> |
ath9k_htc: add spectral scan debug interface Signed-off-by: Oleksij Rempel <linux@rempel-privat.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
3eb6ed23 |
|
11-May-2014 |
Oleksij Rempel <linux@rempel-privat.de> |
ath9k_htc: use ath9k_cmn_debug_phy_err Signed-off-by: Oleksij Rempel <linux@rempel-privat.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
f14c17cc |
|
11-May-2014 |
Oleksij Rempel <linux@rempel-privat.de> |
ath9k_htc: use ath9k_cmn_debug_recv Signed-off-by: Oleksij Rempel <linux@rempel-privat.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
b5a0c86a |
|
11-May-2014 |
Oleksij Rempel <linux@rempel-privat.de> |
ath9k & ath9k_htc: move ath_rx_stats to cmn and use it. This move need changes in both drivers. Signed-off-by: Oleksij Rempel <linux@rempel-privat.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
df738209 |
|
11-May-2014 |
Oleksij Rempel <linux@rempel-privat.de> |
ath9k_htc: use ath9k_cmn_debug_base_eeprom Signed-off-by: Oleksij Rempel <linux@rempel-privat.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
7e9bed71 |
|
11-May-2014 |
Oleksij Rempel <linux@rempel-privat.de> |
ath9k_htc: use ath9k_cmn_debug_modal_eeprom Signed-off-by: Oleksij Rempel <linux@rempel-privat.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
5e88ba62 |
|
05-Sep-2013 |
Zefir Kurtisi <zefir.kurtisi@neratec.com> |
ath9k: replace snprintf() with scnprintf() Whenever the return value of snprintf() is used to calculate remaining buffer-space, we wanted to use sncprintf() instead. Indentation is adapted where possible. Some lines exceed the line width limit, either they did it already before, or since they can not be broken reasonably well. Signed-off-by: Zefir Kurtisi <zefir.kurtisi@neratec.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
68185a4b |
|
19-Jun-2013 |
Ben Greear <greearb@candelatech.com> |
ath9k_htc: Add ethtool stats support. This provides some of the same info found in the ath9k_htc debugfs through the standard ethtool stats API. This logic is only supported when ath9k_htc debugfs kernel feature is enabled, since that is the only time stats are actually gathered. Signed-off-by: Ben Greear <greearb@candelatech.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
156652bb |
|
19-Jun-2013 |
Ben Greear <greearb@candelatech.com> |
ath9k_htc: Support reporting tx and rx chain mask. Signed-off-by: Ben Greear <greearb@candelatech.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
27d7f477 |
|
31-May-2013 |
Jingoo Han <jg1.han@samsung.com> |
net: wireless: replace strict_strtoul() with kstrtoul() The usage of strict_strtoul() is not preferred, because strict_strtoul() is obsolete. Thus, kstrtoul() should be used. Signed-off-by: Jingoo Han <jg1.han@samsung.com> Signed-off-by: David S. Miller <davem@davemloft.net>
|
#
bea843c7 |
|
21-Nov-2012 |
Sujith Manoharan <c_manoha@qca.qualcomm.com> |
ath9k/ath9k_htc: Remove WME macros Use the macros provided by mac80211 and remove redundant declarations inside the drivers. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
234e3405 |
|
05-Apr-2012 |
Stephen Boyd <sboyd@codeaurora.org> |
simple_open: automatically convert to simple_open() Many users of debugfs copy the implementation of default_open() when they want to support a custom read/write function op. This leads to a proliferation of the default_open() implementation across the entire tree. Now that the common implementation has been consolidated into libfs we can replace all the users of this function with simple_open(). This replacement was done with the following semantic patch: <smpl> @ open @ identifier open_f != simple_open; identifier i, f; @@ -int open_f(struct inode *i, struct file *f) -{ ( -if (i->i_private) -f->private_data = i->i_private; | -f->private_data = i->i_private; ) -return 0; -} @ has_open depends on open @ identifier fops; identifier open.open_f; @@ struct file_operations fops = { ... -.open = open_f, +.open = simple_open, ... }; </smpl> [akpm@linux-foundation.org: checkpatch fixes] Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Julia Lawall <Julia.Lawall@lip6.fr> Acked-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
|
#
8f895026 |
|
20-Jul-2011 |
Andy Shevchenko <andriy.shevchenko@linux.intel.com> |
wireless: ath9k: use %pM to print MAC Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Cc: "Luis R. Rodriguez" <lrodriguez@atheros.com> Cc: ath9k-devel@lists.ath9k.org Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
44368796 |
|
28-Apr-2011 |
Sujith Manoharan <Sujith.Manoharan@atheros.com> |
ath9k_htc: Dump modal eeprom header for UB91/94/95 Debugfs file location: <debugfs_mnt>/ieee80211/phy#/ath9k_htc/modal_eeprom Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
80d887c3 |
|
28-Apr-2011 |
Sujith Manoharan <Sujith.Manoharan@atheros.com> |
ath9k_htc: Dump base eeprom header for UB91/94/95 Debugfs file location: <debugfs_mnt>/ieee80211/phy#/ath9k_htc/base_eeprom Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
c58ca5b5 |
|
19-Apr-2011 |
Sujith Manoharan <Sujith.Manoharan@atheros.com> |
ath9k_htc: Use power save wrappers when accessing HW Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
e5facc75 |
|
15-Apr-2011 |
Rajkumar Manoharan <rmanoharan@atheros.com> |
ath9k_htc: Cleanup HTC debugfs Move the ath9k_htc debugfs under ieee80211 to be inline with ath9k driver and it also helps to simplify debug code. Signed-off-by: Rajkumar Manoharan <rmanoharan@atheros.com> Acked-by: Sujith Manoharan <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
00bca7e2 |
|
14-Apr-2011 |
Rajkumar Manoharan <rmanoharan@atheros.com> |
ath9k_htc: Add debugfs support to change debug mask Signed-off-by: Rajkumar Manoharan <rmanoharan@atheros.com> Acked-by: Sujith Manoharan <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
fbc29d6c |
|
12-Apr-2011 |
Sujith Manoharan <Sujith.Manoharan@atheros.com> |
ath9k_htc: Add detailed firmware statistics New debugfs files: <debugfs_root>/ath9k_htc/<phy#>/tgt_int_stats <debugfs_root>/ath9k_htc/<phy#>/tgt_tx_stats <debugfs_root>/ath9k_htc/<phy#>/tgt_rx_stats Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
c4d04186 |
|
12-Apr-2011 |
Sujith Manoharan <Sujith.Manoharan@atheros.com> |
ath9k_htc: Add a debugfs file showing endpoint status Location: ath9k_htc/phy#/queue Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
01f684de |
|
12-Apr-2011 |
Sujith Manoharan <Sujith.Manoharan@atheros.com> |
ath9k_htc: Add a debugfs file to dump TX slot information Location: ath9k_htc/phy#/slot Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
b587fc81 |
|
12-Apr-2011 |
Sujith Manoharan <Sujith.Manoharan@atheros.com> |
ath9k_htc: Drain pending TX frames properly When doing a channel set or a reset operation the pending frames queued up for transmission have to be flushed and sent to mac80211. Fixing this has to be done in two separate steps: * Flush queued frames and kill the URB TX completion handler. * Complete all the frames that in the TX pending queue. This patch adds proper support for draining and all the callsites namely, channel change/reset/idle/stop are fixed. A separate queue is used for handling failed frames. Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
719c4cf6 |
|
12-Apr-2011 |
Sujith Manoharan <Sujith.Manoharan@atheros.com> |
ath9k_htc: Add RX error statistics Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
#
8e42e4ba |
|
12-Apr-2011 |
Sujith Manoharan <Sujith.Manoharan@atheros.com> |
ath9k_htc: Move debug code to a separate file Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
|