Files
linux/fs
Miklos Szeredi f9f300a922 ovl: fix warning in ovl_create_real()
commit 1f5573cfe7 upstream.

Syzbot triggered the following warning in ovl_workdir_create() ->
ovl_create_real():

	if (!err && WARN_ON(!newdentry->d_inode)) {

The reason is that the cgroup2 filesystem returns from mkdir without
instantiating the new dentry.

Weird filesystems such as this will be rejected by overlayfs at a later
stage during setup, but to prevent such a warning, call ovl_mkdir_real()
directly from ovl_workdir_create() and reject this case early.

Reported-and-tested-by: syzbot+75eab84fd0af9e8bf66b@syzkaller.appspotmail.com
Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-12-22 09:29:40 +01:00
..
2020-11-05 11:43:34 +01:00
2021-10-27 09:54:27 +02:00
2021-07-14 16:53:17 +02:00
2021-09-22 12:26:25 +02:00
2021-11-17 09:48:42 +01:00
2021-11-26 10:47:21 +01:00
2020-10-01 13:17:19 +02:00
2020-03-25 08:25:58 +01:00
2019-12-17 19:55:30 +01:00
2021-12-14 14:49:02 +01:00