ps2link-a question

Discuss the development of software, tools, libraries and anything else that helps make ps2dev happen.

Moderators: cheriff, Herben

Post Reply
JorDy
Posts: 121
Joined: Sun Dec 11, 2005 8:45 am

ps2link-a question

Post 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...
User avatar
jbit
Site Admin
Posts: 293
Joined: Sat May 28, 2005 3:11 am
Location: København, Danmark
Contact:

Post 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.
JorDy
Posts: 121
Joined: Sun Dec 11, 2005 8:45 am

Post by JorDy »

i no it is unmapped but, explain how things like the sioshell can load above the kernel at 0x80050000
User avatar
Drakonite
Site Admin
Posts: 990
Joined: Sat Jan 17, 2004 1:30 am
Contact:

Post 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..
Shoot Pixels Not People!
Makeshift Development
misfire
Posts: 110
Joined: Mon Sep 06, 2004 7:53 am
Location: Germany

Post by misfire »

Check out this document.
TyRaNiD
Posts: 907
Joined: Sun Jan 18, 2004 12:23 am

Post 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.
Post Reply