|WP1 - RTOS State of the Art Analysis: Deliverable D1.1 - RTOS Analysis
|Chapter 6. Realtime Support in Linux
It is not possible to build realtime applications on a system with virtual memory. The random and long delays introduced when RAM is exhausted and swapping is required is intolerable in a realtime system. Linux provides the mlock() and mlockall() functions that disables paging for the specified range of memory, or for the whole process respectively. Therefore, all the "locked" memory will stay in RAM until the process exits or unlocks the memory.
mlock() and mlockall() are included in the POSIX realtime extensions.