![]() | |||||||||||||
Messages in this thread |
On Mon, Nov 17, 2003 at 09:42:09AM +0000, Tigran Aivazian wrote: > Here are two files: simple.c kernel module and user.c user test program. > If you (or anyone) believe it is possible to return more than a single > page on a read(2) please change them accordingly and let me know. Sorry, I needed to amend that. It's not a fixed PAGE_SIZE buffer; the buffer is only resized up to the point it allows a single ->show() call to succeed, and then you get short reads if you try to go beyond the buffer size in a single read. You could (in theory) get this to succeed > PAGE_SIZE reads by doing the operation all in a single ->show() call, but that will have some large overheads and will also have a retry loop where the buffer size is doubled until the ->show() call succeeds incurred at least once per open() at the time of the first read(). -- wli - 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/ | ||||||||||||
| Last update: 2005-03-22 12:58 [from the cache] ©2003-2008 | |||||||||||||