==================================================================
BUG: KASAN: slab-use-after-free in rose_timer_expiry+0x471/0x4b0
Read of size 2 at addr ffff88810e94e42a by task kworker/u8:4/6035

CPU: 1 UID: 0 PID: 6035 Comm: kworker/u8:4 Not tainted 6.16.0-rc6-syzkaller-00135-gcf074eca0065-dirty #0 PREEMPT(full) 
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.2-debian-1.16.2-1 04/01/2014
Workqueue: netns cleanup_net
Call Trace:
 <IRQ>
 dump_stack_lvl+0x189/0x250
 print_report+0xca/0x230
 kasan_report+0x118/0x150
 rose_timer_expiry+0x471/0x4b0
 call_timer_fn+0x17e/0x5f0
 __run_timer_base+0x61a/0x860
 run_timer_softirq+0xb7/0x180
 handle_softirqs+0x286/0x870
 __irq_exit_rcu+0xca/0x1f0
 irq_exit_rcu+0x9/0x30
 sysvec_apic_timer_interrupt+0xa6/0xc0
 </IRQ>
 <TASK>
 asm_sysvec_apic_timer_interrupt+0x1a/0x20
RIP: 0010:lock_is_held_type+0x137/0x190
Code: 01 75 44 48 c7 04 24 00 00 00 00 9c 8f 04 24 f7 04 24 00 02 00 00 75 4c 41 f7 c4 00 02 00 00 74 01 fb 65 48 8b 05 f9 22 32 07 <48> 3b 44 24 08 75 43 89 d8 48 83 c4 10 5b 41 5c 41 5d 41 5e 41 5f
RSP: 0018:ffffc90004ce7558 EFLAGS: 00000206
RAX: 0f57fc96de99cb00 RBX: 0000000000000001 RCX: 0f57fc96de99cb00
RDX: 0000000000000004 RSI: ffffffff8db83333 RDI: ffffffff8be28c00
RBP: 00000000ffffffff R08: 0000000000000000 R09: ffffffff825be67c
R10: dffffc0000000000 R11: ffffed1024a4f079 R12: 0000000000000246
R13: ffff888106f81cc0 R14: ffff88801b2f7988 R15: 0000000000000003
 kernfs_drain+0x133/0x5e0
 __kernfs_remove+0x33b/0x570
 kernfs_remove_by_name_ns+0xaf/0x130
 sysfs_remove_group+0xfc/0x2c0
 sysfs_remove_groups+0x54/0xb0
 ib_free_port_attrs+0x281/0x3b0
 rdma_dev_exit_net+0x1d8/0x340
 ops_undo_list+0x49a/0x990
 cleanup_net+0x4c5/0x800
 process_scheduled_works+0xae1/0x17b0
 worker_thread+0x8a0/0xda0
 kthread+0x711/0x8a0
 ret_from_fork+0x3fc/0x770
 ret_from_fork_asm+0x1a/0x30
 </TASK>

Allocated by task 23527:
 kasan_save_track+0x3e/0x80
 __kasan_kmalloc+0x93/0xb0
 __kmalloc_cache_noprof+0x230/0x3d0
 device_add+0xbe/0xb50
 netdev_register_kobject+0x156/0x2f0
 register_netdevice+0x126c/0x1ae0
 __ip_tunnel_create+0x3e7/0x560
 ip_tunnel_init_net+0x2ba/0x800
 ops_init+0x35c/0x5c0
 setup_net+0x219/0x4b0
 copy_net_ns+0x31b/0x4d0
 create_new_namespaces+0x3f3/0x720
 unshare_nsproxy_namespaces+0x11c/0x170
 ksys_unshare+0x4c8/0x8c0
 __x64_sys_unshare+0x38/0x50
 do_syscall_64+0xfa/0x3b0
 entry_SYSCALL_64_after_hwframe+0x77/0x7f

Freed by task 6035:
 kasan_save_track+0x3e/0x80
 kasan_save_free_info+0x46/0x50
 __kasan_slab_free+0x62/0x70
 kfree+0x18e/0x440
 kobject_put+0x22b/0x480
 netdev_run_todo+0xd2e/0xea0
 ops_undo_list+0x3e1/0x990
 cleanup_net+0x4c5/0x800
 process_scheduled_works+0xae1/0x17b0
 worker_thread+0x8a0/0xda0
 kthread+0x711/0x8a0
 ret_from_fork+0x3fc/0x770
 ret_from_fork_asm+0x1a/0x30

The buggy address belongs to the object at ffff88810e94e400
 which belongs to the cache kmalloc-512 of size 512
The buggy address is located 42 bytes inside of
 freed 512-byte region [ffff88810e94e400, ffff88810e94e600)

The buggy address belongs to the physical page:
page: refcount:0 mapcount:0 mapping:0000000000000000 index:0xffff88810e94cc00 pfn:0x10e94c
head: order:2 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0
flags: 0x57ff00000000240(workingset|head|node=1|zone=2|lastcpupid=0x7ff)
page_type: f5(slab)
raw: 057ff00000000240 ffff88801a441c80 ffffea00041b7210 ffffea0004280110
raw: ffff88810e94cc00 000000000010000c 00000000f5000000 0000000000000000
head: 057ff00000000240 ffff88801a441c80 ffffea00041b7210 ffffea0004280110
head: ffff88810e94cc00 000000000010000c 00000000f5000000 0000000000000000
head: 057ff00000000002 ffffea00043a5301 00000000ffffffff 00000000ffffffff
head: ffffffffffffffff 0000000000000000 00000000ffffffff 0000000000000004
page dumped because: kasan: bad access detected
page_owner tracks the page as allocated
page last allocated via order 2, migratetype Unmovable, gfp_mask 0xd20c0(__GFP_IO|__GFP_FS|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC), pid 5925, tgid 5924 (syz.1.8), ts 56766452931, free_ts 56759137221
 post_alloc_hook+0x240/0x2a0
 get_page_from_freelist+0x21e4/0x22c0
 __alloc_frozen_pages_noprof+0x181/0x370
 alloc_pages_mpol+0x232/0x4a0
 allocate_slab+0x8a/0x3b0
 ___slab_alloc+0xbfc/0x1480
 __kmalloc_cache_noprof+0x296/0x3d0
 device_add+0xbe/0xb50
 netdev_register_kobject+0x156/0x2f0
 register_netdevice+0x126c/0x1ae0
 __ip_tunnel_create+0x3e7/0x560
 ip_tunnel_init_net+0x2ba/0x800
 vti_init_net+0x2f/0x100
 ops_init+0x35c/0x5c0
 setup_net+0x219/0x4b0
 copy_net_ns+0x31b/0x4d0
page last free pid 5925 tgid 5924 stack trace:
 __free_frozen_pages+0xc71/0xe70
 stack_depot_save_flags+0x445/0x900
 kasan_save_track+0x4f/0x80
 __kasan_kmalloc+0x93/0xb0
 __kmalloc_node_noprof+0x276/0x4e0
 alloc_slab_obj_exts+0x39/0xa0
 __memcg_slab_post_alloc_hook+0x31e/0x7f0
 __kvmalloc_node_noprof+0x466/0x5f0
 alloc_netdev_mqs+0x8e5/0x11e0
 __ip_tunnel_create+0x349/0x560
 ip_tunnel_init_net+0x2ba/0x800
 ops_init+0x35c/0x5c0
 setup_net+0x219/0x4b0
 copy_net_ns+0x31b/0x4d0
 create_new_namespaces+0x3f3/0x720
 unshare_nsproxy_namespaces+0x11c/0x170

Memory state around the buggy address:
 ffff88810e94e300: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
 ffff88810e94e380: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
>ffff88810e94e400: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
                                  ^
 ffff88810e94e480: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
 ffff88810e94e500: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
==================================================================
