Thread (12 messages) 12 messages, 5 authors, 2014-03-04

Re: change kmalloc into vmalloc for large memory allocations

From: Steven Rostedt <rostedt@goodmis.org>
Date: 2014-02-28 14:11:38
Also in: alsa-devel, linux-arm-kernel, linux-arm-msm, netdev, netfilter-devel

On Fri, 28 Feb 2014 16:15:23 +0800
"Wang, Yalin" [off-list ref] wrote:
Kfree(ptr)
{
	If (is_vmalloc_addr(ptr))
		Vfree(ptr);
	Else
		Kfree(ptr);
}


But we need add some flags to ensure always use kmalloc for
Some special use (dma etc..)

How do you think of it ?
But vmalloc also takes up tlb entries. The more vmalloc space you have,
the more tlb entries that will need to be used, which will have a
performance affect on the entire system.

I would be against making kmalloc() secretly doing a vmalloc. If it is
better for a driver to use a vmalloc on large items, than change the
driver. Don't change a core function.

-- Steve
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help