Search
lxdream.org :: lxdream/src/mem.c :: diff
lxdream 0.9.1
released Jun 29
Download Now
filename src/mem.c
changeset 986:5090104b0963
prev975:007bf7eb944f
next1065:bc1cc0c54917
author nkeynes
date Wed Mar 04 23:12:21 2009 +0000 (15 years ago)
permissions -rw-r--r--
last change Move xltcache to xlat/ src directory
Commit new and improved x86 opcode file - cleaned up and added support for amd64 extended registers
file annotate diff log raw
1.1 --- a/src/mem.c Mon Jan 26 07:26:24 2009 +0000
1.2 +++ b/src/mem.c Wed Mar 04 23:12:21 2009 +0000
1.3 @@ -118,14 +118,14 @@
1.4 {
1.5 int i;
1.6 mem_region_fn_t *ptr;
1.7 - page_map = mmap( NULL, sizeof(sh4ptr_t) * LXDREAM_PAGE_TABLE_ENTRIES,
1.8 + page_map = (sh4ptr_t *)mmap( NULL, sizeof(sh4ptr_t) * LXDREAM_PAGE_TABLE_ENTRIES,
1.9 PROT_READ|PROT_WRITE, MAP_ANON|MAP_PRIVATE, -1, 0 );
1.10 if( page_map == MAP_FAILED ) {
1.11 FATAL( "Unable to allocate page map! (%s)", strerror(errno) );
1.12 }
1.13 memset( page_map, 0, sizeof(sh4ptr_t) * LXDREAM_PAGE_TABLE_ENTRIES );
1.14
1.15 - ext_address_space = mmap( NULL, sizeof(mem_region_fn_t) * LXDREAM_PAGE_TABLE_ENTRIES,
1.16 + ext_address_space = (mem_region_fn_t *) mmap( NULL, sizeof(mem_region_fn_t) * LXDREAM_PAGE_TABLE_ENTRIES,
1.17 PROT_READ|PROT_WRITE, MAP_ANON|MAP_PRIVATE, -1, 0 );
1.18 if( ext_address_space == MAP_FAILED ) {
1.19 FATAL( "Unable to allocate external memory map (%s)", strerror(errno) );
.