ovl: resolve more conflicting mount options
authorAmir Goldstein <amir73il@gmail.com>
Thu, 9 Apr 2020 15:58:34 +0000 (18:58 +0300)
committerMiklos Szeredi <mszeredi@redhat.com>
Wed, 13 May 2020 09:11:24 +0000 (11:11 +0200)
commitb0def88d807f6db6076aab2aeb11f542036e81a6
tree5b38242c01c2fe6af8c1a79d13dd5156d8c20dd5
parent9aafc1b0187322fa4fd4eb905d0903172237206c
ovl: resolve more conflicting mount options

Similar to the way that a conflict between metacopy=on,redirect_dir=off is
resolved, also resolve conflicts between nfs_export=on,index=off and
nfs_export=on,metacopy=on.

An explicit mount option wins over a default config value.  Both explicit
mount options result in an error.

Without this change the xfstests group overlay/exportfs are skipped if
metacopy is enabled by default.

Reported-by: Chengguang Xu <cgxu519@mykernel.net>
Signed-off-by: Amir Goldstein <amir73il@gmail.com>
Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Documentation/filesystems/overlayfs.rst
fs/overlayfs/super.c