From: Al Viro <viro@ZenIV.linux.org.uk>
To: Adrian McMenamin <adrianmcmenamin@gmail.com>
Cc: Adrian McMenamin <lkmladrian@gmail.com>,
LKML <linux-kernel@vger.kernel.org>,
linux-fsdevel@vger.kernel.org,
Linux-sh <linux-sh@vger.kernel.org>
Subject: Re: [PATCH] VMUFAT filesystem [2/4]
Date: Wed, 21 Mar 2012 19:42:03 +0000 [thread overview]
Message-ID: <20120321194202.GP6589@ZenIV.linux.org.uk> (raw)
In-Reply-To: <CACwZE5TaUBLwsz0qMNqih9qnE1awP3i048ds-Say+xMAJXnMDA@mail.gmail.com>
On Wed, Mar 21, 2012 at 04:32:59PM +0800, Adrian McMenamin wrote:
> On 21 March 2012 13:37, Al Viro <viro@zeniv.linux.org.uk> wrote:
>
> ...
>
> OK, points essentially taken and will push through another patch in
> due course ... just a couple of points, though:
>
> * Did the defensive stuff because bad guys might inject evil code
> rather than because I thought in normal run of execution there would
> be an issue - guess I just have to forget that?
Remove ones that are provably useless. If your bad guys really manage to
get their code in kernel mode, you have already lost as thoroughly as one can.
> * On the semaphore - what should I use? Uninterruptible? Spinlock?
> Aren't there big downsides to them also?
Depends on the things you are going to do under it. Spinlocks are OK only
for non-blocking areas; in this context I'd probably go for a plain mutex -
you don't need it to protect directory, since all directory operations have
->i_mutex on your only directory inode, but you need something to protect
your block allocator...
prev parent reply other threads:[~2012-03-21 19:42 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-03-21 4:32 [PATCH] VMUFAT filesystem [2/4] Adrian McMenamin
2012-03-21 5:37 ` Al Viro
2012-03-21 8:32 ` Adrian McMenamin
2012-03-21 19:42 ` Al Viro [this message]
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=20120321194202.GP6589@ZenIV.linux.org.uk \
--to=viro@zeniv.linux.org.uk \
--cc=adrianmcmenamin@gmail.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-sh@vger.kernel.org \
--cc=lkmladrian@gmail.com \
/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).