Re: Allocate continuous memory and physical address.

2009-11-12 Thread Mulyadi Santosa
On 11/12/09, Johnny Hung johnny.hack...@gmail.com wrote: Hi All: I am writing user space application and need to allocate a continuous memory. The size is just 64KB and I also need to know the allocated physical memory address. Is is possible to do it in user space or it should be done it

Re: Allocate continuous memory and physical address.

2009-11-12 Thread Johnny Hung
Thanks for your replied. I surveyed in the internet and found the kerenl's kmalloc API also return a continuous memory address. Is it right? So there are two kernel APIs (__get_free_page, kmalloc) return a _continuous_ memory address (virtual address) and it can be convert to physical address by

Re: Allocate continuous memory and physical address.

2009-11-12 Thread Joel Fernandes
Yes that's right, AFAIK kmap allocates physically contiguous memory and vmalloc allocates virtual contiguous memory. Sorry, change kmap to kmalloc. Regards, -Joel -- To unsubscribe from this list: send an email with unsubscribe kernelnewbies to ecar...@nl.linux.org Please read the FAQ at

Re: Allocate continuous memory and physical address.

2009-11-12 Thread Joel Fernandes
Thanks for your replied. I surveyed in the internet and found the kerenl's kmalloc API also return a continuous memory address. Is it right? So there are two kernel APIs (__get_free_page, kmalloc) return a _continuous_ memory address (virtual address) and it can be convert to physical address

Allocate continuous memory and physical address.

2009-11-11 Thread Johnny Hung
Hi All: I am writing user space application and need to allocate a continuous memory. The size is just 64KB and I also need to know the allocated physical memory address. Is is possible to do it in user space or it should be done it kernel space? BTW, how to allocate continuous physical memory