title: share memory allocated at boot time to user space
body: <p>I am searching a solution to allocate memory from kernel to be accessible by the DMA and shared with user space for fast communication, According to <a href="https://www.google.com/url?sa=t&amp;rct=j&amp;q=&amp;esrc=s&amp;source=web&amp;cd=1&amp;cad=rja&amp;uact=8&amp;ved=0ahUKEwiWz9ni5KnNAhXE0hoKHS9QCf8QFggeMAA&amp;url=http%3A%2F%2Fwww.oreilly.com%2Fopenbook%2Flinuxdrive3%2Fbook%2Fch08.pdf&amp;usg=AFQjCNGKLzUZByH93jx0KkSl5ePuaXssQA&amp;sig2=1AIstuu9NCcVsCOyFbwmyA" rel="nofollow noreferrer">chap08</a> of linux driver3 the only way to allocate huge memory is at boot time method using the function bellow: </p>
  
  <pre><code>#include &lt;linux/bootmem.h&gt;
  void *alloc_bootmem_low_pages(unsigned long size);
  </code></pre>
  
  <p>i don't know if this memory can be mapped to user space using mmap() like the memory allocated with kmalloc() ? </p>
  
  <p>i have seen those posts but still get no answer</p>
  
  <p><a href="https://stackoverflow.com/questions/25896231/allocating-a-physical-memory-buffer-in-linux">Allocating a physical memory buffer in linux</a></p>
  
  <p><a href="https://stackoverflow.com/questions/37549510/allocating-statically-memory-at-kernel-boot-time">Allocating (statically) memory at kernel boot time</a></p>