====================================== | [ 14.930698][ T70] ================================================================== | [ 14.931018][ T70] BUG: KASAN: null-ptr-deref in try_to_grab_pending (./arch/x86/include/asm/bitops.h:136 ./include/asm-generic/bitops/instrumented-atomic.h:72 kernel/workqueue.c:2072) | [ 14.931302][ T70] Write of size 8 at addr 0000000000000000 by task kworker/u16:1/70 | [ 14.931570][ T70] [ 14.931673][ T70] Hardware name: Bochs Bochs, BIOS Bochs 01/01/2011 [ 14.931676][ T70] Workqueue: netns cleanup_net [ 14.931686][ T70] Call Trace: [ 14.931688][ T70] [ 14.931691][ T70] dump_stack_lvl (lib/dump_stack.c:123) [ 14.931699][ T70] ? try_to_grab_pending (./arch/x86/include/asm/bitops.h:136 ./include/asm-generic/bitops/instrumented-atomic.h:72 kernel/workqueue.c:2072) [ 14.931702][ T70] kasan_report (mm/kasan/report.c:597) [ 14.931710][ T70] ? try_to_grab_pending (./arch/x86/include/asm/bitops.h:136 ./include/asm-generic/bitops/instrumented-atomic.h:72 kernel/workqueue.c:2072) [ 14.931715][ T70] kasan_check_range (mm/kasan/generic.c:194 mm/kasan/generic.c:200) [ 14.931718][ T70] try_to_grab_pending (./arch/x86/include/asm/bitops.h:136 ./include/asm-generic/bitops/instrumented-atomic.h:72 kernel/workqueue.c:2072) [ 14.931721][ T70] ? netif_close_many (net/core/dev.c:1959) [ 14.931727][ T70] __cancel_work (kernel/workqueue.c:2161 kernel/workqueue.c:4364) [ 14.931730][ T70] ? enable_delayed_work (kernel/workqueue.c:4359) [ 14.931735][ T70] ? queue_delayed_work_on (kernel/workqueue.c:2565 (discriminator 1)) [ 14.931739][ T70] __cancel_work_sync (kernel/workqueue.c:4383) [ 14.931743][ T70] __dev_close_many (net/core/dev.c:1879 (discriminator 2) net/core/dev.c:1932 (discriminator 2)) [ 14.931747][ T70] ? netdev_notify_peers (net/core/dev.c:1891) [ 14.931751][ T70] ? netif_close_many (net/core/dev.c:1959) [ 14.931755][ T70] netif_close_many (net/core/dev.c:1959) [ 14.931758][ T70] ? __mutex_handoff (kernel/locking/mutex.c:88) [ 14.931763][ T70] ? __dev_close_many (net/core/dev.c:1949) [ 14.931767][ T70] ? netif_close_many_and_unlock (net/core/dev.c:12476) [ 14.931771][ T70] unregister_netdevice_many_notify (net/core/dev.c:12545) [ 14.931777][ T70] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 14.931782][ T70] ? mutex_is_locked (./arch/x86/include/asm/atomic64_64.h:15 ./include/linux/atomic/atomic-arch-fallback.h:2583 ./include/linux/atomic/atomic-long.h:38 ./include/linux/atomic/atomic-instrumented.h:3189 kernel/locking/mutex.h:47 kernel/locking/mutex.c:67) [ 14.931785][ T70] ? dev_ingress_queue_create (net/core/dev.c:12499) [ 14.931788][ T70] ? rtnl_is_locked (net/core/rtnetlink.c:169) [ 14.931792][ T70] ? unregister_netdevice_queue (net/core/dev.c:12442) [ 14.931795][ T70] ? unregister_netdevice_many (net/core/dev.c:12441) [ 14.931798][ T70] ? unregister_netdevice_many (net/core/dev.c:12441) [ 14.931804][ T70] default_device_exit_batch (net/core/dev.c:13229) [ 14.931808][ T70] ? unregister_netdev (net/core/dev.c:13204) [ 14.931814][ T70] ops_undo_list (net/core/net_namespace.c:251) [ 14.931818][ T70] ? netns_get (net/core/net_namespace.c:223) [ 14.931820][ T70] ? cleanup_net (./include/linux/list.h:191 net/core/net_namespace.c:693) [ 14.931825][ T70] cleanup_net (net/core/net_namespace.c:698) [ 14.931829][ T70] ? net_passive_dec (net/core/net_namespace.c:660) [ 14.931832][ T70] ? rcu_is_watching (./include/linux/context_tracking.h:128 kernel/rcu/tree.c:751) [ 14.931839][ T70] process_one_work (kernel/workqueue.c:3268) [ 14.931845][ T70] ? pwq_dec_nr_in_flight (kernel/workqueue.c:3165) [ 14.931853][ T70] ? assign_work (kernel/workqueue.c:1206) [ 14.931861][ T70] worker_thread (kernel/workqueue.c:3340 kernel/workqueue.c:3427) [ 14.931870][ T70] ? rescuer_thread (kernel/workqueue.c:3373) [ 14.931875][ T70] kthread (kernel/kthread.c:463) [ 14.931881][ T70] ? kthread_is_per_cpu (kernel/kthread.c:412) [ 14.931884][ T70] ? ret_from_fork (arch/x86/kernel/process.c:157) [ 14.931892][ T70] ? __lock_release (kernel/locking/lockdep.c:5536) [ 14.931896][ T70] ? rcu_is_watching (./include/linux/context_tracking.h:128 kernel/rcu/tree.c:751) [ 14.931899][ T70] ? kthread_is_per_cpu (kernel/kthread.c:412) [ 14.931902][ T70] ret_from_fork (arch/x86/kernel/process.c:164) [ 14.931905][ T70] ? kthread_is_per_cpu (kernel/kthread.c:412) [ 14.931908][ T70] ret_from_fork_asm (arch/x86/entry/entry_64.S:255) | [ 14.942634][ T70] #PF: error_code(0x0002) - not-present page | [ 14.942952][ T70] PGD 0 P4D 0 | [ 14.943156][ T70] Oops: Oops: 0002 [#1] SMP KASAN | [ 14.944049][ T70] Tainted: [B]=BAD_PAGE [ 14.944256][ T70] Hardware name: Bochs Bochs, BIOS Bochs 01/01/2011 [ 14.944605][ T70] Workqueue: netns cleanup_net [ 14.944894][ T70] RIP: 0010:try_to_grab_pending (./arch/x86/include/asm/bitops.h:136 ./include/asm-generic/bitops/instrumented-atomic.h:72 kernel/workqueue.c:2072) [ 14.945261][ T70] Code: 00 41 89 c0 b8 01 00 00 00 45 85 c0 74 0f 48 83 c4 10 5b 5d 41 5c 41 5d 41 5e 41 5f c3 be 08 00 00 00 48 89 df e8 7f 7f 81 00 48 0f ba 2b 00 72 11 48 83 c4 10 31 c0 5b 5d 41 5c 41 5d 41 5e All code ======== 0: 00 41 89 add %al,-0x77(%rcx) 3: c0 b8 01 00 00 00 45 sarb $0x45,0x1(%rax) a: 85 c0 test %eax,%eax c: 74 0f je 0x1d e: 48 83 c4 10 add $0x10,%rsp 12: 5b pop %rbx 13: 5d pop %rbp 14: 41 5c pop %r12 16: 41 5d pop %r13 18: 41 5e pop %r14 1a: 41 5f pop %r15 1c: c3 ret 1d: be 08 00 00 00 mov $0x8,%esi 22: 48 89 df mov %rbx,%rdi 25: e8 7f 7f 81 00 call 0x817fa9 2a:* f0 48 0f ba 2b 00 lock btsq $0x0,(%rbx) <-- trapping instruction 30: 72 11 jb 0x43 32: 48 83 c4 10 add $0x10,%rsp 36: 31 c0 xor %eax,%eax 38: 5b pop %rbx 39: 5d pop %rbp 3a: 41 5c pop %r12 3c: 41 5d pop %r13 3e: 41 5e pop %r14 Code starting with the faulting instruction =========================================== 0: f0 48 0f ba 2b 00 lock btsq $0x0,(%rbx) 6: 72 11 jb 0x19 8: 48 83 c4 10 add $0x10,%rsp c: 31 c0 xor %eax,%eax e: 5b pop %rbx f: 5d pop %rbp 10: 41 5c pop %r12 12: 41 5d pop %r13 14: 41 5e pop %r14 [ 14.946240][ T70] RSP: 0018:ffffc900004b7690 EFLAGS: 00010046 [ 14.946600][ T70] RAX: 0000000000000000 RBX: 0000000000000000 RCX: ffffffffad03f90a [ 14.947007][ T70] RDX: fffffbfff624b6cd RSI: 0000000000000008 RDI: ffffffffb125b660 [ 14.947425][ T70] RBP: ffffc900004b76f8 R08: 0000000000000001 R09: fffffbfff624b6cc [ 14.947842][ T70] R10: ffffffffb125b667 R11: ffffc900004b7180 R12: 0000000000000000 [ 14.948258][ T70] R13: 0000000000000286 R14: ffff88800d10c000 R15: dffffc0000000000 [ 14.948681][ T70] FS: 0000000000000000(0000) GS:ffff888085110000(0000) knlGS:0000000000000000 [ 14.949143][ T70] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 14.949420][ T70] CR2: 0000000000000000 CR3: 0000000010b35002 CR4: 0000000000772ef0 [ 14.949687][ T70] PKRU: 55555554 [ 14.949822][ T70] Call Trace: [ 14.949964][ T70] [ 14.950055][ T70] ? netif_close_many (net/core/dev.c:1959) [ 14.950245][ T70] __cancel_work (kernel/workqueue.c:2161 kernel/workqueue.c:4364) [ 14.950418][ T70] ? enable_delayed_work (kernel/workqueue.c:4359) [ 14.950587][ T70] ? queue_delayed_work_on (kernel/workqueue.c:2565 (discriminator 1)) [ 14.950759][ T70] __cancel_work_sync (kernel/workqueue.c:4383) [ 14.950926][ T70] __dev_close_many (net/core/dev.c:1879 (discriminator 2) net/core/dev.c:1932 (discriminator 2)) [ 14.951106][ T70] ? netdev_notify_peers (net/core/dev.c:1891) [ 14.951281][ T70] ? netif_close_many (net/core/dev.c:1959) [ 14.951452][ T70] netif_close_many (net/core/dev.c:1959) [ 14.951618][ T70] ? __mutex_handoff (kernel/locking/mutex.c:88) [ 14.951786][ T70] ? __dev_close_many (net/core/dev.c:1949) [ 14.951954][ T70] ? netif_close_many_and_unlock (net/core/dev.c:12476) [ 14.952165][ T70] unregister_netdevice_many_notify (net/core/dev.c:12545) [ 14.952375][ T70] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 14.952548][ T70] ? mutex_is_locked (./arch/x86/include/asm/atomic64_64.h:15 ./include/linux/atomic/atomic-arch-fallback.h:2583 ./include/linux/atomic/atomic-long.h:38 ./include/linux/atomic/atomic-instrumented.h:3189 kernel/locking/mutex.h:47 kernel/locking/mutex.c:67) [ 14.952717][ T70] ? dev_ingress_queue_create (net/core/dev.c:12499) [ 14.952883][ T70] ? rtnl_is_locked (net/core/rtnetlink.c:169) [ 14.953054][ T70] ? unregister_netdevice_queue (net/core/dev.c:12442) [ 14.953268][ T70] ? unregister_netdevice_many (net/core/dev.c:12441) [ 14.953435][ T70] ? unregister_netdevice_many (net/core/dev.c:12441) [ 14.953608][ T70] default_device_exit_batch (net/core/dev.c:13229) [ 14.953783][ T70] ? unregister_netdev (net/core/dev.c:13204) [ 14.953951][ T70] ops_undo_list (net/core/net_namespace.c:251) [ 14.954125][ T70] ? netns_get (net/core/net_namespace.c:223) [ 14.954291][ T70] ? cleanup_net (./include/linux/list.h:191 net/core/net_namespace.c:693) [ 14.954460][ T70] cleanup_net (net/core/net_namespace.c:698) [ 14.954626][ T70] ? net_passive_dec (net/core/net_namespace.c:660) [ 14.954795][ T70] ? rcu_is_watching (./include/linux/context_tracking.h:128 kernel/rcu/tree.c:751) [ 14.954965][ T70] process_one_work (kernel/workqueue.c:3268) [ 14.955149][ T70] ? pwq_dec_nr_in_flight (kernel/workqueue.c:3165) [ 14.955331][ T70] ? assign_work (kernel/workqueue.c:1206) [ 14.955498][ T70] worker_thread (kernel/workqueue.c:3340 kernel/workqueue.c:3427) [ 14.955667][ T70] ? rescuer_thread (kernel/workqueue.c:3373) [ 14.955836][ T70] kthread (kernel/kthread.c:463) [ 14.955964][ T70] ? kthread_is_per_cpu (kernel/kthread.c:412) [ 14.956150][ T70] ? ret_from_fork (arch/x86/kernel/process.c:157) [ 14.956325][ T70] ? __lock_release (kernel/locking/lockdep.c:5536) [ 14.956502][ T70] ? rcu_is_watching (./include/linux/context_tracking.h:128 kernel/rcu/tree.c:751) [ 14.956668][ T70] ? kthread_is_per_cpu (kernel/kthread.c:412) [ 14.956836][ T70] ret_from_fork (arch/x86/kernel/process.c:164) [ 14.957003][ T70] ? kthread_is_per_cpu (kernel/kthread.c:412) Finger prints: kasan_report:kasan_check_range:try_to_grab_pending:__cancel_work:__cancel_work_sync try_to_grab_pending:__cancel_work:__cancel_work_sync:__dev_close_many:netif_close_many