[Top] [All Lists]

Re: [2.6.27-rc4] XFS i_lock vs i_iolock...

To: Peter Zijlstra <peterz@xxxxxxxxxxxxx>
Subject: Re: [2.6.27-rc4] XFS i_lock vs i_iolock...
From: Christoph Hellwig <hch@xxxxxx>
Date: Mon, 25 Aug 2008 23:55:32 +0200
Cc: Dave Chinner <david@xxxxxxxxxxxxx>, Lachlan McIlroy <lachlan@xxxxxxx>, Daniel J Blueman <daniel.blueman@xxxxxxxxx>, Linux Kernel <linux-kernel@xxxxxxxxxxxxxxx>, xfs@xxxxxxxxxxx, hch@xxxxxx
In-reply-to: <1219647573.20732.28.camel@twins>
References: <6278d2220808221412x28f4ac5dl508884c8030b364a@mail.gmail.com> <20080825010213.GO5706@disturbed> <48B21507.9050708@sgi.com> <20080825035542.GR5706@disturbed> <1219647573.20732.28.camel@twins>
Sender: xfs-bounce@xxxxxxxxxxx
User-agent: Mutt/1.3.28i
On Mon, Aug 25, 2008 at 08:59:33AM +0200, Peter Zijlstra wrote:
> How can you take two locks in one go? It seems to me you always need to
> take them one after another, and as soon as you do that, you have
> ordering constraints.

Yes, you would.  Except that in all other places we only have a single
iolock involved, so the ordering of the second iolock and second ilock
don't matter.

Because of that I think declaring that xfs_lock_two_inodes can just
lock on lock type at a time might be the better solution.

<Prev in Thread] Current Thread [Next in Thread>