rc rc0: IR event FIFO is full!
rc rc0: IR event FIFO is full!
rc rc0: IR event FIFO is full!
rc rc0: IR event FIFO is full!
==================================================================
BUG: KASAN: slab-use-after-free in ir_raw_event_store_with_filter+0x55a/0x590 drivers/media/rc/rc-ir-raw.c:184
Write of size 8 at addr ffff8881197e50d8 by task syz-executor.0/9605
CPU: 0 PID: 9605 Comm: syz-executor.0 Not tainted 6.5.0-rc6-syzkaller-00119-gbbb9e06d2c64 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/26/2023
Call Trace:
__dump_stack lib/dump_stack.c:88 [inline]
dump_stack_lvl+0xd9/0x1b0 lib/dump_stack.c:106
print_address_description mm/kasan/report.c:364 [inline]
print_report+0xc4/0x620 mm/kasan/report.c:475
kasan_report+0xda/0x110 mm/kasan/report.c:588
ir_raw_event_store_with_filter+0x55a/0x590 drivers/media/rc/rc-ir-raw.c:184
sz_push+0x97/0x1d0 drivers/media/rc/streamzap.c:104
sz_push_full_space drivers/media/rc/streamzap.c:132 [inline]
sz_push_half_space drivers/media/rc/streamzap.c:138 [inline]
streamzap_callback+0x57d/0x7e0 drivers/media/rc/streamzap.c:190
__usb_hcd_giveback_urb+0x359/0x5c0 drivers/usb/core/hcd.c:1650
usb_hcd_giveback_urb+0x389/0x430 drivers/usb/core/hcd.c:1733
dummy_timer+0x1415/0x35f0 drivers/usb/gadget/udc/dummy_hcd.c:1987
call_timer_fn+0x1a0/0x580 kernel/time/timer.c:1700
expire_timers kernel/time/timer.c:1751 [inline]
__run_timers+0x764/0xb10 kernel/time/timer.c:2022
run_timer_softirq+0x58/0xd0 kernel/time/timer.c:2035
__do_softirq+0x20b/0x94e kernel/softirq.c:553
invoke_softirq kernel/softirq.c:427 [inline]
__irq_exit_rcu kernel/softirq.c:632 [inline]
irq_exit_rcu+0xa7/0x110 kernel/softirq.c:644
sysvec_apic_timer_interrupt+0x8e/0xb0 arch/x86/kernel/apic/apic.c:1109
asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:645
RIP: 0010:__raw_spin_unlock_irqrestore include/linux/spinlock_api_smp.h:152 [inline]
RIP: 0010:_raw_spin_unlock_irqrestore+0x31/0x70 kernel/locking/spinlock.c:194
Code: f5 53 48 8b 74 24 10 48 89 fb 48 83 c7 18 e8 c6 41 ec fa 48 89 df e8 9e c0 ec fa f7 c5 00 02 00 00 75 1f 9c 58 f6 c4 02 75 2f 01 00 00 00 e8 15 47 e1 fa 65 8b 05 26 57 c2 79 85 c0 74 12 5b
RSP: 0018:ffffc9000ee3f730 EFLAGS: 00000246
RAX: 0000000000000006 RBX: ffffffff8c1850b0 RCX: 1ffffffff16f1730
RDX: 0000000000000000 RSI: ffffffff8687a2e0 RDI: ffffffff86a59c00
RBP: 0000000000000282 R08: 0000000000000001 R09: fffffbfff16eef3e
R10: ffffffff8b7779f7 R11: 0000000000056000 R12: dffffc0000000000
R13: 00000000000193c8 R14: 0000000000000000 R15: 0000000000000000
__debug_check_no_obj_freed lib/debugobjects.c:1042 [inline]
debug_check_no_obj_freed+0x245/0x4c0 lib/debugobjects.c:1063
slab_free_hook mm/slub.c:1767 [inline]
slab_free_freelist_hook mm/slub.c:1818 [inline]
slab_free mm/slub.c:3801 [inline]
kmem_cache_free+0x1c2/0x4f0 mm/slub.c:3823
pgtable_pte_page_dtor include/linux/mm.h:2844 [inline]
___pte_free_tlb+0x1d/0x1c0 arch/x86/mm/pgtable.c:55
__pte_free_tlb arch/x86/include/asm/pgalloc.h:61 [inline]
free_pte_range mm/memory.c:194 [inline]
free_pmd_range mm/memory.c:212 [inline]
free_pud_range mm/memory.c:246 [inline]
free_p4d_range mm/memory.c:280 [inline]
free_pgd_range+0x4e7/0xb80 mm/memory.c:360
free_pgtables+0x214/0x910 mm/memory.c:405
exit_mmap+0x2c9/0x960 mm/mmap.c:3213
__mmput kernel/fork.c:1348 [inline]
mmput+0xdb/0x420 kernel/fork.c:1370
exit_mm kernel/exit.c:567 [inline]
do_exit+0x9b4/0x2990 kernel/exit.c:861
do_group_exit+0xd4/0x2a0 kernel/exit.c:1024
get_signal+0x23f3/0x2770 kernel/signal.c:2881
arch_do_signal_or_restart+0x89/0x5f0 arch/x86/kernel/signal.c:308
exit_to_user_mode_loop kernel/entry/common.c:168 [inline]
exit_to_user_mode_prepare+0x116/0x1f0 kernel/entry/common.c:204
__syscall_exit_to_user_mode_work kernel/entry/common.c:286 [inline]
syscall_exit_to_user_mode+0x1d/0x50 kernel/entry/common.c:297
do_syscall_64+0x44/0xb0 arch/x86/entry/common.c:86
entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7f9dfe9be84b
Code: Unable to access opcode bytes at 0x7f9dfe9be821.
RSP: 002b:00007f9dfdd3eff0 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
RAX: fffffffffffffffc RBX: 0000000000000003 RCX: 00007f9dfe9be84b
RDX: 00007f9dfdd40080 RSI: 0000000080085502 RDI: 0000000000000003
RBP: 00007f9dfea0a47a R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000003 R11: 0000000000000246 R12: 0000000020000700
R13: 0000000000000000 R14: 00007f9dfeaddf80 R15: 00007ffec54c84a8
Allocated by task 5339:
kasan_save_stack+0x33/0x50 mm/kasan/common.c:45
kasan_set_track+0x25/0x30 mm/kasan/common.c:52
____kasan_kmalloc mm/kasan/common.c:374 [inline]
__kasan_kmalloc+0x87/0x90 mm/kasan/common.c:383
kmalloc include/linux/slab.h:582 [inline]
kzalloc include/linux/slab.h:703 [inline]
ir_raw_event_prepare+0x5a/0x320 drivers/media/rc/rc-ir-raw.c:617
rc_register_device+0x1517/0x1bd0 drivers/media/rc/rc-main.c:1921
streamzap_init_rc_dev drivers/media/rc/streamzap.c:249 [inline]
streamzap_probe+0x805/0x1090 drivers/media/rc/streamzap.c:331
usb_probe_interface+0x307/0x930 drivers/usb/core/driver.c:396
call_driver_probe drivers/base/dd.c:579 [inline]
really_probe+0x234/0xc90 drivers/base/dd.c:658
__driver_probe_device+0x1de/0x4b0 drivers/base/dd.c:798
driver_probe_device+0x4c/0x1a0 drivers/base/dd.c:828
__device_attach_driver+0x1d4/0x300 drivers/base/dd.c:956
bus_for_each_drv+0x157/0x1d0 drivers/base/bus.c:457
__device_attach+0x1e8/0x4b0 drivers/base/dd.c:1028
bus_probe_device+0x17c/0x1c0 drivers/base/bus.c:532
device_add+0x11f1/0x1b40 drivers/base/core.c:3625
usb_set_configuration+0x10cb/0x1c40 drivers/usb/core/message.c:2207
usb_generic_driver_probe+0xca/0x130 drivers/usb/core/generic.c:238
usb_probe_device+0xda/0x2c0 drivers/usb/core/driver.c:293
call_driver_probe drivers/base/dd.c:579 [inline]
really_probe+0x234/0xc90 drivers/base/dd.c:658
__driver_probe_device+0x1de/0x4b0 drivers/base/dd.c:798
driver_probe_device+0x4c/0x1a0 drivers/base/dd.c:828
__device_attach_driver+0x1d4/0x300 drivers/base/dd.c:956
bus_for_each_drv+0x157/0x1d0 drivers/base/bus.c:457
__device_attach+0x1e8/0x4b0 drivers/base/dd.c:1028
bus_probe_device+0x17c/0x1c0 drivers/base/bus.c:532
device_add+0x11f1/0x1b40 drivers/base/core.c:3625
usb_new_device+0xd80/0x1960 drivers/usb/core/hub.c:2589
hub_port_connect drivers/usb/core/hub.c:5440 [inline]
hub_port_connect_change drivers/usb/core/hub.c:5580 [inline]
port_event drivers/usb/core/hub.c:5740 [inline]
hub_event+0x2e62/0x4f30 drivers/usb/core/hub.c:5822
process_one_work+0xaa2/0x16f0 kernel/workqueue.c:2600
worker_thread+0x687/0x1110 kernel/workqueue.c:2751
kthread+0x33a/0x430 kernel/kthread.c:389
ret_from_fork+0x2c/0x70 arch/x86/kernel/process.c:145
ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:304
Freed by task 25:
kasan_save_stack+0x33/0x50 mm/kasan/common.c:45
kasan_set_track+0x25/0x30 mm/kasan/common.c:52
kasan_save_free_info+0x2b/0x40 mm/kasan/generic.c:522
____kasan_slab_free mm/kasan/common.c:236 [inline]
____kasan_slab_free+0x13f/0x190 mm/kasan/common.c:200
kasan_slab_free include/linux/kasan.h:162 [inline]
slab_free_hook mm/slub.c:1792 [inline]
slab_free_freelist_hook mm/slub.c:1818 [inline]
slab_free mm/slub.c:3801 [inline]
__kmem_cache_free+0xff/0x340 mm/slub.c:3814
ir_raw_event_free drivers/media/rc/rc-ir-raw.c:653 [inline]
ir_raw_event_free drivers/media/rc/rc-ir-raw.c:648 [inline]
ir_raw_event_unregister+0x2e3/0x400 drivers/media/rc/rc-ir-raw.c:676
rc_unregister_device+0x35c/0x410 drivers/media/rc/rc-main.c:2022
streamzap_disconnect+0xa6/0x1f0 drivers/media/rc/streamzap.c:388
usb_unbind_interface+0x1dd/0x8d0 drivers/usb/core/driver.c:458
device_remove drivers/base/dd.c:569 [inline]
device_remove+0x11f/0x170 drivers/base/dd.c:561
__device_release_driver drivers/base/dd.c:1270 [inline]
device_release_driver_internal+0x44a/0x610 drivers/base/dd.c:1293
bus_remove_device+0x22c/0x420 drivers/base/bus.c:574
device_del+0x39a/0xa40 drivers/base/core.c:3814
usb_disable_device+0x36c/0x7f0 drivers/usb/core/message.c:1416
usb_disconnect+0x2e1/0x890 drivers/usb/core/hub.c:2252
hub_port_connect drivers/usb/core/hub.c:5280 [inline]
hub_port_connect_change drivers/usb/core/hub.c:5580 [inline]
port_event drivers/usb/core/hub.c:5740 [inline]
hub_event+0x1be0/0x4f30 drivers/usb/core/hub.c:5822
process_one_work+0xaa2/0x16f0 kernel/workqueue.c:2600
worker_thread+0x687/0x1110 kernel/workqueue.c:2751
kthread+0x33a/0x430 kernel/kthread.c:389
ret_from_fork+0x2c/0x70 arch/x86/kernel/process.c:145
ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:304
The buggy address belongs to the object at ffff8881197e4000
which belongs to the cache kmalloc-8k of size 8192
The buggy address is located 4312 bytes inside of
freed 8192-byte region [ffff8881197e4000, ffff8881197e6000)
The buggy address belongs to the physical page:
page:ffffea000465f800 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1197e0
head:ffffea000465f800 order:3 entire_mapcount:0 nr_pages_mapped:0 pincount:0
flags: 0x200000000010200(slab|head|node=0|zone=2)
page_type: 0xffffffff()
raw: 0200000000010200 ffff888100042280 dead000000000122 0000000000000000
raw: 0000000000000000 0000000080020002 00000001ffffffff 0000000000000000
page dumped because: kasan: bad access detected
page_owner tracks the page as allocated
page last allocated via order 3, migratetype Unmovable, gfp_mask 0x1d2820(GFP_ATOMIC|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC|__GFP_HARDWALL), pid 7337, tgid 7337 (kworker/0:7), ts 515051545168, free_ts 137111078213
set_page_owner include/linux/page_owner.h:31 [inline]
post_alloc_hook+0x2d2/0x350 mm/page_alloc.c:1570
prep_new_page mm/page_alloc.c:1577 [inline]
get_page_from_freelist+0x10e1/0x2fd0 mm/page_alloc.c:3221
__alloc_pages+0x1d0/0x4a0 mm/page_alloc.c:4477
alloc_pages+0x1a9/0x270 mm/mempolicy.c:2292
alloc_slab_page mm/slub.c:1862 [inline]
allocate_slab+0x24e/0x380 mm/slub.c:2009
new_slab mm/slub.c:2062 [inline]
___slab_alloc+0x8bc/0x1570 mm/slub.c:3215
__slab_alloc.constprop.0+0x56/0xa0 mm/slub.c:3314
__slab_alloc_node mm/slub.c:3367 [inline]
slab_alloc_node mm/slub.c:3460 [inline]
__kmem_cache_alloc_node+0x132/0x310 mm/slub.c:3509
__do_kmalloc_node mm/slab_common.c:984 [inline]
__kmalloc_node_track_caller+0x4d/0x100 mm/slab_common.c:1005
kmalloc_reserve+0xef/0x270 net/core/skbuff.c:575
__alloc_skb+0x12b/0x330 net/core/skbuff.c:644
__netdev_alloc_skb+0x72/0x3f0 net/core/skbuff.c:708
netdev_alloc_skb include/linux/skbuff.h:3212 [inline]
dev_alloc_skb include/linux/skbuff.h:3225 [inline]
ath6kl_usb_post_recv_transfers.constprop.0+0x55/0x400 drivers/net/wireless/ath/ath6kl/usb.c:428
ath6kl_usb_start_recv_pipes drivers/net/wireless/ath/ath6kl/usb.c:498 [inline]
hif_start drivers/net/wireless/ath/ath6kl/usb.c:703 [inline]
ath6kl_usb_power_on+0x8e/0x160 drivers/net/wireless/ath/ath6kl/usb.c:1062
ath6kl_hif_power_on drivers/net/wireless/ath/ath6kl/hif-ops.h:136 [inline]
ath6kl_core_init+0x177/0x1180 drivers/net/wireless/ath/ath6kl/core.c:97
ath6kl_usb_probe+0xcd2/0x1440 drivers/net/wireless/ath/ath6kl/usb.c:1168
page last free stack trace:
reset_page_owner include/linux/page_owner.h:24 [inline]
free_pages_prepare mm/page_alloc.c:1161 [inline]
free_unref_page_prepare+0x4ec/0xb60 mm/page_alloc.c:2348
free_unref_page+0x33/0x2c0 mm/page_alloc.c:2443
__unfreeze_partials+0x21d/0x240 mm/slub.c:2647
qlink_free mm/kasan/quarantine.c:166 [inline]
qlist_free_all+0x6a/0x170 mm/kasan/quarantine.c:185
kasan_quarantine_reduce+0x18b/0x1d0 mm/kasan/quarantine.c:292
__kasan_slab_alloc+0x4a/0x70 mm/kasan/common.c:305
kasan_slab_alloc include/linux/kasan.h:186 [inline]
slab_post_alloc_hook+0x5a/0xd0 mm/slab.h:762
kmem_cache_alloc_bulk+0x3ff/0x750 mm/slub.c:4048
mt_alloc_bulk lib/maple_tree.c:164 [inline]
mas_alloc_nodes+0x39c/0x830 lib/maple_tree.c:1304
mas_node_count_gfp lib/maple_tree.c:1362 [inline]
mas_preallocate+0x2b1/0x370 lib/maple_tree.c:5547
vma_iter_prealloc mm/internal.h:1032 [inline]
vma_expand+0x26f/0xbc0 mm/mmap.c:666
mmap_region+0x1cf8/0x2470 mm/mmap.c:2716
do_mmap+0x884/0xee0 mm/mmap.c:1363
vm_mmap_pgoff+0x1a6/0x3a0 mm/util.c:543
ksys_mmap_pgoff+0x422/0x5b0 mm/mmap.c:1409
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x38/0xb0 arch/x86/entry/common.c:80
Memory state around the buggy address:
ffff8881197e4f80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
ffff8881197e5000: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
>ffff8881197e5080: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
^
ffff8881197e5100: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
ffff8881197e5180: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
==================================================================
----------------
Code disassembly (best guess):
0: f5 cmc
1: 53 push %rbx
2: 48 8b 74 24 10 mov 0x10(%rsp),%rsi
7: 48 89 fb mov %rdi,%rbx
a: 48 83 c7 18 add $0x18,%rdi
e: e8 c6 41 ec fa call 0xfaec41d9
13: 48 89 df mov %rbx,%rdi
16: e8 9e c0 ec fa call 0xfaecc0b9
1b: f7 c5 00 02 00 00 test $0x200,%ebp
21: 75 1f jne 0x42
23: 9c pushf
24: 58 pop %rax
25: f6 c4 02 test $0x2,%ah
28: 75 2f jne 0x59
* 2a: bf 01 00 00 00 mov $0x1,%edi <-- trapping instruction
2f: e8 15 47 e1 fa call 0xfae14749
34: 65 8b 05 26 57 c2 79 mov %gs:0x79c25726(%rip),%eax # 0x79c25761
3b: 85 c0 test %eax,%eax
3d: 74 12 je 0x51
3f: 5b pop %rbx