Hi
I have a problem with rt_heap; I write a simple program:
############################
#include <sys/mman.h>
#include <native/heap.h>
RT_HEAP M_HEAP;
int main(void) {
int ret;
int * tmp;
/* no memory-swapping for this programm */
mlockall(MCL_CURRENT | MCL_FUTURE);
ret = rt_heap_create(&M_HEAP, "M_HEAP", 5 * 1024 * 1024 , 0);
if (ret) {
fprintf(stderr, "fail to create heap, code %d\n", ret);
return ret;
}
sleep(10);
ret = rt_heap_delete(&M_HEAP);
if (ret) {
fprintf(stderr, "fail to delete heap, code %d\n", ret);
return;
}
return 0;
}
#######################
this program previously worked on another PC. but now when I execute it on the
new PC, It cause the kernel panic ( Unable to handle null pointer reference
...). same kernel is run on two PC, and not seems any difference. but now I
print memory status (/proc/meminfo). a huge difference is found!
in first pc ( that program worked ) total vmalloc = totol memory = 510 M and
highmem = 0, but on second pc ( that kernel panic ) total vmalloc = 119M but
total memory = 1 G and highmem = 122.
have everyone any idea?
I glade to see your comments.
_______________________________________________
Xenomai-core mailing list
[email protected]
https://mail.gna.org/listinfo/xenomai-core