==================================================================
BUG: KASAN: slab-use-after-free in rose_timer_expiry+0x471/0x4b0
Read of size 2 at addr ffff8880396f302a by task syz.2.10847/30423

CPU: 1 UID: 0 PID: 30423 Comm: syz.2.10847 Not tainted 6.17.0-rc1-syzkaller-00207-g815957293639-dirty #0 PREEMPT(full) 
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.2-debian-1.16.2-1 04/01/2014
Call Trace:
 <IRQ>
 dump_stack_lvl+0x189/0x250
 print_report+0xca/0x240
 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:wp512_process_buffer+0x1875/0x2260
Code: 24 18 49 31 dd 4c 31 fd 4c 31 f5 4c 31 ed 49 33 2c 24 48 89 2c 24 48 8b 44 24 58 48 c1 e8 38 4c 8d 24 c5 a0 87 de 8b 4c 89 e0 <48> c1 e8 03 49 be 00 00 00 00 00 fc ff df 42 80 3c 30 00 74 08 4c
RSP: 0018:ffffc9000332f4a0 EFLAGS: 00000207
RAX: ffffffff8bde8938 RBX: 299135da531c5aec RCX: dffffc0000000000
RDX: ffffc900085d2000 RSI: 000000000007ffff RDI: 0000000000080000
RBP: db5407257674ce2d R08: da9f5d7420855fa7 R09: b828d45eeaa01633
R10: 9b5dc921a81da43b R11: 726cabf62a3cfaca R12: ffffffff8bde8938
R13: a17ee800f52fa797 R14: 57dcae8ba572dcdc R15: 5fc23ebe9d5f5f61
 wp512_update+0x196/0x1d0
 crypto_shash_finup+0x38b/0x6c0
 shash_ahash_update+0x213/0x2f0
 hash_sendmsg+0x96b/0x11d0
 __sock_sendmsg+0x21c/0x270
 ____sys_sendmsg+0x52d/0x830
 ___sys_sendmsg+0x21f/0x2a0
 __sys_sendmmsg+0x227/0x430
 __x64_sys_sendmmsg+0xa0/0xc0
 do_syscall_64+0xfa/0x3b0
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f0315f8ebe9
Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 a8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f0316d42038 EFLAGS: 00000246 ORIG_RAX: 0000000000000133
RAX: ffffffffffffffda RBX: 00007f03161b5fa0 RCX: 00007f0315f8ebe9
RDX: 0000000000000001 RSI: 0000200000000040 RDI: 0000000000000004
RBP: 00007f0316011e19 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000040800 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f03161b6038 R14: 00007f03161b5fa0 R15: 00007ffeb476da68
 </TASK>

Allocated by task 30372:
 kasan_save_track+0x3e/0x80
 __kasan_kmalloc+0x93/0xb0
 __kvmalloc_node_noprof+0x30d/0x5f0
 ib_setup_port_attrs+0x2cb/0x2070
 add_one_compat_dev+0x3d6/0x5c0
 rdma_dev_init_net+0x1dd/0x270
 ops_init+0x35c/0x5c0
 setup_net+0x10c/0x320
 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 12:
 kasan_save_track+0x3e/0x80
 kasan_save_free_info+0x46/0x50
 __kasan_slab_free+0x5b/0x80
 kfree+0x18e/0x440
 kobject_put+0x22b/0x480
 ib_free_port_attrs+0x336/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

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

The buggy address belongs to the physical page:
page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x396f0
head: order:2 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0
flags: 0xfff00000000040(head|node=0|zone=1|lastcpupid=0x7ff)
page_type: f5(slab)
raw: 00fff00000000040 ffff88801a441c80 dead000000000100 dead000000000122
raw: 0000000000000000 0000000000100010 00000000f5000000 0000000000000000
head: 00fff00000000040 ffff88801a441c80 dead000000000100 dead000000000122
head: 0000000000000000 0000000000100010 00000000f5000000 0000000000000000
head: 00fff00000000002 ffffea0000e5bc01 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 5849, tgid 5849 (syz-executor), ts 60678755423, free_ts 0
 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/0x370
 ___slab_alloc+0xbeb/0x1410
 __kmalloc_noprof+0x305/0x4f0
 fib6_info_alloc+0x30/0xf0
 ip6_route_info_create+0x142/0x860
 ip6_route_add+0x49/0x1b0
 addrconf_add_dev+0x24f/0x340
 inet6_addr_add+0x1a1/0xc00
 inet6_rtm_newaddr+0x93d/0xd20
 rtnetlink_rcv_msg+0x7cf/0xb70
 netlink_rcv_skb+0x208/0x470
 netlink_unicast+0x82f/0x9e0
page_owner free stack trace missing

Memory state around the buggy address:
 ffff8880396f2f00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
 ffff8880396f2f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
>ffff8880396f3000: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
                                  ^
 ffff8880396f3080: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
 ffff8880396f3100: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
==================================================================
