[patch 01/46] touch_mnt_namespace when the mount flags change

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Greg KH
Date: Monday, November 17, 2008 - 12:14 am

2.6.27-stable review patch.  If anyone has any objections, please let us know.

------------------

From: Dan Williams <dan.j.williams@intel.com>

commit 0e55a7cca4b66f625d67b292f80b6a976e77c51b upstream

Daemons that need to be launched while the rootfs is read-only can now
poll /proc/mounts to be notified when their O_RDWR requests may no
longer end in EROFS.

Cc: Kay Sievers <kay.sievers@vrfy.org>
Cc: Neil Brown <neilb@suse.de>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>

---
 fs/namespace.c |    7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

--- a/fs/namespace.c
+++ b/fs/namespace.c
@@ -1553,8 +1553,13 @@ static noinline int do_remount(struct na
 	if (!err)
 		nd->path.mnt->mnt_flags = mnt_flags;
 	up_write(&sb->s_umount);
-	if (!err)
+	if (!err) {
 		security_sb_post_remount(nd->path.mnt, flags, data);
+
+		spin_lock(&vfsmount_lock);
+		touch_mnt_namespace(nd->path.mnt->mnt_ns);
+		spin_unlock(&vfsmount_lock);
+	}
 	return err;
 }
 

-- 
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[patch 00/46] 2.6.27.7-stable review, Greg KH, (Mon Nov 17, 12:13 am)
[patch 01/46] touch_mnt_namespace when the mount flags change, Greg KH, (Mon Nov 17, 12:14 am)
[patch 14/46] rtl8187: Add Abocom USB ID, Greg KH, (Mon Nov 17, 12:15 am)
[patch 21/46] r8169: select MII in Kconfig, Greg KH, (Mon Nov 17, 12:15 am)
[patch 26/46] S390: cpu topology: fix locking, Greg KH, (Mon Nov 17, 12:15 am)
[patch 35/46] USB: gadget: cdc-acm deadlock fix, Greg KH, (Mon Nov 17, 12:16 am)
[patch 37/46] USB: Fix PS3 USB shutdown problems, Greg KH, (Mon Nov 17, 12:16 am)
[patch 39/46] USB: EHCI: fix divide-by-zero bug, Greg KH, (Mon Nov 17, 12:16 am)
[patch 42/46] ACPI: EC: revert msleep patch, Greg KH, (Mon Nov 17, 12:17 am)
[patch 43/46] ACPI: EC: wait for last write gpe, Greg KH, (Mon Nov 17, 12:17 am)
[patch 44/46] ACPI: EC: restart failed command, Greg KH, (Mon Nov 17, 12:17 am)
Re: [patch 25/46] V4L/DVB (9624): CVE-2008-5033: fix OOPS ..., Mauro Carvalho Chehab, (Mon Nov 17, 6:31 am)
Re: [stable] [patch 24/46] Fix broken ownership of /proc/s ..., Rafael J. Wysocki, (Mon Nov 17, 3:25 pm)