linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jan Blunck <jblunck@suse.de>
To: viro@ZenIV.linux.org.uk
Cc: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org,
	vaurora@redhat.com, hch@lst.de, miklos@szeredi.hu
Subject: [PATCH] VFS: propagate mnt_flags into do_loopback
Date: Wed, 17 Jun 2009 22:45:06 +0200	[thread overview]
Message-ID: <1245271510-31542-3-git-send-email-jblunck@suse.de> (raw)
In-Reply-To: <1245271510-31542-1-git-send-email-jblunck@suse.de>

The mnt_flags are propagated into do_loopback(), so that they can be checked
when mounting something loopback into a union.

Signed-off-by: Jan Blunck <jblunck@suse.de>
Signed-off-by: Valerie Aurora (Henson) <vaurora@redhat.com>
---
 fs/namespace.c |    7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/fs/namespace.c b/fs/namespace.c
index 134d494..bdff9e4 100644
--- a/fs/namespace.c
+++ b/fs/namespace.c
@@ -1475,8 +1475,8 @@ static int do_change_type(struct path *path, int flag)
 /*
  * do loopback mount.
  */
-static int do_loopback(struct path *path, char *old_name,
-				int recurse)
+static int do_loopback(struct path *path, char *old_name, int recurse,
+		       int mnt_flags)
 {
 	struct path old_path;
 	struct vfsmount *mnt = NULL;
@@ -1971,7 +1971,8 @@ long do_mount(char *dev_name, char *dir_name, char *type_page,
 		retval = do_remount(&path, flags & ~MS_REMOUNT, mnt_flags,
 				    data_page);
 	else if (flags & MS_BIND)
-		retval = do_loopback(&path, dev_name, flags & MS_REC);
+		retval = do_loopback(&path, dev_name, flags & MS_REC,
+				     mnt_flags);
 	else if (flags & (MS_SHARED | MS_PRIVATE | MS_SLAVE | MS_UNBINDABLE))
 		retval = do_change_type(&path, flags);
 	else if (flags & MS_MOVE)
-- 
1.6.0.2


  parent reply	other threads:[~2009-06-17 20:45 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-17 20:45 [PATCH] Preparation work for VFS based union mounts Jan Blunck
2009-06-17 20:45 ` [PATCH] VFS: BUG() if somebody tries to rehash an already hashed dentry Jan Blunck
2009-06-17 20:45 ` Jan Blunck [this message]
2009-06-17 20:45 ` [PATCH] VFS: Make lookup_hash() return a struct path Jan Blunck
2009-06-18 11:19   ` James Morris
2009-06-17 20:45 ` [PATCH] VFS: Remove unnecessary micro-optimization in cached_lookup() Jan Blunck
2009-06-17 20:45 ` [PATCH] VFS: Make real_lookup() return a struct path Jan Blunck
2009-06-18 11:21   ` James Morris
2009-06-17 20:45 ` [PATCH] VFS: Introduce dput() variant that maintains a kill-list Jan Blunck
2009-06-18 11:30   ` James Morris

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1245271510-31542-3-git-send-email-jblunck@suse.de \
    --to=jblunck@suse.de \
    --cc=hch@lst.de \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=miklos@szeredi.hu \
    --cc=vaurora@redhat.com \
    --cc=viro@ZenIV.linux.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).