* [PATCH wireless] wifi: ath6kl: remove WARN on bad firmware input
@ 2025-06-17 9:45 Johannes Berg
2025-06-17 10:31 ` [syzbot] [usb?] [wireless?] WARNING in ath6kl_bmi_get_target_info (2) syzbot
2025-06-17 19:10 ` [PATCH wireless] wifi: ath6kl: remove WARN on bad firmware input Jeff Johnson
0 siblings, 2 replies; 5+ messages in thread
From: Johannes Berg @ 2025-06-17 9:45 UTC (permalink / raw)
To: linux-wireless; +Cc: Johannes Berg, syzbot+92c6dd14aaa230be6855
From: Johannes Berg <johannes.berg@intel.com>
If the firmware gives bad input, that's nothing to do with
the driver's stack at this point etc., so the WARN_ON()
doesn't add any value. Additionally, this is one of the
top syzbot reports now. Just print a message, and as an
added bonus, print the sizes too.
Reported-by: syzbot+92c6dd14aaa230be6855@syzkaller.appspotmail.com
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
---
#syz test
---
drivers/net/wireless/ath/ath6kl/bmi.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/net/wireless/ath/ath6kl/bmi.c b/drivers/net/wireless/ath/ath6kl/bmi.c
index af98e871199d..5a9e93fd1ef4 100644
--- a/drivers/net/wireless/ath/ath6kl/bmi.c
+++ b/drivers/net/wireless/ath/ath6kl/bmi.c
@@ -87,7 +87,9 @@ int ath6kl_bmi_get_target_info(struct ath6kl *ar,
* We need to do some backwards compatibility to make this work.
*/
if (le32_to_cpu(targ_info->byte_count) != sizeof(*targ_info)) {
- WARN_ON(1);
+ ath6kl_err("mismatched byte count %d vs. expected %zd\n",
+ le32_to_cpu(targ_info->byte_count),
+ sizeof(*targ_info));
return -EINVAL;
}
--
2.49.0
^ permalink raw reply related [flat|nested] 5+ messages in thread* Re: [syzbot] [usb?] [wireless?] WARNING in ath6kl_bmi_get_target_info (2)
2025-06-17 9:45 [PATCH wireless] wifi: ath6kl: remove WARN on bad firmware input Johannes Berg
@ 2025-06-17 10:31 ` syzbot
2025-06-17 19:10 ` [PATCH wireless] wifi: ath6kl: remove WARN on bad firmware input Jeff Johnson
1 sibling, 0 replies; 5+ messages in thread
From: syzbot @ 2025-06-17 10:31 UTC (permalink / raw)
To: johannes.berg, johannes, linux-kernel, linux-wireless,
syzkaller-bugs
Hello,
syzbot has tested the proposed patch and the reproducer did not trigger any issue:
Reported-by: syzbot+92c6dd14aaa230be6855@syzkaller.appspotmail.com
Tested-by: syzbot+92c6dd14aaa230be6855@syzkaller.appspotmail.com
Tested on:
commit: 9afe6529 Merge tag 'x86_urgent_for_6.16-rc3' of git://..
git tree: upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=1008c50c580000
kernel config: https://syzkaller.appspot.com/x/.config?x=a1383d853600dcee
dashboard link: https://syzkaller.appspot.com/bug?extid=92c6dd14aaa230be6855
compiler: Debian clang version 20.1.6 (++20250514063057+1e4d39e07757-1~exp1~20250514183223.118), Debian LLD 20.1.6
patch: https://syzkaller.appspot.com/x/patch.diff?x=17334370580000
Note: testing is done by a robot and is best-effort only.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH wireless] wifi: ath6kl: remove WARN on bad firmware input
2025-06-17 9:45 [PATCH wireless] wifi: ath6kl: remove WARN on bad firmware input Johannes Berg
2025-06-17 10:31 ` [syzbot] [usb?] [wireless?] WARNING in ath6kl_bmi_get_target_info (2) syzbot
@ 2025-06-17 19:10 ` Jeff Johnson
2025-06-17 19:25 ` Johannes Berg
1 sibling, 1 reply; 5+ messages in thread
From: Jeff Johnson @ 2025-06-17 19:10 UTC (permalink / raw)
To: Johannes Berg, linux-wireless; +Cc: Johannes Berg, syzbot+92c6dd14aaa230be6855
On 6/17/2025 2:45 AM, Johannes Berg wrote:
> From: Johannes Berg <johannes.berg@intel.com>
>
> If the firmware gives bad input, that's nothing to do with
> the driver's stack at this point etc., so the WARN_ON()
> doesn't add any value. Additionally, this is one of the
> top syzbot reports now. Just print a message, and as an
> added bonus, print the sizes too.
>
> Reported-by: syzbot+92c6dd14aaa230be6855@syzkaller.appspotmail.com
> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Since you used the wireless tag I'm guessing you'll take this through your tree..
Acked-by: Jeff Johnson <jeff.johnson@oss.qualcomm.com>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH wireless] wifi: ath6kl: remove WARN on bad firmware input
2025-06-17 19:10 ` [PATCH wireless] wifi: ath6kl: remove WARN on bad firmware input Jeff Johnson
@ 2025-06-17 19:25 ` Johannes Berg
2025-06-17 22:27 ` Jeff Johnson
0 siblings, 1 reply; 5+ messages in thread
From: Johannes Berg @ 2025-06-17 19:25 UTC (permalink / raw)
To: Jeff Johnson, linux-wireless; +Cc: syzbot+92c6dd14aaa230be6855
On Tue, 2025-06-17 at 12:10 -0700, Jeff Johnson wrote:
> On 6/17/2025 2:45 AM, Johannes Berg wrote:
> > From: Johannes Berg <johannes.berg@intel.com>
> >
> > If the firmware gives bad input, that's nothing to do with
> > the driver's stack at this point etc., so the WARN_ON()
> > doesn't add any value. Additionally, this is one of the
> > top syzbot reports now. Just print a message, and as an
> > added bonus, print the sizes too.
> >
> > Reported-by: syzbot+92c6dd14aaa230be6855@syzkaller.appspotmail.com
> > Signed-off-by: Johannes Berg <johannes.berg@intel.com>
>
> Since you used the wireless tag I'm guessing you'll take this through your tree..
Oh, did I mix that up? I think get_maintainers said it was orphaned.
So yeah, I was thinking I'd just take it, thanks for taking a look.
johannes
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH wireless] wifi: ath6kl: remove WARN on bad firmware input
2025-06-17 19:25 ` Johannes Berg
@ 2025-06-17 22:27 ` Jeff Johnson
0 siblings, 0 replies; 5+ messages in thread
From: Jeff Johnson @ 2025-06-17 22:27 UTC (permalink / raw)
To: Johannes Berg, linux-wireless; +Cc: syzbot+92c6dd14aaa230be6855
On 6/17/2025 12:25 PM, Johannes Berg wrote:
> On Tue, 2025-06-17 at 12:10 -0700, Jeff Johnson wrote:
>> On 6/17/2025 2:45 AM, Johannes Berg wrote:
>>> From: Johannes Berg <johannes.berg@intel.com>
>>>
>>> If the firmware gives bad input, that's nothing to do with
>>> the driver's stack at this point etc., so the WARN_ON()
>>> doesn't add any value. Additionally, this is one of the
>>> top syzbot reports now. Just print a message, and as an
>>> added bonus, print the sizes too.
>>>
>>> Reported-by: syzbot+92c6dd14aaa230be6855@syzkaller.appspotmail.com
>>> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
>>
>> Since you used the wireless tag I'm guessing you'll take this through your tree..
>
> Oh, did I mix that up? I think get_maintainers said it was orphaned.
>
> So yeah, I was thinking I'd just take it, thanks for taking a look.
yes, it's orphaned but the patchwork rules had assigned it to me
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2025-06-17 22:27 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-06-17 9:45 [PATCH wireless] wifi: ath6kl: remove WARN on bad firmware input Johannes Berg
2025-06-17 10:31 ` [syzbot] [usb?] [wireless?] WARNING in ath6kl_bmi_get_target_info (2) syzbot
2025-06-17 19:10 ` [PATCH wireless] wifi: ath6kl: remove WARN on bad firmware input Jeff Johnson
2025-06-17 19:25 ` Johannes Berg
2025-06-17 22:27 ` Jeff Johnson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox