Commit 07f2af7b authored by Konstantin Khlebnikov's avatar Konstantin Khlebnikov Committed by Miklos Szeredi

ovl: honor flag MS_SILENT at mount

This patch hides error about missing lowerdir if MS_SILENT is set.

We use mount(NULL, "/", "overlay", MS_SILENT, NULL) for testing support of
overlayfs: syscall returns -ENODEV if it's not supported. Otherwise kernel
automatically loads module and returns -EINVAL because lowerdir is missing.
Signed-off-by: default avatarKonstantin Khlebnikov <khlebnikov@yandex-team.ru>
Signed-off-by: default avatarMiklos Szeredi <mszeredi@redhat.com>
parent 11f37104
...@@ -936,7 +936,8 @@ static int ovl_fill_super(struct super_block *sb, void *data, int silent) ...@@ -936,7 +936,8 @@ static int ovl_fill_super(struct super_block *sb, void *data, int silent)
err = -EINVAL; err = -EINVAL;
if (!ufs->config.lowerdir) { if (!ufs->config.lowerdir) {
pr_err("overlayfs: missing 'lowerdir'\n"); if (!silent)
pr_err("overlayfs: missing 'lowerdir'\n");
goto out_free_config; goto out_free_config;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment