bisecting fixing commit since 555161ee1b7a74e77ca70fd14ed8a5137c8108ac building syzkaller on 2e29b534005e52c57d726201644ea28ba33a9a3d testing commit 555161ee1b7a74e77ca70fd14ed8a5137c8108ac with gcc (GCC) 8.1.0 kernel signature: a363c0fcb3a83634764d7ea137e31e2cb0deba66c28cacfaac8c426951fc0a9d run #0: crashed: general protection fault in scatterwalk_copychunks run #1: crashed: general protection fault in scatterwalk_copychunks run #2: crashed: KASAN: slab-out-of-bounds Read in scatterwalk_copychunks run #3: crashed: KASAN: slab-out-of-bounds Read in scatterwalk_copychunks run #4: crashed: general protection fault in scatterwalk_copychunks run #5: crashed: general protection fault in scatterwalk_copychunks run #6: crashed: general protection fault in scatterwalk_copychunks run #7: crashed: general protection fault in corrupted run #8: crashed: KASAN: use-after-free Read in scatterwalk_copychunks run #9: crashed: KASAN: slab-out-of-bounds Read in scatterwalk_copychunks testing current HEAD c37da90efff5f183bea6ae4c2af33571f61fe317 testing commit c37da90efff5f183bea6ae4c2af33571f61fe317 with gcc (GCC) 8.1.0 kernel signature: 52b5d5c019709dae62972ffe15c43a9f1782e39453eb693cb533a2bbe1ca13bc run #0: crashed: KASAN: use-after-free Read in scatterwalk_copychunks run #1: crashed: KASAN: slab-out-of-bounds Read in scatterwalk_copychunks run #2: crashed: general protection fault in scatterwalk_copychunks run #3: crashed: KASAN: slab-out-of-bounds Read in scatterwalk_copychunks run #4: crashed: general protection fault in scatterwalk_copychunks run #5: crashed: general protection fault in scatterwalk_copychunks run #6: crashed: KASAN: slab-out-of-bounds Read in scatterwalk_copychunks run #7: crashed: general protection fault in scatterwalk_copychunks run #8: crashed: KASAN: slab-out-of-bounds Read in scatterwalk_copychunks run #9: crashed: KASAN: slab-out-of-bounds Read in scatterwalk_copychunks revisions tested: 2, total time: 28m41.731478031s (build: 20m15.874122525s, test: 6m34.041167594s) the crash still happens on HEAD commit msg: Linux 4.19.143 crash: KASAN: slab-out-of-bounds Read in scatterwalk_copychunks fail_dump lib/fault-inject.c:51 [inline] should_fail.cold.4+0x5/0x13 lib/fault-inject.c:149 __should_failslab+0xba/0xf0 mm/failslab.c:32 should_failslab+0x9/0x14 mm/slab_common.c:1588 slab_pre_alloc_hook mm/slab.h:424 [inline] slab_alloc mm/slab.c:3383 [inline] __do_kmalloc mm/slab.c:3725 [inline] __kmalloc+0x2dd/0x770 mm/slab.c:3736 ================================================================== BUG: KASAN: slab-out-of-bounds in memcpy include/linux/string.h:373 [inline] BUG: KASAN: slab-out-of-bounds in memcpy_dir crypto/scatterwalk.c:28 [inline] BUG: KASAN: slab-out-of-bounds in scatterwalk_copychunks+0x1e1/0x610 crypto/scatterwalk.c:43 kmalloc include/linux/slab.h:520 [inline] aead_request_alloc include/crypto/aead.h:425 [inline] tls_push_record+0xff/0x1600 net/tls/tls_sw.c:209 Read of size 4096 at addr ffff888097219000 by task syz-executor.5/7900 tls_sw_sendpage+0x458/0xc00 net/tls/tls_sw.c:585 inet_sendpage+0x122/0x600 net/ipv4/af_inet.c:815 kernel_sendpage+0x60/0xd0 net/socket.c:3378 sock_sendpage+0x6d/0xd0 net/socket.c:847 pipe_to_sendpage+0x212/0x430 fs/splice.c:452 splice_from_pipe_feed fs/splice.c:503 [inline] __splice_from_pipe+0x2cb/0x720 fs/splice.c:627 splice_from_pipe+0xbb/0x120 fs/splice.c:662 generic_splice_sendpage+0x10/0x20 fs/splice.c:833 do_splice_from fs/splice.c:852 [inline] do_splice+0x4fd/0x12d0 fs/splice.c:1154 __do_sys_splice fs/splice.c:1428 [inline] __se_sys_splice fs/splice.c:1408 [inline] __x64_sys_splice+0x248/0x300 fs/splice.c:1408 do_syscall_64+0xd0/0x4e0 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x459aa9 Code: 7d b7 fb ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 90 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 0f 83 4b b7 fb ff c3 66 2e 0f 1f 84 00 00 00 00 RSP: 002b:00007f389cb98c78 EFLAGS: 00000246 ORIG_RAX: 0000000000000113 RAX: ffffffffffffffda RBX: 00007f389cb98c90 RCX: 0000000000459aa9 RDX: 0000000000000004 RSI: 0000000000000000 RDI: 0000000000000003 RBP: 000000000075bf20 R08: 000000011d100000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 00007f389cb996d4 R13: 00000000004c94f8 R14: 00000000004dfe58 R15: 0000000000000005 CPU: 1 PID: 7900 Comm: syz-executor.5 Not tainted 4.19.143-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x123/0x177 lib/dump_stack.c:118 print_address_description.cold.8+0x9/0x1ff mm/kasan/report.c:256 kasan_report_error mm/kasan/report.c:354 [inline] kasan_report.cold.9+0x242/0x309 mm/kasan/report.c:412 check_memory_region_inline mm/kasan/kasan.c:260 [inline] check_memory_region+0x13e/0x1b0 mm/kasan/kasan.c:267 memcpy+0x23/0x50 mm/kasan/kasan.c:302 memcpy include/linux/string.h:373 [inline] memcpy_dir crypto/scatterwalk.c:28 [inline] scatterwalk_copychunks+0x1e1/0x610 crypto/scatterwalk.c:43 scatterwalk_map_and_copy+0x128/0x190 crypto/scatterwalk.c:72 gcmaes_encrypt.constprop.15+0x6d6/0xda0 arch/x86/crypto/aesni-intel_glue.c:956 generic_gcmaes_encrypt+0xfd/0x150 arch/x86/crypto/aesni-intel_glue.c:1297 crypto_aead_encrypt include/crypto/aead.h:335 [inline] gcmaes_wrapper_encrypt+0x109/0x180 arch/x86/crypto/aesni-intel_glue.c:1130 crypto_aead_encrypt include/crypto/aead.h:335 [inline] tls_do_encryption net/tls/tls_sw.c:193 [inline] tls_push_record+0x9ae/0x1600 net/tls/tls_sw.c:228 tls_sw_sendpage+0x458/0xc00 net/tls/tls_sw.c:585 inet_sendpage+0x122/0x600 net/ipv4/af_inet.c:815 kernel_sendpage+0x60/0xd0 net/socket.c:3378 sock_sendpage+0x6d/0xd0 net/socket.c:847 pipe_to_sendpage+0x212/0x430 fs/splice.c:452 splice_from_pipe_feed fs/splice.c:503 [inline] __splice_from_pipe+0x2cb/0x720 fs/splice.c:627 splice_from_pipe+0xbb/0x120 fs/splice.c:662 generic_splice_sendpage+0x10/0x20 fs/splice.c:833 do_splice_from fs/splice.c:852 [inline] do_splice+0x4fd/0x12d0 fs/splice.c:1154 __do_sys_splice fs/splice.c:1428 [inline] __se_sys_splice fs/splice.c:1408 [inline] __x64_sys_splice+0x248/0x300 fs/splice.c:1408 do_syscall_64+0xd0/0x4e0 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x459aa9 Code: 7d b7 fb ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 90 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 0f 83 4b b7 fb ff c3 66 2e 0f 1f 84 00 00 00 00 RSP: 002b:00007fbd07e56c78 EFLAGS: 00000246 ORIG_RAX: 0000000000000113 RAX: ffffffffffffffda RBX: 00007fbd07e56c90 RCX: 0000000000459aa9 RDX: 0000000000000004 RSI: 0000000000000000 RDI: 0000000000000003 RBP: 000000000075bf20 R08: 000000011d100000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 00007fbd07e576d4 R13: 00000000004c94f8 R14: 00000000004dfe58 R15: 0000000000000005 Allocated by task 6894: save_stack+0x43/0xd0 mm/kasan/kasan.c:448 set_track mm/kasan/kasan.c:460 [inline] kasan_kmalloc+0xc7/0xe0 mm/kasan/kasan.c:553 kasan_slab_alloc+0x12/0x20 mm/kasan/kasan.c:490 kmem_cache_alloc+0x12e/0x730 mm/slab.c:3559 kmem_cache_zalloc include/linux/slab.h:699 [inline] fill_pool lib/debugobjects.c:134 [inline] __debug_object_init+0x7dc/0xd70 lib/debugobjects.c:379 debug_object_init+0x16/0x20 lib/debugobjects.c:431 debug_timer_init kernel/time/timer.c:713 [inline] debug_init kernel/time/timer.c:766 [inline] init_timer_key+0x2e/0x270 kernel/time/timer.c:815 neigh_alloc net/core/neighbour.c:338 [inline] __neigh_create+0x450/0x1810 net/core/neighbour.c:501 ip6_finish_output2+0x9d7/0x2200 net/ipv6/ip6_output.c:117 ip6_finish_output+0x3c6/0xa90 net/ipv6/ip6_output.c:154 NF_HOOK_COND include/linux/netfilter.h:278 [inline] ip6_output+0x1bf/0x660 net/ipv6/ip6_output.c:171 dst_output include/net/dst.h:455 [inline] NF_HOOK include/linux/netfilter.h:289 [inline] ndisc_send_skb+0xcc8/0x12d0 net/ipv6/ndisc.c:491 ndisc_send_ns+0x2d3/0x800 net/ipv6/ndisc.c:633 addrconf_dad_work+0x9b9/0xfc0 net/ipv6/addrconf.c:4075 process_one_work+0x830/0x1670 kernel/workqueue.c:2155 worker_thread+0x85/0xb60 kernel/workqueue.c:2298 kthread+0x347/0x410 kernel/kthread.c:259 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:415 Freed by task 0: (stack is not available) The buggy address belongs to the object at ffff888097219000 which belongs to the cache debug_objects_cache of size 40 The buggy address is located 0 bytes inside of 40-byte region [ffff888097219000, ffff888097219028) The buggy address belongs to the page: page:ffffea00025c8640 count:1 mapcount:0 mapping:ffff88812c301dc0 index:0xffff888097219fb9 flags: 0x1fffc0000000100(slab) raw: 01fffc0000000100 ffffea00026cae08 ffffea000262d308 ffff88812c301dc0 raw: ffff888097219fb9 ffff888097219000 000000010000003e 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff888097218f00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff888097218f80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff888097219000: 00 00 00 00 00 fc fc fb fb fb fb fb fc fc 00 00 ^ ffff888097219080: 00 00 00 fc fc 00 00 00 00 00 fc fc 00 00 00 00 ffff888097219100: 00 fc fc 00 00 00 00 00 fc fc 00 00 00 00 00 fc ==================================================================