Page 1 of 1
ps2link-a question
Posted: Sat May 13, 2006 5:14 am
by JorDy
well i would like to know why when i try to load my elf which opens above 0x01FFFFFF, the ps2link error/debug screen apears with all the register values etc...
i also tried for a simple test doing a load word or a memory dump above 0x01FFFFFF and the same thing happens...
Posted: Sat May 13, 2006 5:33 am
by jbit
Is this a trick question?
The PS2 has 32mb of ram, which is mapped from 0x00000000 to 0x02000000.
Since anything above 0x01ffffff (well, other than registers, and memory mirrors) isn't mapped, it'll cause a load/store exception when accessed. If ps2link is loaded, it'll catch the exception and display a helpful debug screen.
Posted: Sat May 13, 2006 5:51 am
by JorDy
i no it is unmapped but, explain how things like the sioshell can load above the kernel at 0x80050000
Posted: Sat May 13, 2006 9:34 am
by Drakonite
Because that memory is mapped...
You haven't worked with mips much have you? ....
0x80000000 is another way of addressing 0x00000000. There are a couple different ways of addressing the same memory, the difference being cache and such..
Posted: Wed May 17, 2006 5:43 am
by misfire
Posted: Wed May 17, 2006 6:29 am
by TyRaNiD
The MIPS memory model considers the < 1GB roughly to be user mapped memory setup in the MMU hardware of the CPU, anything above 2GB (0x80000000 and above) are kernel memory pages with 1 to 1 mapping to physical memory. The PS2 kernel sets up the TLB stuff to map in approx 31.5 megs of ram between I think 0x80000 and 0x2000000 which can be accessed in user mode, these are direct mapped from physical ram. Note if you try to access below 0x80000 it will crash the PS2 :)
sioshell jams itself in the kernel memory space for shits and giggles, to do that you need to be in kernel mode, ps2link doesn't run in kernel mode so loading an elf linked to that sort of address will fail.