RBP: 000000000072bea0 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000002 R11: 0000000000000246 R12: 0000000000000014 R13: 00000000004c07fa R14: 00000000004cff58 R15: 0000000000000000 ================================================================== BUG: KMSAN: uninit-value in _copy_to_user+0x12f/0x180 lib/usercopy.c:26 CPU: 1 PID: 4397 Comm: rsyslogd Not tainted 4.17.0+ #9 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+0x185/0x1d0 lib/dump_stack.c:113 kmsan_report+0x188/0x2a0 mm/kmsan/kmsan.c:1125 __msan_warning_32+0x70/0xc0 mm/kmsan/kmsan_instr.c:620 _copy_to_user+0x12f/0x180 lib/usercopy.c:26 copy_to_user include/linux/uaccess.h:183 [inline] syslog_print kernel/printk/printk.c:1344 [inline] do_syslog+0x3936/0x3c20 kernel/printk/printk.c:1467 kmsg_read+0x142/0x1a0 fs/proc/kmsg.c:40 proc_reg_read+0x1e3/0x2f0 fs/proc/inode.c:230 __vfs_read+0x1b2/0x9d0 fs/read_write.c:416 vfs_read+0x36c/0x6b0 fs/read_write.c:452 ksys_read fs/read_write.c:578 [inline] __do_sys_read fs/read_write.c:588 [inline] __se_sys_read fs/read_write.c:586 [inline] __x64_sys_read+0x1bf/0x3e0 fs/read_write.c:586 do_syscall_64+0x15b/0x230 arch/x86/entry/common.c:287 entry_SYSCALL_64_after_hwframe+0x44/0xa9 RIP: 0033:0x7fb913b321fd RSP: 002b:00007fb9110d1e30 EFLAGS: 00000293 ORIG_RAX: 0000000000000000 RAX: ffffffffffffffda RBX: 0000000002296ce0 RCX: 00007fb913b321fd RDX: 0000000000000fff RSI: 00007fb9129065a0 RDI: 0000000000000004 RBP: 0000000000000000 R08: 0000000002282260 R09: 0000000004000001 R10: 0000000000000001 R11: 0000000000000293 R12: 000000000065e420 R13: 00007fb9110d29c0 R14: 00007fb914177040 R15: 0000000000000003 Uninit was stored to memory at: kmsan_save_stack_with_flags mm/kmsan/kmsan.c:282 [inline] kmsan_save_stack mm/kmsan/kmsan.c:297 [inline] kmsan_internal_chain_origin+0x12b/0x210 mm/kmsan/kmsan.c:689 __msan_chain_origin+0x69/0xc0 mm/kmsan/kmsan_instr.c:464 log_store+0x13fc/0x14b0 kernel/printk/printk.c:641 log_output kernel/printk/printk.c:1832 [inline] vprintk_emit+0xca5/0x1060 kernel/printk/printk.c:1897 vprintk_default+0x90/0xa0 kernel/printk/printk.c:1955 vprintk_func+0x517/0x700 kernel/printk/printk_safe.c:379 printk+0x1e4/0x210 kernel/printk/printk.c:1991 printk_stack_address arch/x86/kernel/dumpstack.c:69 [inline] show_trace_log_lvl+0xb5c/0x10a0 arch/x86/kernel/dumpstack.c:207 show_stack+0xfc/0x150 arch/x86/kernel/dumpstack.c:245 __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x185/0x1d0 lib/dump_stack.c:113 fail_dump lib/fault-inject.c:51 [inline] should_fail+0x87b/0xab0 lib/fault-inject.c:149 __should_failslab+0x278/0x2a0 mm/failslab.c:32 should_failslab+0x29/0x70 mm/slab_common.c:1522 slab_pre_alloc_hook mm/slab.h:423 [inline] slab_alloc_node mm/slub.c:2679 [inline] slab_alloc mm/slub.c:2761 [inline] kmem_cache_alloc+0x129/0xb70 mm/slub.c:2766 kmem_cache_zalloc include/linux/slab.h:691 [inline] taskstats_tgid_alloc kernel/taskstats.c:573 [inline] taskstats_exit+0x17a/0x17e0 kernel/taskstats.c:606 do_exit+0xc0d/0x3930 kernel/exit.c:852 do_group_exit+0x1a0/0x360 kernel/exit.c:970 get_signal+0x1405/0x1ec0 kernel/signal.c:2482 do_signal+0xb8/0x1d20 arch/x86/kernel/signal.c:810 exit_to_usermode_loop arch/x86/entry/common.c:162 [inline] prepare_exit_to_usermode+0x271/0x3a0 arch/x86/entry/common.c:196 syscall_return_slowpath+0xe9/0x710 arch/x86/entry/common.c:265 do_syscall_64+0x1ad/0x230 arch/x86/entry/common.c:290 entry_SYSCALL_64_after_hwframe+0x44/0xa9 Local variable description: ----flags.i.i.i.i.i.i@kmem_cache_alloc Variable was created at: kmem_cache_alloc+0x7a/0xb70 mm/slub.c:2764 kmem_cache_zalloc include/linux/slab.h:691 [inline] taskstats_tgid_alloc kernel/taskstats.c:573 [inline] taskstats_exit+0x17a/0x17e0 kernel/taskstats.c:606 ==================================================================