![]() | |||||||||||||
Messages in this thread |
On Thu, 5 Aug 2004, Michael Halcrow wrote: > > I often have a virtual address to work with in the first place, and > the data that I hash usually occupies less than one page (passphrases, > keys, etc.). Ehh. A lot of encryption algorithms are not re-entrant, which means that you can't take page faults in the middle without serious trouble. And if the data is smaller than a page, then it's cheaper to just copy it into kernel memory than it is to try to follow the page tables by hand. One is usually nice cached accesses, the other one is nasty code with locking and often totally uncached. So I'd strongly suggest against doing any "raw crypto access". Zero-copy is often just a complicated way of doing things slowly, all in the name of some benchmark performance. Linus - 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 14:05 [from the cache] ©2003-2008 | |||||||||||||