System files corrupted brick

Discussion in 'Wii - Hacking' started by WiiCrazy, Nov 24, 2008.

  1. WiiCrazy
    OP

    WiiCrazy Be water my friend!

    Member
    2,391
    1
    May 8, 2008
    Istanbul
    Taking a close look on wii's memory map figured out something... Firstly this is only for those that can use trucha signed discs

    At the very bottom of the table in the wiibrew article (http://www.wiibrew.org/wiki/Memory_Map)
    0x80003F00 0x132c100 (~19.2MB) Standard application executable area
    0x81330000 0x4d0000 (~4.8MB) Loader executable area

    In loader executable area our system menu resides, and once a disc put into the wii, system runs the apploader and apploader tells the system the memory sections of the initial executable (main.dol) and it's loaded into above defined standard application executable area...

    on a sane wii, if the disc is autoboot system boots the code loaded into the standard application executable area..
    on a wii with "system files corrupted" error the dol is not booted yet it's loaded into the standard executable area...

    so the result is, system menu can be patched with the apploader to jump to the dol loaded...

    of course to proove my theory we need examples of people bricked with the same error and can't boot an autoboot disc either from recovery menu or from the warning screen...

    If I find time, I'll test on my non-bricked wii with a non-autoboot disc if it's like that...

    For those interested, there is code and explanation as to how system menu can be patched using the freeloader's apploader below
    http://forum.wiibrew.org/read.php?8,1693,page=2


    by the way,
    jumping is not straight forward, here below c code taken from front sd elf loader (which is taken from gecko os) should be implemented without doing any ogc calls [​IMG]

    Code:
    __IOS_ShutdownSubsystems ();
    _CPU_ISR_Disable (level);
    __exception_closeall ();
    ep();
    _CPU_ISR_Restore (level);
    ep is the pointer to the dol entry point

    interrupt disabling and enabling is just two inline assembly defines, below is generic ppc code libogc also contains these defines

    Code:
     #define PPC_MSR_DISABLE_MASK 0x00008000
    
    #define _CPU_ISR_Disable( _isr_cookie ) \
    ÂÂÂÂ{ register u32 _disable_mask = PPC_MSR_DISABLE_MASK; \
    ÂÂÂÂÂÂ_isr_cookie = 0; \
    ÂÂÂÂÂÂasm volatile ( \
    ÂÂÂÂÂÂÂÂÂÂ"mfmsr %0; andc %1,%0,%1; mtmsr %1" : \
    ÂÂÂÂÂÂÂÂÂÂ"=&r" ((_isr_cookie)), "=&r" ((_disable_mask)) : \
    ÂÂÂÂÂÂÂÂÂÂ"0" ((_isr_cookie)), "1" ((_disable_mask)) \
    ÂÂÂÂÂÂÂÂÂÂ); \
    ÂÂÂÂ}
    
    
    
    #define _CPU_ISR_Enable( _isr_cookie )ÂÂ\
    ÂÂÂÂ{ \
    ÂÂÂÂÂÂ asm volatile ( "mtmsr %0" : \
    ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂ "=r" ((_isr_cookie)) : \
    ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂ "0" ((_isr_cookie))); \
    ÂÂÂÂ}
     


  2. ether2802

    ether2802 we have the techno...!!

    Former Staff
    4,350
    5
    Oct 14, 2007
    Mexico
    Pto. Vallarta
    You really got it going don't ya!!! why don't you make peaces with marcan and join the TT?? your ideas can be really helpful for the Wii Scene...!!! [​IMG]
     
  3. WiiCrazy
    OP

    WiiCrazy Be water my friend!

    Member
    2,391
    1
    May 8, 2008
    Istanbul
    Well actually don't know what is going on in the wii, it's completely french to me... the last time I did serious assembly coding was in 1994 on c64 and some x86 later at school...
    Ppc and wii architecture is huge beast compared to those... so I'm no way near TT or even the lamest coder in the wii scene... these things should be a piece of cake for them (TT)
     
  4. Brian117

    Brian117 GBAtemp Psycho!

    Member
    3,250
    712
    Oct 1, 2007
    United States
    Cleveland, OH
    Wow, very nice. You know what you're doing, that's for sure.

    Keep up the good work. finds* [​IMG]
     
  5. WiiCrazy
    OP

    WiiCrazy Be water my friend!

    Member
    2,391
    1
    May 8, 2008
    Istanbul
    Well there is no real work done actually, it may be a pointer to some of those talented coders in the wii scene...
     
  6. koala90

    koala90 Newbie

    Newcomer
    2
    0
    Oct 1, 2008
    United States
    When I turn my Wii on, that message appears. There's some way to fix it? If has, may you help me? I'm scared. T_T

    I didn't understand, you are searching a way for help who has that problem?
    Sorry for my bad english, I'm from Brazil, I don't speak very well. ^^'
     
  7. WiiCrazy
    OP

    WiiCrazy Be water my friend!

    Member
    2,391
    1
    May 8, 2008
    Istanbul
    First, this is just an idea rather than being a solution at the moment...
    Do you have 3.2 system menu and a modchip? And did you test autoboot discs?
     
  8. AdamBrunt

    AdamBrunt GBAtemp Advanced Fan

    Member
    699
    6
    Jun 24, 2003
    If my "maintenance, press all buttons on the D-pad" test doesn't work - I could try it BUT ... I'd need an iso of the disc that needs to be loaded.
     
  9. koala90

    koala90 Newbie

    Newcomer
    2
    0
    Oct 1, 2008
    United States
    My Wii turned on normal. o.O
    But any channel was working. I formated the Wii and now it's working normally. \o\
     
  10. WiiCrazy
    OP

    WiiCrazy Be water my friend!

    Member
    2,391
    1
    May 8, 2008
    Istanbul
    Well I should test my theory first with a normal system menu patcher, if it's worked out then continue with the apploader patching and finally testing it on a banner bricked wii... no ready iso at the moment..
     
  11. WiiCrazy
    OP

    WiiCrazy Be water my friend!

    Member
    2,391
    1
    May 8, 2008
    Istanbul
    Bump!
    Anyone recovered from this brick?
    No need for me to continue working on this if there are enough people that recovered...
     
  12. AdamBrunt

    AdamBrunt GBAtemp Advanced Fan

    Member
    699
    6
    Jun 24, 2003
    I'm still waiting for the ebay seller to send me the flipping triwing screwdriver !!! The temptation to smash my friend's GC controller is growing stronger by the day !!!
     
  13. Brian117

    Brian117 GBAtemp Psycho!

    Member
    3,250
    712
    Oct 1, 2007
    United States
    Cleveland, OH
    Why their GC controller? o.o
     
  14. EmperorOfCanada

    EmperorOfCanada GBAtemp Maniac

    Member
    1,479
    96
    Aug 4, 2008
    Canada
    Canada
    They want to modify it to be able to press all 4 directions at once.
     
  15. Quincy

    Quincy Your own personal guitarist :3

    Member
    1,436
    66
    Nov 13, 2008
    Netherlands
    Your house, robbing your stuff
    I didnt recover(yet)

    I do not have a modded wii(yet,the stupid motherf** moddedmoddeR lawl*** cancled on me then called me to make a new appointment for tomorrow [​IMG] )
     
  16. djdynamite123

    djdynamite123 Master Of Hardcore!

    Banned
    3,791
    1
    Sep 21, 2008
    Redcar, England UK
    Hope he cancels again tomorrow Quincy, butterflies starting to rumble wild in your buggy rubbish skip [​IMG]
     
  17. Quincy

    Quincy Your own personal guitarist :3

    Member
    1,436
    66
    Nov 13, 2008
    Netherlands
    Your house, robbing your stuff
    whas this meant to be a joke...since i am seriously offended!
     
  18. djdynamite123

    djdynamite123 Master Of Hardcore!

    Banned
    3,791
    1
    Sep 21, 2008
    Redcar, England UK
    Lol, sorry Quincy hehe, yeah you know it was a joke [​IMG] Modchip here you come [​IMG]
     
  19. Quincy

    Quincy Your own personal guitarist :3

    Member
    1,436
    66
    Nov 13, 2008
    Netherlands
    Your house, robbing your stuff
    lets hope so (i want to make a racist comment but instead,ill do it in my head lawl
     
  20. djdynamite123

    djdynamite123 Master Of Hardcore!

    Banned
    3,791
    1
    Sep 21, 2008
    Redcar, England UK
    Charming......hehe you know i was messing lol, i like the dutch hell most of the hardcore/gabba inventors came from there! (if you know what style I'm talking about) [​IMG]