The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Olaf Dietsche <olaf.dietsche#list.linux-kernel@t-online.de>
To: linux-kernel@vger.kernel.org
Cc: viro@math.psu.edu
Subject: [PATCH] 2.5.46: switch quota and BSD acct off for busy fs?
Date: Fri, 08 Nov 2002 07:19:07 +0100	[thread overview]
Message-ID: <87adkkoa78.fsf@goat.bogus.local> (raw)

do_umount() does DQUOT_OFF() and acct_auto_close() before actually
unmounting the fs. I guess, this is wrong, as long as the fs is busy.

Possible fix below. Comments?

Regards, Olaf.

--- a/fs/namespace.c	Sat Oct  5 18:45:36 2002
+++ b/fs/namespace.c	Fri Nov  8 07:07:55 2002
@@ -334,6 +334,8 @@
 	down_write(&current->namespace->sem);
 	spin_lock(&dcache_lock);
 
+	retval = -EBUSY;
+	if (atomic_read(&mnt->mnt_count) == 2 || flags & MNT_DETACH) {
 	if (atomic_read(&sb->s_active) == 1) {
 		/* last instance - try to be smart */
 		spin_unlock(&dcache_lock);
@@ -344,8 +346,6 @@
 		security_ops->sb_umount_close(mnt);
 		spin_lock(&dcache_lock);
 	}
-	retval = -EBUSY;
-	if (atomic_read(&mnt->mnt_count) == 2 || flags & MNT_DETACH) {
 		if (!list_empty(&mnt->mnt_list))
 			umount_tree(mnt);
 		retval = 0;

                 reply	other threads:[~2002-11-08  6:12 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=87adkkoa78.fsf@goat.bogus.local \
    --to=olaf.dietsche#list.linux-kernel@t-online.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=viro@math.psu.edu \
    /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