Re: [PATCH 22/43] CacheFiles: Add a hook to write a single page of data to an inode [ver #46]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Christoph Hellwig <hch@xxxxxxxxxxxxx> wrote:

> > I don't think "write_one_page" sounds like a particularly good new
> > API addition.
> 
> I also thing it's not a nice one.  I still haven't seen a really good
> explanation of why it can't just use plain ->write

->write requires:

 (1) A struct file.  Refer to the ENFILE problem that my patch to do this
     raised.  The problem is that doing a tar of, say, a kernel tree
     immediately opens ~30000 files internally, and then userspace falls over
     with ENFILE all over the place.  My tests multiply that by 8.

     You (at least I think it was you) refused to countenance allocating file
     structs internally to the kernel that weren't accounted.

 (2) A pointer to a buffer.  That means kmapping a page for the duration of
     the write.

->write is quite heavy.  For something like ext3 it goes down through quite a
few layers, in and out of the fs, VM and VFS.  All this takes both time and
stack space.

I want to write a whole page from the kernel at a page-boundary in the file.
That means it is possible to use an extremely optimised aop to do that.

Really, what I want to do is have the filesystem issue its BIOs directly on
the netfs page, but the Ext3 people I talked to at the time thought that would
be too difficult to track.

David
--
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux