This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

User-Level Virtual to Physical Mapping

I want to convert a Virtual to Physical Address to the use the Resizer in the DM644x SoC, but the memory region is not CMEM allocated.  Is there a way to do this?  The memory is allocated by the kernel for the framebuffer and I'm given a memory-mapped pointer directly to it.  I know how to do it for a driver or kernel level module, but I'm not sure how to do it in user space.

 

 

  • If you have the space in a kernel driver than you can map that into user space (give user space a virtual pointer to a physical address) using the mmap() call which is discussed in chapter 15 of Linux Device Drivers 3rd Edition. This is actually a user space call, though it is dependent on the driver cooperating to make the mmap happen, in general user space cannot convert directly to physical without some driver involvement under the basic premise of memory protection within Linux.