BUG: sleeping function called from invalid context at arch/x86/mm/fault.c:1372 in_atomic(): 0, irqs_disabled(): 1, pid: 11366, name: syz-executor7 2 locks held by syz-executor7/11366: #0: (sk_lock-AF_ALG){+.+.}, at: [<000000003565009a>] lock_sock include/net/sock.h:1465 [inline] #0: (sk_lock-AF_ALG){+.+.}, at: [<000000003565009a>] skcipher_recvmsg+0xb3/0xf20 crypto/algif_skcipher.c:163 #1: (&mm->mmap_sem){++++}, at: [<00000000cf7d2463>] __do_page_fault+0x32d/0xc90 arch/x86/mm/fault.c:1358 irq event stamp: 546 hardirqs last enabled at (545): [<00000000ca9cfc95>] slab_alloc mm/slab.c:3378 [inline] hardirqs last enabled at (545): [<00000000ca9cfc95>] __do_kmalloc mm/slab.c:3709 [inline] hardirqs last enabled at (545): [<00000000ca9cfc95>] __kmalloc+0x23a/0x760 mm/slab.c:3720 hardirqs last disabled at (546): [<00000000d6209391>] kfree+0x6a/0x250 mm/slab.c:3800 softirqs last enabled at (540): [<00000000f47c947a>] lock_sock_nested+0x91/0x110 net/core/sock.c:2765 softirqs last disabled at (538): [<00000000ac234eed>] spin_lock_bh include/linux/spinlock.h:320 [inline] softirqs last disabled at (538): [<00000000ac234eed>] lock_sock_nested+0x44/0x110 net/core/sock.c:2762 IPv6: RTM_NEWROUTE with no NLM_F_CREATE or NLM_F_REPLACE IPv6: NLM_F_CREATE should be set when creating new route IPv6: NLM_F_CREATE should be set when creating new route CPU: 0 PID: 11366 Comm: syz-executor7 Not tainted 4.15.0-rc1+ #133 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:17 [inline] dump_stack+0x194/0x257 lib/dump_stack.c:53 ___might_sleep+0x2b2/0x470 kernel/sched/core.c:6060 IPv6: RTM_NEWROUTE with no NLM_F_CREATE or NLM_F_REPLACE __might_sleep+0x95/0x190 kernel/sched/core.c:6013 __do_page_fault+0x350/0xc90 arch/x86/mm/fault.c:1372 do_page_fault+0xee/0x720 arch/x86/mm/fault.c:1504 page_fault+0x22/0x30 arch/x86/entry/entry_64.S:1094 RIP: 0010:virt_to_cache mm/slab.c:400 [inline] RIP: 0010:kfree+0xb2/0x250 mm/slab.c:3802 RSP: 0018:ffff8801a0557660 EFLAGS: 00010046 RAX: 0000000000000000 RBX: ffff8801a0557828 RCX: ffffffffffffffff RDX: ffffea00068155c0 RSI: 0000000000000000 RDI: ffff8801a0557828 RBP: ffff8801a0557680 R08: ffffed003a2f4dc4 R09: 0000000000000000 R10: 0000000000000001 R11: ffffed003a2f4dc3 R12: 0000000000000286 R13: 0000000000000000 R14: ffff8801a0557828 R15: ffff8801a0557790 blkcipher_walk_done+0x72b/0xde0 crypto/blkcipher.c:139 encrypt+0x50a/0xaf0 crypto/salsa20_generic.c:208 skcipher_crypt_blkcipher crypto/skcipher.c:622 [inline] skcipher_decrypt_blkcipher+0x213/0x310 crypto/skcipher.c:640 crypto_skcipher_decrypt include/crypto/skcipher.h:463 [inline] _skcipher_recvmsg crypto/algif_skcipher.c:144 [inline] skcipher_recvmsg+0xa54/0xf20 crypto/algif_skcipher.c:165 sock_recvmsg_nosec net/socket.c:805 [inline] sock_recvmsg+0xc9/0x110 net/socket.c:812 sock_read_iter+0x361/0x560 net/socket.c:889 call_read_iter include/linux/fs.h:1766 [inline] do_iter_readv_writev+0x607/0x7f0 fs/read_write.c:651 do_iter_read+0x220/0x5b0 fs/read_write.c:895 vfs_readv+0x121/0x1c0 fs/read_write.c:959 do_readv+0xfc/0x2a0 fs/read_write.c:992 SYSC_readv fs/read_write.c:1079 [inline] SyS_readv+0x27/0x30 fs/read_write.c:1076 entry_SYSCALL_64_fastpath+0x1f/0x96 RIP: 0033:0x4529d9 RSP: 002b:00007fa54e9a5c58 EFLAGS: 00000212 ORIG_RAX: 0000000000000013 RAX: ffffffffffffffda RBX: 0000000000758048 RCX: 00000000004529d9 RDX: 0000000000000002 RSI: 00000000206cafe0 RDI: 0000000000000014 RBP: 0000000000758048 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000212 R12: 0000000000000000 R13: 0000000000a6f7ff R14: 00007fa54e9a69c0 R15: 0000000000000000 BUG: unable to handle kernel NULL pointer dereference at 000000009edb127f IP: virt_to_cache mm/slab.c:400 [inline] IP: kfree+0xb2/0x250 mm/slab.c:3802 PGD 1d4387067 P4D 1d4387067 PUD 1d124a067 PMD 0 Oops: 0000 [#1] SMP KASAN Dumping ftrace buffer: (ftrace buffer empty) Modules linked in: CPU: 0 PID: 11366 Comm: syz-executor7 Tainted: G W 4.15.0-rc1+ #133 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 task: 00000000c1b4cc88 task.stack: 000000005df959c6 RIP: 0010:virt_to_cache mm/slab.c:400 [inline] RIP: 0010:kfree+0xb2/0x250 mm/slab.c:3802 RSP: 0018:ffff8801a0557660 EFLAGS: 00010046 RAX: 0000000000000000 RBX: ffff8801a0557828 RCX: ffffffffffffffff RDX: ffffea00068155c0 RSI: 0000000000000000 RDI: ffff8801a0557828 RBP: ffff8801a0557680 R08: ffffed003a2f4dc4 R09: 0000000000000000 R10: 0000000000000001 R11: ffffed003a2f4dc3 R12: 0000000000000286 R13: 0000000000000000 R14: ffff8801a0557828 R15: ffff8801a0557790 FS: 00007fa54e9a6700(0000) GS:ffff8801db400000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000000000074 CR3: 00000001ca271000 CR4: 00000000001406f0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: blkcipher_walk_done+0x72b/0xde0 crypto/blkcipher.c:139 encrypt+0x50a/0xaf0 crypto/salsa20_generic.c:208 skcipher_crypt_blkcipher crypto/skcipher.c:622 [inline] skcipher_decrypt_blkcipher+0x213/0x310 crypto/skcipher.c:640 crypto_skcipher_decrypt include/crypto/skcipher.h:463 [inline] _skcipher_recvmsg crypto/algif_skcipher.c:144 [inline] skcipher_recvmsg+0xa54/0xf20 crypto/algif_skcipher.c:165 sock_recvmsg_nosec net/socket.c:805 [inline] sock_recvmsg+0xc9/0x110 net/socket.c:812 sock_read_iter+0x361/0x560 net/socket.c:889 call_read_iter include/linux/fs.h:1766 [inline] do_iter_readv_writev+0x607/0x7f0 fs/read_write.c:651 do_iter_read+0x220/0x5b0 fs/read_write.c:895 vfs_readv+0x121/0x1c0 fs/read_write.c:959 do_readv+0xfc/0x2a0 fs/read_write.c:992 SYSC_readv fs/read_write.c:1079 [inline] SyS_readv+0x27/0x30 fs/read_write.c:1076 entry_SYSCALL_64_fastpath+0x1f/0x96 RIP: 0033:0x4529d9 RSP: 002b:00007fa54e9a5c58 EFLAGS: 00000212 ORIG_RAX: 0000000000000013 RAX: ffffffffffffffda RBX: 0000000000758048 RCX: 00000000004529d9 RDX: 0000000000000002 RSI: 00000000206cafe0 RDI: 0000000000000014 RBP: 0000000000758048 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000212 R12: 0000000000000000 R13: 0000000000a6f7ff R14: 00007fa54e9a69c0 R15: 0000000000000000 Code: c2 48 b8 00 00 00 00 00 ea ff ff 48 89 df 48 c1 ea 0c 48 c1 e2 06 48 01 c2 48 8b 42 20 48 8d 48 ff a8 01 48 0f 45 d1 4c 8b 6a 30 <49> 63 75 74 e8 95 75 af ff 48 89 de 4c 89 ef 4c 8b 75 08 e8 06 RIP: virt_to_cache mm/slab.c:400 [inline] RSP: ffff8801a0557660 RIP: kfree+0xb2/0x250 mm/slab.c:3802 RSP: ffff8801a0557660 CR2: 0000000000000074 ---[ end trace 8a9557ab65135118 ]---