/*
    TMHalAsmExc.S, Copyright (c) by Silvio Dragone & David Reist,
    Swiss Federal Institute of Technology,
    Computer Engineering and Networks Laboratory.

    TOPSY -- A Teachable Operating System.
             Implementation of a tiny and simple
             micro kernel for teaching purposes.

    For further information, please visit http://www.tik.ee.ethz.ch/~topsy

    This software is provided under the terms of the GNU General Public Licence.

    A full copy of the GNU GPL is provided in the file COPYING found in the 
    development root of Topsy.
*/

#include "asm.h"
#include "cpu.h"

/****************************************************************************
 *                          -> EXCSEG <-                                    *
 *                                                                          *
 * The ExceptionVectorTable will be copied to address 0x0 (phys: 0x10000000)*
 * Since there is only for ONE instruction space in the table, we have to   *
 * fill it up with relativ load. The loaded value (jump address) is added   *
 * at the end of this code. So you have to take care, that also the address *
 * table is going to be copied!                                             *
 ****************************************************************************/

.text
	
ENTRY(ExceptionVectorTable)
	ldr	pc, =__start	// Reset
	ldr	pc, =UndefinedInstructionExceptionHandler
	ldr	pc, =SoftwareIntrruptExceptionHandler
	ldr	pc, =PrefetchAbortExceptionHandler
	ldr	pc, =DataAbortExceptionHandler
	nop			// Not used
	ldr	pc, =IRQExceptionHandler
	ldr	pc, =FIQExceptionHandler
	
LABEL(ExceptionAddressTable)
	nop	
