From 70586d1f66c1dc130bbae2f0e19d6e4160bc006a Mon Sep 17 00:00:00 2001 From: ToadKing Date: Fri, 26 Apr 2013 13:14:25 -0400 Subject: [PATCH] bump libogc memory reserve to 256KB wiimotes were acting up without it --- Makefile.wii | 2 +- wii/mem2_manager.c | 9 +++++---- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/Makefile.wii b/Makefile.wii index 30d6c6314b..07f0e2c947 100644 --- a/Makefile.wii +++ b/Makefile.wii @@ -7,7 +7,7 @@ PERF_TEST = 0 WHOLE_ARCHIVE_LINK = 0 BIG_STACK = 0 -PC_DEVELOPMENT_IP_ADDRESS = "192.168.1.13" +PC_DEVELOPMENT_IP_ADDRESS = "192.168.1.6" PC_DEVELOPMENT_UDP_PORT = 3490 # system platform diff --git a/wii/mem2_manager.c b/wii/mem2_manager.c index b8fb75c038..234c9f0c7a 100644 --- a/wii/mem2_manager.c +++ b/wii/mem2_manager.c @@ -75,12 +75,13 @@ bool gx_init_mem2() // BIG NOTE: MEM2 on the Wii is 64MB, but a portion of that is reserved for // IOS. libogc by default defines the "safe" area for MEM2 to go from // 0x90002000 to 0x933E0000. However, from my testing, I've found I need to - // reserve about 128KB for stuff like network and USB to work correctly. + // reserve about 256KB for stuff like network and USB to work correctly. // However, other sources says these functions need at least 0xE0000 bytes, // 7/8 of a megabyte, of reserved memory to do this. My initial testing - // shows that we can work with only 128KB, but if some stuff mysteriously - // stops working, try fiddling with this size. - u32 size = SYS_GetArena2Size() - 1024 * 128; + // shows that we can work with only 128KB, but we use 256KB becuse testing + // has shown some stuff being iffy with only 128KB, mainly wiimote stuff. + // If some stuff mysteriously stops working, try fiddling with this size. + u32 size = SYS_GetArena2Size() - 1024 * 256; void *heap_ptr = (void *) ROUNDUP32(((u32) SYS_GetArena2Hi() - size));