mirror of
https://github.com/libretro/Mu.git
synced 2026-09-22 22:56:12 +00:00
Fix crashing with ARMv5 core
This commit is contained in:
@@ -24,7 +24,7 @@ void bad_write_half(uint32_t addr, uint16_t value) { warn("Bad write_half: %08x
|
||||
void bad_write_word(uint32_t addr, uint32_t value) { warn("Bad write_word: %08x %08x", addr, value); }
|
||||
|
||||
uint8_t *mem_and_flags = NULL;
|
||||
struct mem_area_desc mem_areas[4];
|
||||
struct mem_area_desc mem_areas[2];
|
||||
|
||||
void *phys_mem_ptr(uint32_t addr, uint32_t size) {
|
||||
unsigned int i;
|
||||
|
||||
@@ -26,7 +26,7 @@ struct mem_area_desc {
|
||||
uint32_t base, size;
|
||||
uint8_t *ptr;
|
||||
};
|
||||
extern struct mem_area_desc mem_areas[4];
|
||||
extern struct mem_area_desc mem_areas[2];
|
||||
void *phys_mem_ptr(uint32_t addr, uint32_t size);
|
||||
uint32_t phys_mem_addr(void *ptr);
|
||||
|
||||
|
||||
@@ -60,15 +60,8 @@ bool pxa255Init(uint8_t** returnRom, uint8_t** returnRam){
|
||||
mem_areas[1].ptr = mem_and_flags + mem_offset;
|
||||
mem_offset += TUNGSTEN_C_RAM_SIZE;
|
||||
|
||||
//PCMCIA0/1
|
||||
mem_areas[2].base = PXA255_PCMCIA0_START_ADDRESS;
|
||||
mem_areas[2].size = PXA255_PCMCIA0_SIZE + PXA255_PCMCIA1_SIZE;
|
||||
mem_areas[2].ptr = NULL;
|
||||
|
||||
//CPU registers
|
||||
mem_areas[3].base = PXA255_REG_START_ADDRESS;
|
||||
mem_areas[3].size = PXA255_REG_SIZE;//size of address space, not all of it is mapped
|
||||
mem_areas[3].ptr = NULL;
|
||||
//memory regions that are not directly mapped to a buffer are not added to mem_areas
|
||||
//adding them will cause SIGSEGVs
|
||||
|
||||
//accessors
|
||||
//default
|
||||
|
||||
Reference in New Issue
Block a user