Do you have a question? Post it now! No Registration Necessary
Subject
- Posted on
alloc_pages_exact vs. alloc_pages
- 02-03-2012

Re: alloc_pages_exact vs. alloc_pages
"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."
and
http://lxr.free-electrons.com/source/mm/page_alloc.c#L2391
"2379 * alloc_pages_exact - allocate an exact number
physically-contiguous pages.
2380 * @size: the number of bytes to allocate
2381 * @gfp_mask: GFP flags for the allocation
2382 *
2383 * This function is similar to alloc_pages(), except that it
allocates the
2384 * minimum number of pages to satisfy the request. alloc_pages() can
only
2385 * allocate memory in power-of-two pages."

--
Using Opera's revolutionary email client: http://www.opera.com/mail /
Using Opera's revolutionary email client: http://www.opera.com/mail /
Site Timeline
- » Reading the Riot Act To ARM's developers
- — Next thread in » Embedded Linux
-
- » alsa / codec driver
- — Previous thread in » Embedded Linux
-
- » Crosscompiling for ARM: reloc type R_ARM_ABS32 is not supported for PIC - ...
- — Newest thread in » Embedded Linux
-
- » ottenere alim duale da trafo singolo
- — The site's Newest Thread. Posted in » Electronics Hobby (Italian)
-