================================================================== BUG: KASAN: use-after-free in __read_once_size include/linux/compiler.h:193 [inline] BUG: KASAN: use-after-free in rhashtable_last_table+0xd7/0xf0 lib/rhashtable.c:217 Read of size 8 at addr ffff88808be00780 by task kworker/0:2/2998 CPU: 0 PID: 2998 Comm: kworker/0:2 Not tainted 5.1.0-rc1+ #1 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Workqueue: events rht_deferred_worker Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x113/0x167 lib/dump_stack.c:113 print_address_description.cold.5+0x9/0x1ff mm/kasan/report.c:187 kasan_report.cold.6+0x1b/0x39 mm/kasan/report.c:317 __asan_report_load8_noabort+0x14/0x20 mm/kasan/generic_report.c:132 __read_once_size include/linux/compiler.h:193 [inline] rhashtable_last_table+0xd7/0xf0 lib/rhashtable.c:217 rht_deferred_worker+0x77/0x15c0 lib/rhashtable.c:410 process_one_work+0x830/0x16a0 kernel/workqueue.c:2269 worker_thread+0x85/0xb60 kernel/workqueue.c:2415 kthread+0x324/0x3e0 kernel/kthread.c:253 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:352 Allocated by task 22: save_stack+0x43/0xd0 mm/kasan/common.c:75 set_track mm/kasan/common.c:87 [inline] __kasan_kmalloc.constprop.9+0xc7/0xd0 mm/kasan/common.c:497 kasan_kmalloc+0x9/0x10 mm/kasan/common.c:511 __do_kmalloc_node mm/slab.c:3686 [inline] __kmalloc_node+0x4d/0x70 mm/slab.c:3693 kmalloc_node include/linux/slab.h:588 [inline] kvmalloc_node+0x6a/0x80 mm/util.c:430 kvmalloc include/linux/mm.h:605 [inline] kvzalloc include/linux/mm.h:613 [inline] bucket_table_alloc+0x38/0x390 lib/rhashtable.c:176 rhashtable_rehash_alloc+0x5b/0xc0 lib/rhashtable.c:353 rhashtable_shrink lib/rhashtable.c:397 [inline] rht_deferred_worker+0x10fe/0x15c0 lib/rhashtable.c:415 process_one_work+0x830/0x16a0 kernel/workqueue.c:2269 worker_thread+0x85/0xb60 kernel/workqueue.c:2415 kthread+0x324/0x3e0 kernel/kthread.c:253 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:352 Freed by task 7: save_stack+0x43/0xd0 mm/kasan/common.c:75 set_track mm/kasan/common.c:87 [inline] __kasan_slab_free+0x102/0x150 mm/kasan/common.c:459 kasan_slab_free+0xe/0x10 mm/kasan/common.c:467 __cache_free mm/slab.c:3498 [inline] kfree+0xcf/0x220 mm/slab.c:3821 kvfree+0x2c/0x30 mm/util.c:459 bucket_table_free+0x79/0x140 lib/rhashtable.c:108 rhashtable_free_and_destroy+0xf7/0x690 lib/rhashtable.c:1163 inet_frags_exit_net+0x38/0x50 net/ipv4/inet_fragment.c:152 ipv4_frags_exit_net+0x6e/0x90 net/ipv4/ip_fragment.c:695 ops_exit_list.isra.5+0x8b/0x120 net/core/net_namespace.c:153 cleanup_net+0x363/0x840 net/core/net_namespace.c:551 process_one_work+0x830/0x16a0 kernel/workqueue.c:2269 worker_thread+0x85/0xb60 kernel/workqueue.c:2415 kthread+0x324/0x3e0 kernel/kthread.c:253 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:352 The buggy address belongs to the object at ffff88808be00740 which belongs to the cache kmalloc-4k of size 4096 The buggy address is located 64 bytes inside of 4096-byte region [ffff88808be00740, ffff88808be01740) The buggy address belongs to the page: page:ffffea00022f8000 count:1 mapcount:0 mapping:ffff88812c326dc0 index:0x0 compound_mapcount: 0 flags: 0x1fffc0000010200(slab|head) raw: 01fffc0000010200 ffffea0002a3f088 ffffea000231ca88 ffff88812c326dc0 raw: 0000000000000000 ffff88808be00740 0000000100000001 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff88808be00680: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff88808be00700: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb >ffff88808be00780: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff88808be00800: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff88808be00880: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ==================================================================