亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? vectors.s

?? 基于ARM S3C44B0X的ECOS 硬件移植代碼
?? S
?? 第 1 頁 / 共 3 頁
字號:
// #========================================================================
// #
// #    vectors.S
// #
// #    ARM exception vectors
// #
// #========================================================================
//####ECOSGPLCOPYRIGHTBEGIN####
// -------------------------------------------
// This file is part of eCos, the Embedded Configurable Operating System.
// Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc.
//
// eCos is free software; you can redistribute it and/or modify it under
// the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2 or (at your option) any later version.
//
// eCos is distributed in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or
// FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
// for more details.
//
// You should have received a copy of the GNU General Public License along
// with eCos; if not, write to the Free Software Foundation, Inc.,
// 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
//
// As a special exception, if other files instantiate templates or use macros
// or inline functions from this file, or you compile this file and link it
// with other works to produce a work based on this file, this file does not
// by itself cause the resulting work to be covered by the GNU General Public
// License. However the source code for this file must still be made available
// in accordance with section (3) of the GNU General Public License.
//
// This exception does not invalidate any other reasons why a work based on
// this file might be covered by the GNU General Public License.
//
// Alternative licenses for eCos may be arranged by contacting Red Hat, Inc.
// at http://sources.redhat.com/ecos/ecos-license/
// -------------------------------------------
//####ECOSGPLCOPYRIGHTEND####
// #========================================================================
// ######DESCRIPTIONBEGIN####
// #
// # Author(s):     nickg, gthomas
// # Contributors:  nickg, gthomas
// # Date:          1999-02-20
// # Purpose:       ARM exception vectors
// # Description:   This file defines the code placed into the exception
// #                vectors. It also contains the first level default VSRs
// #                that save and restore state for both exceptions and
// #                interrupts.
// #
// #####DESCRIPTIONEND####
// #
// #========================================================================

#include <pkgconf/hal.h>
#include <pkgconf/hal_arm.h>
#ifdef CYGPKG_KERNEL  // no CDL yet
#include <pkgconf/kernel.h>
#else
# undef CYGFUN_HAL_COMMON_KERNEL_SUPPORT
# undef CYGIMP_HAL_COMMON_INTERRUPTS_USE_INTERRUPT_STACK
#endif
#include <cyg/hal/hal_platform_setup.h>

#ifdef CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS
// The CDL should enforce this
#undef  CYGHWR_HAL_ARM_DUMP_EXCEPTIONS
#endif

#include "arm.inc"

#ifdef __thumb__
// Switch to thumb mode
#define THUMB_MODE(_r_, _l_)                     \
        ldr     _r_,=_l_ ## f+1                 ;\
        bx      _r_                             ;\
        .pool                                   ;\
        .code   16                              ;\
        .thumb_func                             ;\
 _l_:

// Switch to ARM mode
#define ARM_MODE(_r_, _l_)                       \
        ldr     _r_,=_l_ ## f                   ;\
        bx      _r_                             ;\
        .pool                                   ;\
        .code   32                              ;\
 _l_:

// Function definition, start executing body in ARM mode
#define FUNC_START_ARM(_name_, _r_)              \
        .code   16                              ;\
        .thumb_func                             ;\
        .globl _name_                           ;\
_name_:                                         ;\
        ldr     _r_,=_name_ ## _ARM             ;\
        bx      _r_                             ;\
        .code   32                              ;\
_name_ ## _ARM:

#else

// Switch to thumb mode
#define THUMB_MODE(_r_, _l_)

// Switch to ARM mode
#define ARM_MODE(_r_, _l_)

// Function definition, start executing body in ARM mode
#define FUNC_START_ARM(_name_, _r_) \
        .globl _name_; \
_name_: 

#endif

        

#define PTR(name)               \
.##name: .word  name

// CYGHWR_HAL_ROM_VADDR is used when compiling for a different location
// from the base of ROM.  hal_platform_setup.h might define it.  For
// example, if flash is from 0x50000000 upwards (as on SA11x0), and we are
// to execute at 0x50040000, then we want the reset vector to point to
// 0x0004pqrs - the unmapped ROM address of the code - rather than
// 0x0000pqrs, which is the offset into our flash block.
// 
// But usually it's not defined, so the behaviour is the obvious.

#ifndef UNMAPPED        
#ifdef CYGHWR_HAL_ARM_HAS_MMU
# ifndef CYGHWR_HAL_ROM_VADDR
#  define CYGHWR_HAL_ROM_VADDR __exception_handlers
# endif
# define UNMAPPED(x) ((x)-CYGHWR_HAL_ROM_VADDR)
#else
# define UNMAPPED(x) (x)
#endif
#endif        
                                
#define UNMAPPED_PTR(name)              \
.##name: .word  UNMAPPED(name)

//        .file   "vectors.S"


// CYGHWR_LED_MACRO can be defined in hal_platform_setup.h. It's free to
// use r0+r1. Argument is in "\x" - cannot use macro arguments since the
// macro may contain #-chars and use of arguments cause these to be 
// interpreted as CPP stringify operators.
// See example in PID hal_platform_setup.h.
#ifndef CYGHWR_LED_MACRO
#define CYGHWR_LED_MACRO
#endif
        
.macro LED x
    CYGHWR_LED_MACRO
.endm


//==========================================================================
// Hardware exception vectors.
//   This entire section will be copied to location 0x0000 at startup time.
//
        .code   32
        .section ".vectors","ax"

// This macro allows platforms to add their own code at the very start of
// the image.  This may be required in some circumstances where eCos ROM 
// based code does not run immediately upon reset and/or when some sort of
// special header is required at the start of the image.        
#ifdef PLATFORM_PREAMBLE
        PLATFORM_PREAMBLE
#endif
                        
        .global __exception_handlers
__exception_handlers:
#ifdef CYGSEM_HAL_ROM_RESET_USES_JUMP
// Assumption:  ROM code has these vectors at the hardware reset address.
// A simple jump removes any address-space dependencies [i.e. safer]
        b       reset_vector                    // 0x00
#else        
        ldr     pc,.reset_vector                // 0x00
#endif        
        ldr     pc,.undefined_instruction       // 0x04
        ldr     pc,.software_interrupt          // 0x08 start && software int
        ldr     pc,.abort_prefetch              // 0x0C
        ldr     pc,.abort_data                  // 0x10
        .word   0                               // unused
#ifdef CYG_HAL_STARTUP_RAM
        ldr     pc,.IRQ                         // 0x18			// ??? ram appication use
        ldr     pc,.FIQ                         // 0x1C
#else
        ldr     pc,=0x0c100018                  // 0x18			// ??? rom redboot use
        ldr     pc,=0x0c10001c                  // 0x1C
#endif        

// The layout of these pointers should match the vector table above since
// they are copied in pairs.
        .global vectors
vectors:
	UNMAPPED_PTR(reset_vector)              // 0x20
	PTR(undefined_instruction)              // 0x24
	PTR(software_interrupt)                 // 0x28
	PTR(abort_prefetch)                     // 0x2C
	PTR(abort_data)                         // 0x30
        .word   0                               // 0x34

#ifdef CYG_HAL_STARTUP_RAM						// ???
	PTR(IRQ)                                // 0x38
	PTR(FIQ)                                // 0x3c
#else
	.word 0x0c100038
	.word 0x0c10003c
#endif        

#ifdef CYGSEM_HAL_ARM_PID_ANGEL_BOOT         
PTR(start) // This is copied to 0x28 for bootup // 0x40
#endif        
           // location 0x40 is used for storing DRAM size if known
           // for some platforms.
        
//
// "Vectors" - fixed location data items
//    This section contains any data which might be shared between
// an eCos application and any other environment, e.g. the debug
// ROM.                        
//
        .section ".fixed_vectors"
        // Interrupt/exception VSR pointers
        .globl  hal_vsr_table
hal_vsr_table:
        .rept   8               
        .long   0
        .endr

        .globl  hal_dram_size
hal_dram_size:  
        .long   0
	// what, if anything, hal_dram_type means is up to the platform
        .globl  hal_dram_type
hal_dram_type:  
        .long   0

        .balign 16
#ifdef CYGSEM_HAL_VIRTUAL_VECTOR_SUPPORT
	// Vectors used to communicate between eCos and ROM environments
        .globl  hal_virtual_vector_table
hal_virtual_vector_table:
        .rept   CYGNUM_CALL_IF_TABLE_SIZE
        .long   0
        .endr
#endif
        
#ifdef CYGHWR_HAL_ARM_ICE_THREAD_SUPPORT
        .balign 16      // Should be at 0x50
ice_thread_vector:
        .long   0       // Must be 'MICE'             
        .long   0       // Pointer to thread support vector
        .long   0       // eCos executing flag
        .long   0       // Must be 'GDB '
#endif // CYGHWR_HAL_ARM_ICE_THREAD_SUPPORT
        .balign 32
        
// Other vectors - this may include "fixed" locations
#ifdef PLATFORM_VECTORS
        PLATFORM_VECTORS
#endif
                        
        .text   
// Startup code which will get the machine into supervisor mode
        .global reset_vector
        .type   reset_vector,function
reset_vector:
        PLATFORM_SETUP1         // Early stage platform initialization
                                // which can set DRAM size at 0x40
                                // see <cyg/hal/hal_platform_setup.h>

        // Come here to reset board
warm_reset:                 

#if defined(CYG_HAL_STARTUP_RAM) && \
    !defined(CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS)
        mrs     r7,cpsr                 // move back to IRQ mode
        and     r7,r7,#CPSR_MODE_BITS
        cmp     r7,#CPSR_SUPERVISOR_MODE
        beq     start
#endif

        // We cannot access any LED registers until after PLATFORM_SETUP1
        LED 7

        mov     r0,#0           // move vectors
        ldr     r1,=__exception_handlers
#ifndef CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS
        // Wait with this if stubs are included (see further down).
        ldr     r2,[r1,#0x04]   // undefined instruction
        str     r2,[r0,#0x04]
        ldr     r2,[r1,#0x24]   
        str     r2,[r0,#0x24]
#endif
        ldr     r2,[r1,#0x08]   // software interrupt
        str     r2,[r0,#0x08]

#ifdef CYGHWR_HAL_ARM_ICE_THREAD_SUPPORT        
        ldr     r2,=ice_thread_vector
        sub     r2,r2,r1        // compute fixed (low memory) address
        ldr     r3,=0x4D494345  // 'MICE'
        str     r3,[r2],#4
        ldr     r3,=hal_arm_ice_thread_handler
        str     r3,[r2],#4
        mov     r3,#1
        str     r3,[r2],#4
        ldr     r3,=0x47444220  // 'GDB '
        str     r3,[r2],#4
#endif // CYGHWR_HAL_ARM_ICE_THREAD_SUPPORT

#if defined(CYGSEM_HAL_ARM_PID_ANGEL_BOOT)
// Ugly hack to get into supervisor mode
        ldr     r2,[r1,#0x40]
        str     r2,[r0,#0x28]

        LED 6
                
        swi                     // switch to supervisor mode
#endif        

// =========================================================================
// Real startup code. We jump here from the reset vector to set up the world.
        .globl  start
start:  

        LED 5

#if defined(CYG_HAL_STARTUP_RAM) && \
    !defined(CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS)
// If we get restarted, hang here to avoid corrupting memory
        ldr     r0,.init_flag
        ldr     r1,[r0]
1:      cmp     r1,#0
        bne     1b
        ldr     r1,init_done
        str     r1,[r0]
#endif

        // Reset software interrupt pointer
        mov     r0,#0           // move vectors
        ldr     r1,.__exception_handlers
#if defined(CYG_HAL_STARTUP_RAM) && \
    !defined(CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS)
        cmp     r7,#CPSR_SUPERVISOR_MODE
        beq     10f
#endif
        ldr     r2,[r1,#0x28]   // software interrupt
        str     r2,[r0,#0x28]
10:
        ldr     r2,[r1,#0x18]   // IRQ
        str     r2,[r0,#0x18]
        ldr     r2,[r1,#0x38]
        str     r2,[r0,#0x38]
        ldr     r2,[r1,#0x1C]   // FIQ
        str     r2,[r0,#0x1C]
        ldr     r2,[r1,#0x3C]
        str     r2,[r0,#0x3C]
        ldr     r2,[r1,#0x0C]   // abort (prefetch)
        str     r2,[r0,#0x0C]
        ldr     r2,[r1,#0x2C]   
        str     r2,[r0,#0x2C]
        ldr     r2,[r1,#0x10]   // abort (data)
        str     r2,[r0,#0x10]
        ldr     r2,[r1,#0x30]
        str     r2,[r0,#0x30]

        LED 4

#if defined(CYG_HAL_STARTUP_ROM) || defined(CYG_HAL_STARTUP_ROMRAM)
        // Set up reset vector
        mov     r0,#0

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美一级黄色大片| 国产一区不卡精品| 自拍偷拍欧美激情| 亚洲三级久久久| 国产精品网曝门| 久久麻豆一区二区| www久久精品| 久久影音资源网| 久久久精品免费免费| 国产欧美日韩一区二区三区在线观看| 久久久久久综合| 久久你懂得1024| 中文字幕av一区二区三区| 国产精品你懂的在线欣赏| 国产精品久久久久9999吃药| 亚洲精选在线视频| 亚洲综合色自拍一区| 亚洲一二三级电影| 久久99九九99精品| 成人免费黄色在线| 色吧成人激情小说| 欧美顶级少妇做爰| 精品久久人人做人人爰| 国产精品美女久久久久久久 | 久久久久久久久97黄色工厂| 国产日韩在线不卡| 亚洲精品视频一区| 日本午夜一区二区| 国产成人免费视频网站| 色诱亚洲精品久久久久久| 欧美一个色资源| 国产精品美女久久福利网站| 亚洲制服欧美中文字幕中文字幕| 日韩在线观看一区二区| 国产98色在线|日韩| 欧美性一二三区| 国产色婷婷亚洲99精品小说| 亚洲综合视频网| 国产福利91精品一区二区三区| 一本久久a久久精品亚洲| 日韩美女一区二区三区四区| 亚洲精品一二三| 国产一区二区不卡在线| 在线观看国产精品网站| 国产亚洲精品中文字幕| 五月婷婷激情综合| 97se亚洲国产综合自在线不卡| 91精品国产色综合久久| 亚洲人成网站影音先锋播放| 激情图片小说一区| 欧美日韩精品一区二区三区| 国产精品三级电影| 另类专区欧美蜜桃臀第一页| 欧美日韩视频在线一区二区 | 在线观看不卡一区| 国产日产亚洲精品系列| 人妖欧美一区二区| 欧美视频中文一区二区三区在线观看| 国产女人18毛片水真多成人如厕 | 精品国产乱码久久久久久蜜臀 | 亚洲国产精品欧美一二99| 成人av在线网| 国产色产综合产在线视频| 另类小说视频一区二区| 欧美日韩高清影院| 亚洲毛片av在线| 91论坛在线播放| 中文字幕中文字幕一区二区| 粉嫩av亚洲一区二区图片| 久久综合精品国产一区二区三区| 日韩av一区二区三区四区| 欧美色偷偷大香| 亚洲图片欧美视频| 欧美色图一区二区三区| 亚洲国产日日夜夜| 欧美日韩黄色影视| 日韩精品欧美精品| 欧美一级二级三级蜜桃| 精品无码三级在线观看视频 | 国产精品盗摄一区二区三区| 国产成人综合在线观看| 国产人成一区二区三区影院| 国产成人午夜精品影院观看视频 | 韩国成人精品a∨在线观看| 日韩精品一区二区三区四区视频 | 欧美猛男超大videosgay| 亚洲国产美女搞黄色| 在线成人午夜影院| 另类调教123区| 欧美激情在线一区二区三区| 91在线观看视频| 亚洲午夜久久久| 日韩精品一区二区三区四区视频| 国产一区二区三区免费观看| 国产免费久久精品| 欧美亚洲动漫制服丝袜| 久久精品国产精品亚洲精品| 国产午夜精品在线观看| 91福利精品视频| 免费欧美在线视频| 中文字幕一区三区| 欧美高清你懂得| 国产精品夜夜嗨| 亚洲最大成人综合| 欧美精品一区二区三区视频| 99麻豆久久久国产精品免费优播| 亚洲国产一区二区a毛片| 日韩免费观看高清完整版在线观看| 国产精品99久久久久久宅男| 亚洲一区二区三区自拍| 久久尤物电影视频在线观看| 91在线免费看| 国内外成人在线| 夜夜嗨av一区二区三区四季av| 日韩三级在线观看| 91麻豆自制传媒国产之光| 日韩在线播放一区二区| 日韩一区日韩二区| 日韩欧美aaaaaa| 欧美午夜精品久久久久久孕妇| 国产在线国偷精品产拍免费yy | 欧美aⅴ一区二区三区视频| 国产精品福利一区| 日韩欧美激情一区| 欧美性xxxxx极品少妇| 国产成人午夜精品影院观看视频 | 国产精品天干天干在观线| 欧美日韩精品综合在线| 91色在线porny| 韩日精品视频一区| 日本人妖一区二区| 亚洲国产视频在线| 亚洲精品乱码久久久久久久久 | 婷婷中文字幕综合| 一区二区三区四区av| 久久精品亚洲乱码伦伦中文| 欧美一区日韩一区| 欧美日韩一区二区电影| 91极品美女在线| 91免费视频观看| 成人av在线观| 成人av集中营| 粉嫩欧美一区二区三区高清影视| 久久99热99| 久久精品国产**网站演员| 免费人成网站在线观看欧美高清| 五月天国产精品| 五月天丁香久久| 日韩av中文字幕一区二区三区| 亚洲成人一区二区| 日韩精品视频网| 蜜桃精品视频在线| 久久国产视频网| 韩国女主播一区| 国产精品中文欧美| 国产精品 欧美精品| 丁香激情综合国产| 成年人国产精品| www.99精品| 欧美日韩综合色| 欧美男男青年gay1069videost | 精品日韩99亚洲| 久久色在线视频| 国产精品美女久久福利网站| 亚洲色图在线播放| 亚洲va欧美va国产va天堂影院| 亚洲妇熟xx妇色黄| 精彩视频一区二区三区| 国产大陆精品国产| 97久久超碰精品国产| 在线观看视频一区| 日韩美女视频一区二区在线观看| 久久久另类综合| 一区在线观看免费| 亚洲一区二区四区蜜桃| 免费人成黄页网站在线一区二区| 国产麻豆一精品一av一免费| 成人综合婷婷国产精品久久免费| 91亚洲国产成人精品一区二区三| 欧美视频中文字幕| 精品粉嫩aⅴ一区二区三区四区 | 亚洲chinese男男1069| 美国十次了思思久久精品导航| 国产成人精品免费在线| 一本大道久久a久久精二百| 91精品国产手机| 国产午夜亚洲精品理论片色戒| 亚洲免费观看高清完整版在线| 日本女优在线视频一区二区| 国产福利不卡视频| 欧美精选在线播放| 国产精品毛片高清在线完整版| 午夜激情久久久| 99久久婷婷国产综合精品| 欧美一级视频精品观看| 一区二区三区免费在线观看| 国产在线精品一区二区三区不卡 | 日本一区二区三区dvd视频在线| 亚洲高清久久久| 97久久超碰国产精品|