Re: VFS interactions with UML and other big UML changes (was: Re:[patch 1/2] Uml - first part rework of run_helper() and users.)

From: Andrew Morton
Date: Tue Nov 30 2004 - 19:39:37 EST


Blaisorblade <blaisorblade_spam@xxxxxxxx> wrote:
>
> static struct address_space_operations hostfs_aops = {
> .writepage = hostfs_writepage,
> .readpage = hostfs_readpage,
> /* .set_page_dirty = __set_page_dirty_nobuffers, */
> .prepare_write = hostfs_prepare_write,
> .commit_write = hostfs_commit_write
> };
>
> Actually, hostfs is a nodev filesystem, but I simply don't know if that
> implies that it uses no buffers. So, should
>
> .set_page_dirty = __set_page_dirty_nobuffers
>
> be uncommented? Or should it be deleted (leaving it there is not a good
> option).

See the operation of set_page_dirty().

If you have NULL ->set_page_dirty a_op then set_page_dirty() will fall
through to __set_page_dirty_buffers().

If your fs never sets PG_private then __set_page_dirty_buffers() will just
do what __set_page_dirty_nobuffers() does.

Without having looked at it, I'm sure that hostfs does not use
buffer_heads. So setting your ->set_page_dirty a_op to point at
__set_page_dirty_nobuffers() is a reasonable thing to do - it'll provide a
slight speedup.

-
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/