lkml.org 
[lkml]   [2008]   [May]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH][RFC] Add alloc_pages_exact() and free_pages_exact()
From
Date
Timur Tabi writes:

> alloc_pages_exact() is similar to alloc_pages(), except that it allocates
> the minimum number of pages to fulfill the request. This is useful if you
> want to allocate a very large buffer that is slightly larger than an
> even power-of-two number of pages. In that case, alloc_pages() will waste
> a lot of memory.

FWIW, I wished I had something like this when doing the cafe_ccic
driver. I can't really attest to the validity of the core VM stuff, but
I will say that the interface is worth having.

Thanks for doing this!

jon


\
 
 \ /
  Last update: 2008-05-14 16:09    [W:0.608 / U:0.016 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site