mirror of
git://projects.qi-hardware.com/ben-blinkenlights.git
synced 2024-11-27 17:05:20 +02:00
ubb-patgen/ubb-patgen.c (dma_pattern): mlockall (before address translation and DMA)
This commit is contained in:
parent
c6306ff591
commit
dad97398d3
@ -18,6 +18,7 @@
|
||||
#include <math.h>
|
||||
#include <time.h>
|
||||
#include <assert.h>
|
||||
#include <sys/mman.h>
|
||||
#include <asm/cachectl.h>
|
||||
|
||||
#include <ubb/ubb.h>
|
||||
@ -361,7 +362,12 @@ static void dma_pattern(const struct mmcclk *clk,
|
||||
exit(1);
|
||||
}
|
||||
buf = parse_pattern(pattern, &n);
|
||||
|
||||
|
||||
if (mlockall(MCL_CURRENT | MCL_FUTURE)) {
|
||||
perror("mlockall");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
dma_init();
|
||||
|
||||
/* Initial static state: the first pattern. */
|
||||
|
Loading…
Reference in New Issue
Block a user