From: Al Viro <viro@zeniv.linux.org.uk>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org,
Ian Kent <raven@themaw.net>
Subject: [git pull] vfs.git autofs-related stuff
Date: Fri, 6 Dec 2019 00:58:53 +0000 [thread overview]
Message-ID: <20191206005853.GK4203@ZenIV.linux.org.uk> (raw)
autofs misuses checks for ->d_subdirs emptiness; the cursors are
in the same lists, resulting in false negatives. It's not needed anyway,
since autofs maintains counter in struct autofs_info, containing 0 for
removed ones, 1 for live symlinks and 1 + number of children for live
directories, which is precisely what we need for those checks. This
series switches to use of that counter and untangles the crap around
its uses (it needs not be atomic and there's a bunch of completely pointless
"defensive" checks).
This fell out of dcache_readdir work; the main point is to get
rid of ->d_subdirs abuses in there. I've more followup cleanups, but
I hadn't run those by Ian yet, so they can go next cycle.
The following changes since commit 5f68056ca50fdd3954a93ae66fea7452abddb66f:
autofs_lookup(): hold ->d_lock over playing with ->d_flags (2019-07-27 10:03:14 -0400)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs.git next.autofs
for you to fetch changes up to 850d71acd52cd331474116fbd60cf8b3f3ded93e:
autofs: don't bother with atomics for ino->count (2019-09-17 23:31:27 -0400)
----------------------------------------------------------------
Al Viro (4):
autofs_clear_leaf_automount_flags(): use ino->count instead of ->d_subdirs
autofs: get rid of pointless checks around ->count handling
autofs_dir_rmdir(): check ino->count for deciding whether it's empty...
autofs: don't bother with atomics for ino->count
fs/autofs/autofs_i.h | 2 +-
fs/autofs/expire.c | 6 +++---
fs/autofs/root.c | 39 ++++++++++++++-------------------------
3 files changed, 18 insertions(+), 29 deletions(-)
next reply other threads:[~2019-12-06 0:58 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-12-06 0:58 Al Viro [this message]
2019-12-06 1:20 ` [git pull] vfs.git autofs-related stuff pr-tracker-bot
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=20191206005853.GK4203@ZenIV.linux.org.uk \
--to=viro@zeniv.linux.org.uk \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=raven@themaw.net \
--cc=torvalds@linux-foundation.org \
/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