I think the best thing would be to extend generic_file_write
(mm/filemap.c) to recognize if its writing a complete page to disk in
which case it will not duplicate that page. (Issues with getting the
buffer cache to support this remain.) This should make either the
mmap/write or sendfile aproach be zero-copy. I am given the impression
that this is just what the TCP/IP version of write does to make it
zero-copy.
-
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/