ci starts bisection 2022-07-26 04:44:26.076159206 +0000 UTC m=+10465.387434696 bisecting fixing commit since 2fe1020d73ca0467b5383b0a3e459a1d29902762 building syzkaller on 744a39e220cece33e207035facce6c5ae161b775 testing commit 2fe1020d73ca0467b5383b0a3e459a1d29902762 compiler: gcc (GCC) 10.2.1 20210217, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: 1a60c60b482bc671afa0545a911bbdf68c9a9f7b2e8419854d0b0ecfbc42dd6b all runs: crashed: KASAN: slab-out-of-bounds Read in sk_psock_get testing current HEAD e0dccc3b76fb35bb257b4118367a883073d7390e testing commit e0dccc3b76fb35bb257b4118367a883073d7390e compiler: gcc (GCC) 10.2.1 20210217, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: da948069d5932042218d06c5ee3cb6b680fe0cc48e9c7fa10ac1e2f901665e3a all runs: crashed: KASAN: slab-out-of-bounds Read in sk_psock_get revisions tested: 2, total time: 21m50.876461756s (build: 14m27.185299406s, test: 6m51.323522441s) the crash still happens on HEAD commit msg: Linux 5.19-rc8 crash: KASAN: slab-out-of-bounds Read in sk_psock_get ================================================================== BUG: KASAN: slab-out-of-bounds in instrument_atomic_read include/linux/instrumented.h:71 [inline] BUG: KASAN: slab-out-of-bounds in atomic_read include/linux/atomic/atomic-instrumented.h:27 [inline] BUG: KASAN: slab-out-of-bounds in refcount_read include/linux/refcount.h:147 [inline] BUG: KASAN: slab-out-of-bounds in __refcount_add_not_zero include/linux/refcount.h:152 [inline] BUG: KASAN: slab-out-of-bounds in __refcount_inc_not_zero include/linux/refcount.h:227 [inline] BUG: KASAN: slab-out-of-bounds in refcount_inc_not_zero include/linux/refcount.h:245 [inline] BUG: KASAN: slab-out-of-bounds in sk_psock_get+0xe4/0x2c0 include/linux/skmsg.h:439 Read of size 4 at addr ffff8880225c3e78 by task syz-executor.0/4110 CPU: 1 PID: 4110 Comm: syz-executor.0 Not tainted 5.19.0-rc8-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 06/29/2022 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x57/0x7d lib/dump_stack.c:106 print_address_description.constprop.0.cold+0xeb/0x467 mm/kasan/report.c:313 print_report mm/kasan/report.c:429 [inline] kasan_report.cold+0xf4/0x1c6 mm/kasan/report.c:491 check_region_inline mm/kasan/generic.c:183 [inline] kasan_check_range+0x13d/0x180 mm/kasan/generic.c:189 instrument_atomic_read include/linux/instrumented.h:71 [inline] atomic_read include/linux/atomic/atomic-instrumented.h:27 [inline] refcount_read include/linux/refcount.h:147 [inline] __refcount_add_not_zero include/linux/refcount.h:152 [inline] __refcount_inc_not_zero include/linux/refcount.h:227 [inline] refcount_inc_not_zero include/linux/refcount.h:245 [inline] sk_psock_get+0xe4/0x2c0 include/linux/skmsg.h:439 tls_sw_recvmsg+0x134/0x1330 net/tls/tls_sw.c:1747 inet6_recvmsg+0xf0/0x490 net/ipv6/af_inet6.c:671 sock_recvmsg_nosec net/socket.c:995 [inline] sock_recvmsg net/socket.c:1013 [inline] sock_recvmsg net/socket.c:1009 [inline] ____sys_recvmsg+0x262/0x630 net/socket.c:2707 ___sys_recvmsg+0xe2/0x1a0 net/socket.c:2749 do_recvmmsg+0x1cf/0x550 net/socket.c:2843 __sys_recvmmsg net/socket.c:2922 [inline] __do_sys_recvmmsg net/socket.c:2945 [inline] __se_sys_recvmmsg net/socket.c:2938 [inline] __x64_sys_recvmmsg+0x19a/0x200 net/socket.c:2938 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd RIP: 0033:0x7fa8984890e9 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 b8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fa899683168 EFLAGS: 00000246 ORIG_RAX: 000000000000012b RAX: ffffffffffffffda RBX: 00007fa89859bf60 RCX: 00007fa8984890e9 RDX: 000000000000000a RSI: 00000000200030c0 RDI: 0000000000000005 RBP: 00007fa8984e308d R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000010000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007ffc95cd236f R14: 00007fa899683300 R15: 0000000000022000 Allocated by task 4110: kasan_save_stack+0x1e/0x40 mm/kasan/common.c:38 kasan_set_track mm/kasan/common.c:45 [inline] set_alloc_info mm/kasan/common.c:436 [inline] __kasan_slab_alloc+0x85/0xb0 mm/kasan/common.c:469 kasan_slab_alloc include/linux/kasan.h:224 [inline] slab_post_alloc_hook mm/slab.h:750 [inline] slab_alloc mm/slab.c:3302 [inline] __kmem_cache_alloc_lru mm/slab.c:3479 [inline] kmem_cache_alloc+0x265/0x560 mm/slab.c:3499 kmem_cache_zalloc include/linux/slab.h:723 [inline] kcm_attach net/kcm/kcmsock.c:1405 [inline] kcm_attach_ioctl net/kcm/kcmsock.c:1490 [inline] kcm_ioctl+0x3d2/0x10b0 net/kcm/kcmsock.c:1696 sock_do_ioctl+0xc9/0x1c0 net/socket.c:1169 sock_ioctl+0x278/0x510 net/socket.c:1286 vfs_ioctl fs/ioctl.c:51 [inline] __do_sys_ioctl fs/ioctl.c:870 [inline] __se_sys_ioctl fs/ioctl.c:856 [inline] __x64_sys_ioctl+0x11f/0x190 fs/ioctl.c:856 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd Last potentially related work creation: kasan_save_stack+0x1e/0x40 mm/kasan/common.c:38 __kasan_record_aux_stack+0x7e/0x90 mm/kasan/generic.c:348 insert_work+0x43/0x2e0 kernel/workqueue.c:1358 __queue_work+0x4e6/0xdc0 kernel/workqueue.c:1517 queue_work_on+0x70/0x80 kernel/workqueue.c:1545 kcm_attach net/kcm/kcmsock.c:1466 [inline] kcm_attach_ioctl net/kcm/kcmsock.c:1490 [inline] kcm_ioctl+0xc79/0x10b0 net/kcm/kcmsock.c:1696 sock_do_ioctl+0xc9/0x1c0 net/socket.c:1169 sock_ioctl+0x278/0x510 net/socket.c:1286 vfs_ioctl fs/ioctl.c:51 [inline] __do_sys_ioctl fs/ioctl.c:870 [inline] __se_sys_ioctl fs/ioctl.c:856 [inline] __x64_sys_ioctl+0x11f/0x190 fs/ioctl.c:856 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd The buggy address belongs to the object at ffff8880225c3bc0 which belongs to the cache kcm_psock_cache of size 568 The buggy address is located 128 bytes to the right of 568-byte region [ffff8880225c3bc0, ffff8880225c3df8) The buggy address belongs to the physical page: page:ffffea0000897080 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x225c2 head:ffffea0000897080 order:1 compound_mapcount:0 compound_pincount:0 flags: 0xfff00000010200(slab|head|node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000010200 ffff888025981c50 ffff888025981c50 ffff88814a66ff00 raw: 0000000000000000 ffff8880225c2040 000000010000000b 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 1, migratetype Unmovable, gfp_mask 0x3420c0(__GFP_IO|__GFP_FS|__GFP_NOWARN|__GFP_COMP|__GFP_HARDWALL|__GFP_THISNODE), pid 4110, tgid 4109 (syz-executor.0), ts 111589089151, free_ts 111578898793 prep_new_page mm/page_alloc.c:2456 [inline] get_page_from_freelist+0x19d3/0x3b30 mm/page_alloc.c:4198 __alloc_pages+0x1c7/0x510 mm/page_alloc.c:5426 __alloc_pages_node include/linux/gfp.h:587 [inline] kmem_getpages mm/slab.c:1363 [inline] cache_grow_begin+0x75/0x350 mm/slab.c:2569 cache_alloc_refill+0x27f/0x380 mm/slab.c:2942 ____cache_alloc mm/slab.c:3024 [inline] ____cache_alloc mm/slab.c:3007 [inline] __do_cache_alloc mm/slab.c:3253 [inline] slab_alloc mm/slab.c:3295 [inline] __kmem_cache_alloc_lru mm/slab.c:3479 [inline] kmem_cache_alloc+0x450/0x560 mm/slab.c:3499 kmem_cache_zalloc include/linux/slab.h:723 [inline] kcm_attach net/kcm/kcmsock.c:1405 [inline] kcm_attach_ioctl net/kcm/kcmsock.c:1490 [inline] kcm_ioctl+0x3d2/0x10b0 net/kcm/kcmsock.c:1696 sock_do_ioctl+0xc9/0x1c0 net/socket.c:1169 sock_ioctl+0x278/0x510 net/socket.c:1286 vfs_ioctl fs/ioctl.c:51 [inline] __do_sys_ioctl fs/ioctl.c:870 [inline] __se_sys_ioctl fs/ioctl.c:856 [inline] __x64_sys_ioctl+0x11f/0x190 fs/ioctl.c:856 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd page last free stack trace: reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1371 [inline] free_pcp_prepare+0x549/0xd20 mm/page_alloc.c:1421 free_unref_page_prepare mm/page_alloc.c:3343 [inline] free_unref_page+0x19/0x6a0 mm/page_alloc.c:3438 slab_destroy mm/slab.c:1615 [inline] slabs_destroy+0x89/0xc0 mm/slab.c:1635 cache_flusharray mm/slab.c:3397 [inline] ___cache_free+0x34e/0x670 mm/slab.c:3460 qlink_free mm/kasan/quarantine.c:168 [inline] qlist_free_all+0x4f/0x1b0 mm/kasan/quarantine.c:187 kasan_quarantine_reduce+0x180/0x200 mm/kasan/quarantine.c:294 __kasan_slab_alloc+0x97/0xb0 mm/kasan/common.c:446 kasan_slab_alloc include/linux/kasan.h:224 [inline] slab_post_alloc_hook mm/slab.h:750 [inline] slab_alloc mm/slab.c:3302 [inline] __kmem_cache_alloc_lru mm/slab.c:3479 [inline] kmem_cache_alloc+0x265/0x560 mm/slab.c:3499 getname_flags.part.0+0x4a/0x440 fs/namei.c:139 do_sys_openat2+0xd2/0x3f0 fs/open.c:1272 do_sys_open fs/open.c:1294 [inline] __do_sys_openat fs/open.c:1310 [inline] __se_sys_openat fs/open.c:1305 [inline] __x64_sys_openat+0x11b/0x1d0 fs/open.c:1305 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd Memory state around the buggy address: ffff8880225c3d00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff8880225c3d80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc >ffff8880225c3e00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff8880225c3e80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff8880225c3f00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================