⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 vectors.s

📁 motorola 针对coldfire 5275 评估板的Dbug bootloader源程序
💻 S
字号:
    #
    # File:     vectors.s
    #
    # Purpose:  Exception vectors for MPC6XX dBUG.
    #
    #
    #
    # Modificiations:
    #
    #

    # Globally accessible symbols
    .global VECTOR_TABLE

    .extern asm_startmeup
    .extern asm_exception_body
    .extern asm_isr_handler
    .extern dbug_sc_handler

######################################################################

    .text

# This is the vector table for the MPC6XX.  It is placed here so that it
# can be in a FLASH/ROM at bootup to initialize the system.  All of the
# exceptions use a generic "exception header" before branching to the
# actual handler.
#
# This file MUST be the first file linked in order for this code to be
# ROM-able.
#
    .macro  vector NUM,HANDLER
exception_\NUM:
    mtspr   272,31
    mfspr   31,8
    mtspr   273,31
    bl      next\NUM
next\NUM:
    mfspr   31,8
    rlwinm  31,31,0,0,23
    lwz     31,vect\NUM-exception_\NUM(r31)
    mtspr   8,31
    bclrl   20,0
vect\NUM:
    .long   \HANDLER
    .space  256-(10*4),0
            .endm


VECTOR_TABLE:

vector  0000,asm_exception_body     # reserved
vector  0100,asm_startmeup          # hard reset
vector  0200,asm_exception_body     # machine check
vector  0300,asm_exception_body     # data access
vector  0400,asm_exception_body     # instruction access
vector  0500,asm_isr_handler        # external interrupt
vector  0600,asm_exception_body     # alignment
vector  0700,asm_exception_body     # program
vector  0800,asm_exception_body     # floating-point unavail
vector  0900,asm_isr_handler        # decrementer
vector  0A00,asm_exception_body     # reserved
vector  0B00,asm_exception_body     # reserved
vector  0C00,dbug_sc_handler        # system call
vector  0D00,asm_exception_body     # trace
vector  0E00,asm_exception_body     # reserved
vector  0F00,asm_exception_body     # performance monitor
vector  1000,asm_exception_body     # instruction tlb miss
vector  1100,asm_exception_body     # data tlb miss
vector  1200,asm_exception_body     # data store tlb miss
vector  1300,asm_exception_body     # instruction breakpoint
vector  1400,asm_exception_body     # system management interrupt
vector  1500,asm_exception_body     # reserved
vector  1600,asm_exception_body     # reserved
vector  1700,asm_exception_body     # reserved
vector  1800,asm_exception_body     # reserved
vector  1900,asm_exception_body     # reserved
vector  1A00,asm_exception_body     # reserved
vector  1B00,asm_exception_body     # reserved
vector  1C00,asm_exception_body     # reserved
vector  1D00,asm_exception_body     # reserved
vector  1E00,asm_exception_body     # reserved
vector  1F00,asm_exception_body     # reserved

######################################################################

    .end

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -