reticulatedpines / magiclantern_simplified

A Git based version of Magic Lantern, for those unwilling or unable to work using Mercurial. The vast majority of branches have been removed, with those thought to be important brought in individually and merged.
GNU General Public License v2.0
142 stars 47 forks source link

Probable D8 init bug, reboot.c #147

Open reticulatedpines opened 1 month ago

reticulatedpines commented 1 month ago

These two lines in reboot.c got swapped at some point:

        MEM(0xBFE01FC4) = 0x10;         // unknown meaning
        MEM(0xBFE01FC8) = ROMBASEADDR;  // pointer used by 2nd core to run 2nd stage loader

From static analysis on R rom, this is probably the wrong order. Since cpu1 is waiting on the write to fc4 to wake up, could this mean it jumps to the wrong address and becomes sad? Notably, 850D doesn't this differently, and it's the most stable D8 cam we have, so this is a vaguely plausible cause of the problems on D8.

kitor commented 1 month ago

I introduced that with Digic X support (old code was the "correct" order) so I don't think it causes any extra instabilites. But definitely requires verification