From: Erik M. <J.A...@it...> - 2002-04-25 22:38:08
|
On Thu, Apr 25, 2002 at 12:33:34PM +0200, Abraham vd Merwe wrote: > I'm beating my head against a stone here :P > > If I set the irq exception handler to any address in a > INIT_LEVEL_DRIVER_SELECTION hook and I check that address later on in a > INIT_LEVEL_OTHER_STUFF hook, the address differs, e.g. with > > static void frodo_set_irq() > { > u32 *irq_vector = (u32 *) 0x00000018; > *irq_vector = 0xdeadbeaf; You're trying to write to flash... > } > __initlist(frodo_set_irq,INIT_LEVEL_DRIVER_SELECTION); > > static void frodo_debug_irq() > { > u32 *irq_vector = (u32 *) 0x00000018; > printf ("*irq_vector == 0x%.8x\n",*irq_vector); > } > __initlist(frodo_debug_irq,INIT_LEVEL_OTHER_STUFF); > > I get *irq_vector == 0xea0000c1 when booting blob. > > I can't see anything in the second stage boot loader that modifies this > address, so what is happening here? Writing to flash doesn't work. Do it like I suggested before: "irq" in start-sa11x0.S has to become an indirect branch to an entry point in trampoline.S. The entry point in trampoline.S on its turn can push some registers on the stack and branch&link into the C irq handler. Erik -- J.A.K. (Erik) Mouw, Information and Communication Theory Group, Faculty of Information Technology and Systems, Delft University of Technology, PO BOX 5031, 2600 GA Delft, The Netherlands Phone: +31-15-2783635 Fax: +31-15-2781843 Email: J.A...@it... WWW: http://www-ict.its.tudelft.nl/~erik/ |