FYI, we noticed the following commit (built with gcc-7): commit: 53d4a4300b82c4156da46eab01a8dd4e65a46491 ("[PATCH 1/1] fs: rethread notify_change to take a path instead of a dentry") url: https://github.com/0day-ci/linux/commits/James-Bottomley/preparatory-patch-for-a-uid-gid-shifting-bind-mount/20191201-052453 in testcase: ltp with following parameters: disk: 1HDD fs: btrfs test: syscalls_part2 test-description: The LTP testsuite contains a collection of tools for testing the Linux kernel and related features. test-url: http://linux-test-project.github.io/ on test machine: qemu-system-x86_64 -enable-kvm -cpu SandyBridge -smp 2 -m 8G caused below changes (please refer to attached dmesg/kmsg for entire log/backtrace): +---------------------------------------------------------------+------------+------------+ | | a6ed68d646 | 53d4a4300b | +---------------------------------------------------------------+------------+------------+ | boot_successes | 42 | 5 | | boot_failures | 0 | 8 | | WARNING:at_fs/overlayfs/copy_up.c:#ovl_copy_up_inode[overlay] | 0 | 8 | | RIP:ovl_copy_up_inode[overlay] | 0 | 8 | +---------------------------------------------------------------+------------+------------+ If you fix the issue, kindly add following tag Reported-by: kernel test robot [ 578.985285] WARNING: CPU: 0 PID: 5270 at fs/overlayfs/copy_up.c:455 ovl_copy_up_inode+0x16f/0x180 [overlay] [ 578.986017] ioctl01 1 TPASS : failed as expected: TEST_ERRNO=EBADF(9): Bad file descriptor [ 578.986019] [ 578.988494] Modules linked in: overlay ext4 mbcache jbd2 tun xfs loop btrfs xor zstd_decompress zstd_compress raid6_pq libcrc32c dm_mod intel_rapl_msr intel_rapl_common crct10dif_pclmul crc32_pclmul crc32c_intel ghash_clmulni_intel bochs_drm drm_vram_helper drm_ttm_helper ttm sr_mod drm_kms_helper cdrom sg ata_generic pata_acpi syscopyarea sysfillrect ppdev sysimgblt fb_sys_fops drm snd_pcm aesni_intel crypto_simd snd_timer cryptd glue_helper snd soundcore pcspkr joydev ata_piix serio_raw libata i2c_piix4 parport_pc floppy parport ip_tables [ 578.992500] ioctl01 2 TPASS : failed as expected: TEST_ERRNO=EFAULT(14): Bad address [ 578.992501] [ 579.002619] CPU: 0 PID: 5270 Comm: inotify07 Not tainted 5.4.0-08748-g53d4a4300b82c #2 [ 579.002619] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.10.2-1 04/01/2014 [ 579.002625] RIP: 0010:ovl_copy_up_inode+0x16f/0x180 [overlay] [ 579.002627] Code: ff ff 85 c0 0f 84 4d ff ff ff eb a5 4c 8d 64 24 28 48 8b 73 58 4c 89 e7 e8 be f8 ff ff 85 c0 0f 85 74 ff ff ff e9 63 ff ff ff <0f> 0b b8 fb ff ff ff e9 7b ff ff ff e8 b0 f6 b5 ee 66 66 66 66 90 [ 579.009864] ioctl01 3 TPASS : failed as expected: TEST_ERRNO=ENOTTY(25): Inappropriate ioctl for device [ 579.009866] [ 579.010638] RSP: 0018:ffffab27c0327958 EFLAGS: 00010206 [ 579.010639] RAX: 0000000000008000 RBX: ffffab27c0327a90 RCX: 00000000000081a4 [ 579.010640] RDX: 000000000000001c RSI: ffffab27c0327960 RDI: ffff98f9d6812e40 [ 579.010641] RBP: ffff98f9ecb92600 R08: 0000000000000000 R09: 0000000100043f23 [ 579.010641] R10: ffffab27c0327860 R11: ffff98f9d55b4000 R12: ffffab27c0327a90 [ 579.010642] R13: ffff98f9c648f6c0 R14: 00000000ecb92600 R15: 0000000000000000 [ 579.010643] FS: 00007fe8e8403500(0000) GS:ffff98fa7fc00000(0000) knlGS:0000000000000000 [ 579.015105] ioctl01 4 TPASS : failed as expected: TEST_ERRNO=ENOTTY(25): Inappropriate ioctl for device [ 579.015106] [ 579.018993] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 579.018994] CR2: 0000558a8a903840 CR3: 0000000195090000 CR4: 00000000000406f0 [ 579.018997] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 [ 579.018998] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 [ 579.018999] Call Trace: [ 579.023287] ioctl01 5 TPASS : failed as expected: TEST_ERRNO=EFAULT(14): Bad address [ 579.023289] [ 579.024174] ovl_copy_up_one+0x80c/0xf40 [overlay] [ 579.024178] ? __d_lookup_done+0x7e/0x100 [ 579.027460] ioctl01_02 1 TPASS : ioctl01 Passed with /dev/tty59 [ 579.027462] [ 579.028091] ? ext4_xattr_get+0x95/0x2d0 [ext4] [ 579.030043] [ 579.031918] ovl_copy_up_flags+0xac/0xf0 [overlay] [ 579.031921] ? ovl_llseek+0x110/0x110 [overlay] [ 579.035137] ioctl01_02 0 TINFO : Testing ioctl01 with /dev/tty6 [ 579.035139] [ 579.035850] ovl_maybe_copy_up+0x79/0xa0 [overlay] [ 579.035853] ovl_open+0x25/0x80 [overlay] [ 579.035857] do_dentry_open+0x1ce/0x380 [ 579.040211] ioctl01 1 TPASS : failed as expected: TEST_ERRNO=EBADF(9): Bad file descriptor [ 579.040212] [ 579.040979] path_openat+0x2e5/0x1550 [ 579.044772] ioctl01 2 TPASS : failed as expected: TEST_ERRNO=EFAULT(14): Bad address [ 579.044774] [ 579.044837] do_filp_open+0x9b/0x110 [ 579.049101] ioctl01 3 TPASS : failed as expected: TEST_ERRNO=ENOTTY(25): Inappropriate ioctl for device [ 579.049103] [ 579.050042] ? __check_object_size+0xd4/0x1a0 [ 579.050045] ? do_sys_open+0x1bd/0x250 [ 579.053467] ioctl01 4 TPASS : failed as expected: TEST_ERRNO=ENOTTY(25): Inappropriate ioctl for device [ 579.053469] [ 579.054093] do_sys_open+0x1bd/0x250 [ 579.057723] ioctl01 5 TPASS : failed as expected: TEST_ERRNO=EFAULT(14): Bad address [ 579.057725] [ 579.058355] do_syscall_64+0x5b/0x1f0 [ 579.058358] entry_SYSCALL_64_after_hwframe+0x44/0xa9 [ 579.060704] ioctl01_02 1 TPASS : ioctl01 Passed with /dev/tty6 [ 579.060707] [ 579.060889] RIP: 0033:0x7fe8e7f246f0 [ 579.062386] [ 579.064109] Code: 00 f7 d8 64 89 01 48 83 c8 ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 83 3d 19 30 2c 00 00 75 10 b8 02 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 31 c3 48 83 ec 08 e8 fe 9d 01 00 48 89 04 24 [ 579.064110] RSP: 002b:00007ffc1f798318 EFLAGS: 00000246 ORIG_RAX: 0000000000000002 [ 579.064112] RAX: ffffffffffffffda RBX: 0000558a8a6f0f40 RCX: 00007fe8e7f246f0 [ 579.064112] RDX: 00000000000001b6 RSI: 0000000000000041 RDI: 0000558a8a6f0f40 [ 579.064113] RBP: 0000558a8a6f1135 R08: 00000000000001a4 R09: 0000000000000000 [ 579.064113] R10: 0000000000000075 R11: 0000000000000246 R12: 000000000000004e [ 579.064115] R13: 00000000000001a4 R14: 0000000000000000 R15: 0000000000000000 [ 579.066448] ioctl01_02 0 TINFO : Testing ioctl01 with /dev/tty60 [ 579.066450] [ 579.066610] ---[ end trace 1eae0e213285ea20 ]--- To reproduce: # build kernel cd linux cp config-5.4.0-08748-g53d4a4300b82c .config make HOSTCC=gcc-7 CC=gcc-7 ARCH=x86_64 olddefconfig prepare modules_prepare bzImage modules make HOSTCC=gcc-7 CC=gcc-7 ARCH=x86_64 INSTALL_MOD_PATH= modules_install cd find lib/ | cpio -o -H newc --quiet | gzip > modules.cgz git clone https://github.com/intel/lkp-tests.git cd lkp-tests bin/lkp qemu -k -m modules.cgz job-script # job-script is attached in this email Thanks, Rong Chen