syzbot


divide error in mac80211_hwsim_bss_info_changed

Status: upstream: reported on 2024/07/12 08:51
Reported-by: syzbot+52e006c922419132d49f@syzkaller.appspotmail.com
First crash: 95d, last: 5d01h
Similar bugs (5)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
android-54 divide error in mac80211_hwsim_bss_info_changed 2 1463d 1471d 0/2 auto-closed as invalid on 2021/02/09 23:56
upstream divide error in mac80211_hwsim_bss_info_changed (2) wireless 2 1045d 1093d 0/28 auto-closed as invalid on 2022/04/04 22:30
linux-4.19 divide error in mac80211_hwsim_bss_info_changed (2) 1 596d 596d 0/1 upstream: reported on 2023/02/27 09:41
upstream divide error in mac80211_hwsim_bss_info_changed wireless 1 1280d 1247d 0/28 auto-closed as invalid on 2021/08/12 01:33
linux-4.19 divide error in mac80211_hwsim_bss_info_changed 1 727d 727d 0/1 auto-obsoleted due to no activity on 2023/02/16 17:15

Sample crash report:
divide error: 0000 [#1] PREEMPT SMP KASAN
CPU: 1 PID: 5572 Comm: kworker/u4:16 Not tainted 5.15.167-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024
Workqueue: phy48 ieee80211_roc_work
RIP: 0010:mac80211_hwsim_bss_info_changed+0x419/0xfd0 drivers/net/wireless/mac80211_hwsim.c:2037
Code: 49 03 1f 48 b8 00 00 00 00 00 fc ff df 41 80 7c 05 00 00 49 89 c5 74 08 4c 89 f7 e8 31 45 d6 fb 49 8b 0e 89 ce 48 89 d8 31 d2 <48> f7 f6 29 d1 48 69 f1 e8 03 00 00 48 8b 7c 24 20 31 d2 b9 05 00
RSP: 0018:ffffc90003077a80 EFLAGS: 00010246
RAX: 000624264b08e98d RBX: 000624264b08e98d RCX: 0000000000000000
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000040
RBP: ffffc90003077b58 R08: ffffffff816fb511 R09: fffffbfff20e2426
R10: 0000000000000000 R11: dffffc0000000001 R12: 0000000000000200
R13: dffffc0000000000 R14: ffff88807a7b6fc0 R15: ffff88807a7b7120
FS:  0000000000000000(0000) GS:ffff8880b9100000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000000200002 CR3: 0000000051bbc000 CR4: 00000000003526e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 drv_bss_info_changed net/mac80211/driver-ops.h:177 [inline]
 ieee80211_bss_info_change_notify+0x2fd/0x540 net/mac80211/main.c:210
 ieee80211_offchannel_return+0x325/0x460 net/mac80211/offchannel.c:158
 __ieee80211_roc_work+0x287/0x340 net/mac80211/offchannel.c:444
 ieee80211_roc_work+0x2b/0x40 net/mac80211/offchannel.c:458
 process_one_work+0x8a1/0x10c0 kernel/workqueue.c:2310
 worker_thread+0xaca/0x1280 kernel/workqueue.c:2457
 kthread+0x3f6/0x4f0 kernel/kthread.c:334
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:287
 </TASK>
Modules linked in:
---[ end trace 97aa67d40f79e3dd ]---
RIP: 0010:mac80211_hwsim_bss_info_changed+0x419/0xfd0 drivers/net/wireless/mac80211_hwsim.c:2037
Code: 49 03 1f 48 b8 00 00 00 00 00 fc ff df 41 80 7c 05 00 00 49 89 c5 74 08 4c 89 f7 e8 31 45 d6 fb 49 8b 0e 89 ce 48 89 d8 31 d2 <48> f7 f6 29 d1 48 69 f1 e8 03 00 00 48 8b 7c 24 20 31 d2 b9 05 00
RSP: 0018:ffffc90003077a80 EFLAGS: 00010246
RAX: 000624264b08e98d RBX: 000624264b08e98d RCX: 0000000000000000
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000040
RBP: ffffc90003077b58 R08: ffffffff816fb511 R09: fffffbfff20e2426
R10: 0000000000000000 R11: dffffc0000000001 R12: 0000000000000200
R13: dffffc0000000000 R14: ffff88807a7b6fc0 R15: ffff88807a7b7120
FS:  0000000000000000(0000) GS:ffff8880b9000000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f42fb709d60 CR3: 000000000c68e000 CR4: 00000000003526f0
----------------
Code disassembly (best guess):
   0:	49 03 1f             	add    (%r15),%rbx
   3:	48 b8 00 00 00 00 00 	movabs $0xdffffc0000000000,%rax
   a:	fc ff df
   d:	41 80 7c 05 00 00    	cmpb   $0x0,0x0(%r13,%rax,1)
  13:	49 89 c5             	mov    %rax,%r13
  16:	74 08                	je     0x20
  18:	4c 89 f7             	mov    %r14,%rdi
  1b:	e8 31 45 d6 fb       	call   0xfbd64551
  20:	49 8b 0e             	mov    (%r14),%rcx
  23:	89 ce                	mov    %ecx,%esi
  25:	48 89 d8             	mov    %rbx,%rax
  28:	31 d2                	xor    %edx,%edx
* 2a:	48 f7 f6             	div    %rsi <-- trapping instruction
  2d:	29 d1                	sub    %edx,%ecx
  2f:	48 69 f1 e8 03 00 00 	imul   $0x3e8,%rcx,%rsi
  36:	48 8b 7c 24 20       	mov    0x20(%rsp),%rdi
  3b:	31 d2                	xor    %edx,%edx
  3d:	b9                   	.byte 0xb9
  3e:	05                   	.byte 0x5

Crashes (3):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/10/10 21:46 linux-5.15.y 3a5928702e71 8fbfc0c8 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan divide error in mac80211_hwsim_bss_info_changed
2024/07/30 12:29 linux-5.15.y 7e89efd3ae1c 5187fc86 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan divide error in mac80211_hwsim_bss_info_changed
2024/07/12 08:50 linux-5.15.y f45bea23c39c eaeb5c15 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan divide error in mac80211_hwsim_bss_info_changed
* Struck through repros no longer work on HEAD.