Re: [PATCH v3 2/3] Call the filesystem back whenever a page isremoved from the page cache

From: Linus Torvalds
Date: Wed Dec 01 2010 - 23:00:11 EST


On Wed, Dec 1, 2010 at 7:53 PM, Trond Myklebust
<Trond.Myklebust@xxxxxxxxxx> wrote:
>
> Again, I was being cautious (I freely admit to not having studied
> stop_machine()). If nobody disagrees with your interpretation, then I'm
> very happy to drop the preempt disable/enable crud.

Just remove it. It won't matter for the stop_machine case, and the
other case that Andrew pointed out (just unmap with memory pressure)
is an independent thing that doesn't do stop_machine anyway.

In the next merge window we'll see the whole RCU name lookup (let's
see if people can agree on it, or whether I'll just have to do an
executive decision and push it through even without consensus), which
then rcu-delays inode freeing, and that will fix it for real. When
that happens, doing a "rcu_read_lock()" in vmscan.c before the removal
of the page from the mapping, and then unlocking after the callback
will be a real fix, but it will require the rcu release to be that
real fix anyway, so doing something else now will just confuse things.

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