Re: VM deadlock

Rik van Riel (riel@conectiva.com.br)
Wed, 27 Jun 2001 17:36:45 -0300 (BRST)


On Wed, 27 Jun 2001, Chris Mason wrote:
> On Wednesday, June 27, 2001 04:43:28 PM -0300 Rik van Riel

> > If you don't have free memory, you are limited to 2 choices:
> >
> > 1) wait on IO
> > 2) spin endlessly, wasting CPU until the IO is done
>
> Ok, I need to describe the problem a little better. reiserfs
> inodes need to be logged, which means you have to join/start a
> transaction in order to write them.

> So, the only time reiserfs_write_inode needs to do something is for fsync
> and/or O_SYNC writes, and all it needs to do is commit the transaction.
>
> Any time kswapd is calling write_inode, it is just trying to
> free the inode struct, and reiserfs can safely ignore the write
> request, regardless of if a sync is requested.

OK, sounds sane enough to me ;)

So the fix is just to let reiserfs_write_inode always be
asynchronous, independent of its arguments, as long as
we're not in fsync() or O_SYNC.

OTOH, if we are called synchronously, we could also just
walk down the code path taken when we _are_ called by
fsync(), right ?

regards,

Rik

--
Executive summary of a recent Microsoft press release:
   "we are concerned about the GNU General Public License (GPL)"

http://www.surriel.com/ http://www.conectiva.com/ http://distro.conectiva.com/

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/