[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH][2/17] USB virt 2.6 split driver---xenidc buffer resource provider



On 22 Nov 2005, at 11:22, Muli Ben-Yehuda wrote:

Quoth Linus[1[:

"vmalloc() is NOT SOMETHING YOU SHOULD EVER USE! It's only valid for
when you _need_ a big array, and you don't have any choice. It's slow,
and it's a very restricted resource: it's a global resource that is
literally restricted to a few tens of megabytes. It should be _very_
carefully used."

He also says the correct fix is to not need a multi-page chunk in the first place. If you do, then you should pre-allocate. If that's impossible (e.g., you're a module) then you use vmalloc(). The page allocator does not attempt any compaction, so even if there is plenty of memory you may well not find a big contiguous extent.

 -- Keir


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.