linux-stable/fs/overlayfs
Amir Goldstein 6890751cfe ovl: relax WARN_ON() on rename to self
commit 6889ee5a53 upstream.

In ovl_rename(), if new upper is hardlinked to old upper underneath
overlayfs before upper dirs are locked, user will get an ESTALE error
and a WARN_ON will be printed.

Changes to underlying layers while overlayfs is mounted may result in
unexpected behavior, but it shouldn't crash the kernel and it shouldn't
trigger WARN_ON() either, so relax this WARN_ON().

Reported-by: syzbot+bb1836a212e69f8e201a@syzkaller.appspotmail.com
Fixes: 804032fabb ("ovl: don't check rename to self")
Cc: <stable@vger.kernel.org> # v4.9+
Signed-off-by: Amir Goldstein <amir73il@gmail.com>
Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-12-17 20:39:21 +01:00
..
Kconfig ovl: introduce the inodes index dir feature 2017-07-04 22:03:17 +02:00
Makefile ovl: split super.c 2016-12-16 11:02:56 +01:00
copy_up.c vfs: swap names of {do,vfs}_clone_file_range() 2018-11-10 07:48:33 -08:00
dir.c ovl: relax WARN_ON() on rename to self 2019-12-17 20:39:21 +01:00
inode.c ovl: filter of trusted xattr results in audit 2019-10-05 12:48:09 +02:00
namei.c ovl: fix error handling in ovl_verify_set_fh() 2018-11-21 09:24:04 +01:00
overlayfs.h ovl: fix format of setxattr debug 2018-10-10 08:54:27 +02:00
ovl_entry.h locking/barriers: Convert users of lockless_dereference() to READ_ONCE() 2017-12-25 14:26:21 +01:00
readdir.c ovl: fix wrong use of impure dir cache in ovl_iterate() 2018-09-09 19:55:58 +02:00
super.c ovl: Sync upper dirty data when syncing overlayfs 2018-08-03 07:50:43 +02:00
util.c ovl: fix memory leak on unlink of indexed file 2018-10-10 08:54:27 +02:00