syzbot


general protection fault in mac80211_hwsim_tx_frame_nl (2)

Status: upstream: reported on 2023/02/08 15:42
Reported-by: syzbot+4cfba4cd716e171d3f7b@syzkaller.appspotmail.com
First crash: 665d, last: 665d
Similar bugs (2)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-4.19 general protection fault in mac80211_hwsim_tx_frame_nl 1 809d 809d 0/1 auto-obsoleted due to no activity on 2023/01/15 09:09
upstream general protection fault in mac80211_hwsim_tx_frame_nl wireless 4 1274d 1281d 0/28 auto-closed as invalid on 2021/10/06 20:43

Sample crash report:
netlink: 16 bytes leftover after parsing attributes in process `syz-executor.0'.
kasan: CONFIG_KASAN_INLINE enabled
kasan: GPF could be caused by NULL-ptr deref or user memory access
general protection fault: 0000 [#1] PREEMPT SMP KASAN
CPU: 1 PID: 7807 Comm: in:imklog Not tainted 4.19.211-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/12/2023
RIP: 0010:mac80211_hwsim_tx_frame_nl+0x403/0x1230 drivers/net/wireless/mac80211_hwsim.c:1114
Code: 48 c1 ea 03 80 3c 02 00 0f 85 7e 0d 00 00 4c 8b ab 88 12 00 00 48 b8 00 00 00 00 00 fc ff df 49 8d 7d 04 48 89 fa 48 c1 ea 03 <0f> b6 14 02 48 89 f8 83 e0 07 83 c0 01 38 d0 7c 09 84 d2 74 05 e8
RSP: 0018:ffff8880ba107c40 EFLAGS: 00010247
RAX: dffffc0000000000 RBX: ffff8880615ed720 RCX: ffffffff84a67677
RDX: 0000000000000000 RSI: ffffffff84a67685 RDI: 0000000000000004
RBP: ffff8880b3364bc0 R08: 0000000000000001 R09: 0000000000000000
R10: 0000000000000005 R11: 0000000000000000 R12: ffff8880ba107cc8
R13: 0000000000000000 R14: ffff88805bbb7d00 R15: ffff8880615ebe00
FS:  00007f5107142700(0000) GS:ffff8880ba100000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f90be800000 CR3: 00000000a9818000 CR4: 00000000003406e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <IRQ>
 mac80211_hwsim_tx_frame+0x159/0x210 drivers/net/wireless/mac80211_hwsim.c:1554
 mac80211_hwsim_beacon_tx+0x3f8/0x680 drivers/net/wireless/mac80211_hwsim.c:1595
 __iterate_interfaces+0x2e1/0x4a0 net/mac80211/util.c:614
 ieee80211_iterate_active_interfaces_atomic+0x8d/0x170 net/mac80211/util.c:650
 mac80211_hwsim_beacon+0xc9/0x190 drivers/net/wireless/mac80211_hwsim.c:1615
 __tasklet_hrtimer_trampoline+0x29/0xa0 kernel/softirq.c:601
 tasklet_action_common.constprop.0+0x265/0x360 kernel/softirq.c:522
 __do_softirq+0x265/0x980 kernel/softirq.c:292
 invoke_softirq kernel/softirq.c:372 [inline]
 irq_exit+0x215/0x260 kernel/softirq.c:412
 exiting_irq arch/x86/include/asm/apic.h:536 [inline]
 smp_apic_timer_interrupt+0x136/0x550 arch/x86/kernel/apic/apic.c:1098
 apic_timer_interrupt+0xf/0x20 arch/x86/entry/entry_64.S:894
 </IRQ>
RIP: 0010:arch_local_irq_restore arch/x86/include/asm/paravirt.h:789 [inline]
RIP: 0010:kfree+0x123/0x210 mm/slab.c:3823
Code: 89 ea 48 89 ee 4c 89 e7 e8 da ee ff ff f6 c7 02 74 ca e8 20 74 cf ff 48 83 3d 60 4d 59 08 00 0f 84 eb 00 00 00 48 89 df 57 9d <0f> 1f 44 00 00 5b 5d 41 5c 41 5d c3 65 8b 05 ea 4b 69 7e 83 f8 07
RSP: 0018:ffff88809df5fa90 EFLAGS: 00000286 ORIG_RAX: ffffffffffffff13
RAX: 0000000000000007 RBX: 0000000000000286 RCX: 1ffff1101416ad8d
RDX: 0000000000000000 RSI: ffff8880a0b56c48 RDI: 0000000000000286
RBP: ffff88809cc27240 R08: 0000000000400000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: ffff88813bff0ac0
R13: ffffffff814d928c R14: 0000000000000063 R15: 00007f5107121e03
 syslog_print kernel/printk/printk.c:1388 [inline]
 do_syslog.part.0+0x53c/0x1510 kernel/printk/printk.c:1505
 do_syslog+0x49/0x60 kernel/printk/printk.c:1486
 kmsg_read+0x8a/0xb0 fs/proc/kmsg.c:40
 proc_reg_read+0x1bd/0x2d0 fs/proc/inode.c:231
 __vfs_read+0xf7/0x750 fs/read_write.c:416
 vfs_read+0x194/0x3c0 fs/read_write.c:452
 ksys_read+0x12b/0x2a0 fs/read_write.c:579
 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293
 entry_SYSCALL_64_after_hwframe+0x49/0xbe
RIP: 0033:0x7f510978522d
Code: c1 20 00 00 75 10 b8 00 00 00 00 0f 05 48 3d 01 f0 ff ff 73 31 c3 48 83 ec 08 e8 4e fc ff ff 48 89 04 24 b8 00 00 00 00 0f 05 <48> 8b 3c 24 48 89 c2 e8 97 fc ff ff 48 89 d0 48 83 c4 08 48 3d 01
RSP: 002b:00007f5107121580 EFLAGS: 00000293 ORIG_RAX: 0000000000000000
RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f510978522d
RDX: 0000000000001fa0 RSI: 00007f5107121da0 RDI: 0000000000000004
RBP: 000055f905ce79d0 R08: 0000000000000000 R09: 0000000004000001
R10: 0000000000000001 R11: 0000000000000293 R12: 00007f5107121da0
R13: 0000000000001fa0 R14: 0000000000001f9f R15: 00007f5107121e08
Modules linked in:
---[ end trace a618f4b3054e4394 ]---
RIP: 0010:mac80211_hwsim_tx_frame_nl+0x403/0x1230 drivers/net/wireless/mac80211_hwsim.c:1114
Code: 48 c1 ea 03 80 3c 02 00 0f 85 7e 0d 00 00 4c 8b ab 88 12 00 00 48 b8 00 00 00 00 00 fc ff df 49 8d 7d 04 48 89 fa 48 c1 ea 03 <0f> b6 14 02 48 89 f8 83 e0 07 83 c0 01 38 d0 7c 09 84 d2 74 05 e8
RSP: 0018:ffff8880ba107c40 EFLAGS: 00010247
RAX: dffffc0000000000 RBX: ffff8880615ed720 RCX: ffffffff84a67677
RDX: 0000000000000000 RSI: ffffffff84a67685 RDI: 0000000000000004
RBP: ffff8880b3364bc0 R08: 0000000000000001 R09: 0000000000000000
mac80211_hwsim: wmediumd released netlink socket, switching to perfect channel medium
R10: 0000000000000005 R11: 0000000000000000 R12: ffff8880ba107cc8
R13: 0000000000000000 R14: ffff88805bbb7d00 R15: ffff8880615ebe00
FS:  00007f5107142700(0000) GS:ffff8880ba100000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f90be800000 CR3: 00000000a9818000 CR4: 00000000003406e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess):
   0:	48 c1 ea 03          	shr    $0x3,%rdx
   4:	80 3c 02 00          	cmpb   $0x0,(%rdx,%rax,1)
   8:	0f 85 7e 0d 00 00    	jne    0xd8c
   e:	4c 8b ab 88 12 00 00 	mov    0x1288(%rbx),%r13
  15:	48 b8 00 00 00 00 00 	movabs $0xdffffc0000000000,%rax
  1c:	fc ff df
  1f:	49 8d 7d 04          	lea    0x4(%r13),%rdi
  23:	48 89 fa             	mov    %rdi,%rdx
  26:	48 c1 ea 03          	shr    $0x3,%rdx
* 2a:	0f b6 14 02          	movzbl (%rdx,%rax,1),%edx <-- trapping instruction
  2e:	48 89 f8             	mov    %rdi,%rax
  31:	83 e0 07             	and    $0x7,%eax
  34:	83 c0 01             	add    $0x1,%eax
  37:	38 d0                	cmp    %dl,%al
  39:	7c 09                	jl     0x44
  3b:	84 d2                	test   %dl,%dl
  3d:	74 05                	je     0x44
  3f:	e8                   	.byte 0xe8

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/02/08 15:42 linux-4.19.y 3f8a27f9e27b fc9c934e .config console log report info [disk image] [vmlinux] ci2-linux-4-19 general protection fault in mac80211_hwsim_tx_frame_nl
* Struck through repros no longer work on HEAD.