[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20101021194044.GC19804@ZenIV.linux.org.uk>
Date: Thu, 21 Oct 2010 20:40:45 +0100
From: Al Viro <viro@...IV.linux.org.uk>
To: Dave Chinner <david@...morbit.com>
Cc: linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 08/21] fs: rework icount to be a locked variable
On Thu, Oct 21, 2010 at 11:49:33AM +1100, Dave Chinner wrote:
> From: Dave Chinner <dchinner@...hat.com>
>
> The inode reference count is currently an atomic variable so that it
> can be sampled/modified outside the inode_lock. However, the
> inode_lock is still needed to synchronise the final reference count
> and checks against the inode state.
>
> To avoid needing the protection of the inode lock, protect the inode
> reference count with the per-inode i_lock and convert it to a normal
> variable. To avoid existing out-of-tree code accidentally compiling
> against the new method, rename the i_count field to i_ref. This is
> relatively straight forward as there are limited external references
> to the i_count field remaining.
BTW, the same thing as with Nick's set - separate patch for "clone the
reference to inode we are already holding" helper, in front of queue.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists