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

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

?? bootinit.c

?? 菲利普22系列 vxworks bsp 可以用來可以和其他版本的ARM vxworks bsp(特別是7內核的進行比較)進行比較可以加深對BSP的理解和掌握
?? C
字號:
/* bootInit.c - ROM initialization module */

/* Copyright 1989-2002 Wind River Systems, Inc. */
#include "copyright_wrs.h"
#include "lpc2210.h"

/*
DESCRIPTION
This module provides a generic boot ROM facility.  The target-specific
romInit.s module performs the minimal preliminary board initialization and
then jumps to the C routine romStart().  This routine, still executing out
of ROM, copies the first stage of the startup code to a RAM address and
jumps to it.  The next stage clears memory and then uncompresses the
remainder of ROM into the final VxWorks ROM image in RAM.

A modified version of the Public Domain \f3zlib\fP library is used to
uncompress the VxWorks boot ROM executable linked with it.  Compressing
object code typically achieves over 55% compression, permitting much
larger systems to be burned into ROM.  The only expense is the added few
seconds delay while the first two stages complete.

ROM AND RAM MEMORY LAYOUT
Example memory layout for a 1-megabyte board:
.CS
    --------------  0x00100000 = LOCAL_MEM_SIZE = sysMemTop()
    |            |
    |    RAM     |
    |  0 filled  |
    |            |
    |------------| = (romInit+ROM_COPY_SIZE) or binArrayStart
    | ROM image  |
    |----------- |  0x00090000  = RAM_HIGH_ADRS
    | STACK_SAVE |
    |------------|
    |            |  0x00080000  = 0.5 Megabytes
    |            |
    |            |
    | 0 filled   |
    |            |
    |            |  0x00001000  = RAM_ADRS & RAM_LOW_ADRS
    |            |
    |            |  exc vectors, bp anchor, exc msg, bootline
    |            |
    |            |
    --------------  0x00000000  = LOCAL_MEM_LOCAL_ADRS
.CE
.CS
    --------------
    |    ROM     |
    |            |  0xff8xxxxx  = binArrayStart
    |            |
    |            |  0xff800008  = ROM_TEXT_ADRS
    --------------  0xff800000  = ROM_BASE_ADRS
.CE

SEE ALSO:
inflate(), romInit(), and deflate

AUTHOR
The original compression software for zlib was written by Jean-loup Gailly
and Mark Adler. See the manual pages of inflate and deflate for
more information on their freely available compression software.
*/

#include "vxWorks.h"
#include "sysLib.h"
#include "config.h"
#include "errno.h"
#include "sioLib.h"

#define	UNCMP_RTN	inflate

#ifndef USER_RESERVED_MEM
#define USER_RESERVED_MEM 0
#endif

/*
 * If memory is to be cleared, it will be cleared from SYS_MEM_BOTTOM
 * up to (but not including) SYS_MEM_TOP, except for text and data segments.
 * The user reserved area is not cleared.
 */

#define	SYS_MEM_TOP \
	(LOCAL_MEM_LOCAL_ADRS + LOCAL_MEM_SIZE - USER_RESERVED_MEM)

#define SYS_MEM_BOTTOM \
	(LOCAL_MEM_LOCAL_ADRS + RESERVED)

#define BINARRAYEND_ROUNDOFF	(ROUND_DOWN(binArrayEnd, sizeof(long))) 

IMPORT void	romInit ();
IMPORT STATUS	UNCMP_RTN ();
IMPORT void	usrInit ();
IMPORT void	sysInitAlt ();
IMPORT void	start ();

IMPORT UCHAR	binArrayStart [];	/* compressed binary image */
IMPORT UCHAR	binArrayEnd [];		/* end of compressed binary image */
IMPORT char	etext [];		/* defined by the loader */
IMPORT char	end [];			/* defined by the loader */
IMPORT UCHAR	wrs_kernel_data_start [];  /* defined by the loader */
IMPORT UCHAR	wrs_kernel_data_end [];    /* defined by the loader */

#define	RESIDENT_DATA 	wrs_kernel_data_start	

#ifndef RAM_DST_ADRS                	/* default uncompress dest. */
#define RAM_DST_ADRS        RAM_HIGH_ADRS
#endif

/* #if	defined (UNCOMPRESS) || defined (ROM_RESIDENT) */
#ifndef ROM_COPY_SIZE
#define	ROM_COPY_SIZE	(ROM_SIZE - (ROM_TEXT_ADRS - ROM_BASE_ADRS))
#endif
/* #endif*/	/* UNCOMPRESS */

#define ROM_OFFSET(adr)	(((UINT)adr - (UINT)romInit) + ROM_TEXT_ADRS)

/* forward declarations */

LOCAL void copyLongs (FAST UINT *source, FAST UINT *destination, UINT nlongs);
LOCAL void fillLongs (FAST UINT *buf, UINT nlongs, FAST UINT val);

void lpc2210Init(void)
{
/* 設置系統各部分時鐘 */
/* Set system timers for each component */
    PLLCON = 1;
#if (Fpclk / (Fcclk / 4)) == 1
    VPBDIV = 0;
#endif
#if (Fpclk / (Fcclk / 4)) == 2
    VPBDIV = 2;
#endif
#if (Fpclk / (Fcclk / 4)) == 4
    VPBDIV = 1;
#endif

#if (Fcco / Fcclk) == 2
    PLLCFG = ((Fcclk / Fosc) - 1) | (0 << 5);
#endif
#if (Fcco / Fcclk) == 4
    PLLCFG = ((Fcclk / Fosc) - 1) | (1 << 5);
#endif
#if (Fcco / Fcclk) == 8
    PLLCFG = ((Fcclk / Fosc) - 1) | (2 << 5);
#endif
#if (Fcco / Fcclk) == 16
    PLLCFG = ((Fcclk / Fosc) - 1) | (3 << 5);
#endif
    PLLFEED = 0xaa;
    PLLFEED = 0x55;
    while((PLLSTAT & (1 << 10)) == 0);
    PLLCON = 3;
    PLLFEED = 0xaa;
    PLLFEED = 0x55;
    
    /* 設置存儲器加速模塊 */
    /* Set memory accelerater module*/
    MAMCR = 0;
#if Fcclk < 20000000
    MAMTIM = 1;
#else
#if Fcclk < 40000000
    MAMTIM = 2;
#else
    MAMTIM = 3;
#endif
#endif
    MAMCR = 2;
}

/*******************************************************************************
*
* romStart - generic ROM initialization
*
* This is the first C code executed after reset.
*
* This routine is called by the assembly start-up code in romInit().
* It clears memory, copies ROM to RAM, and possibly invokes the uncompressor.
* It then jumps to the entry point of the uncompressed object code.
*
* RETURNS: N/A
*/

void romStart
    (
    FAST int startType		/* start type */
    )
{
    volatile FUNCPTR absEntry;		/* to avoid PC Relative Jump Subroutine */

     /* The link.ROM is not correct, so currently there is no need to copy data segment to 
     0x80204000. They have already been there! */
#if 0
    copyLongs ((UINT *)etext, (UINT *) RESIDENT_DATA,
        ((UINT) wrs_kernel_data_end - (UINT) RESIDENT_DATA) / sizeof (long));
#endif
    /* clear all memory if cold booting */

    lpc2210Init();

    if (startType & BOOT_CLEAR)
    {
	/* Clear memory not loaded with text & data.
	 *
	 * We are careful about initializing all memory (except
	 * STACK_SAVE bytes) due to parity error generation (on
	 * some hardware) at a later stage.  This is usually
	 * caused by read accesses without initialization.
	 */
	fillLongs ((UINT *)SYS_MEM_BOTTOM,
		((UINT) RESIDENT_DATA - STACK_SAVE - (UINT)SYS_MEM_BOTTOM)
		/ sizeof(long), 0);
	fillLongs (((UINT *) wrs_kernel_data_end),
	((UINT)SYS_MEM_TOP - ((UINT) wrs_kernel_data_end)) / sizeof(long), 0);

	/* 
	 * Ensure the boot line is null. This is necessary for those
	 * targets whose boot line is excluded from cleaning.
	 */
	*(BOOT_LINE_ADRS) = EOS;
    }

    /* jump to VxWorks entry point (after uncompressing) */

    absEntry = (FUNCPTR)usrInit;			/* on to bootConfig */

    (absEntry) (startType);
}

/*******************************************************************************
*
* copyLongs - copy one buffer to another a long at a time
*
* This routine copies the first <nlongs> longs from <source> to <destination>.
*/

LOCAL void copyLongs (source, destination, nlongs)
    FAST UINT *source;		/* pointer to source buffer      */
    FAST UINT *destination;	/* pointer to destination buffer */
    UINT nlongs;		/* number of longs to copy       */
{
    FAST UINT *dstend = destination + nlongs;
    FAST UINT nchunks;

    /* Hop by chunks of longs, for speed. */
    for (nchunks = nlongs / 8; nchunks; --nchunks)
    {
	destination[0] = source[0];
	destination[1] = source[1];
	destination[2] = source[2];
	destination[3] = source[3];
	destination[4] = source[4];
	destination[5] = source[5];
	destination[6] = source[6];
	destination[7] = source[7];
	destination += 8, source += 8;
    }

    /* Do the remainder one long at a time. */
    while (destination < dstend)
	*destination++ = *source++;
}

/*******************************************************************************
*
* fillLongs - fill a buffer with a value a long at a time
*
* This routine fills the first <nlongs> longs of the buffer with <val>.
*/

LOCAL void fillLongs (buf, nlongs, val)
    FAST UINT *buf;	/* pointer to buffer              */
    UINT nlongs;	/* number of longs to fill        */
    FAST UINT val;	/* char with which to fill buffer */
{
    FAST UINT *bufend = buf + nlongs;
    FAST UINT nchunks;

    /* Hop by chunks of longs, for speed. */
    for (nchunks = nlongs / 8; nchunks; --nchunks)
    {
        buf[0] = val;
        buf[1] = val;
        buf[2] = val;
        buf[3] = val;
        buf[4] = val;
        buf[5] = val;
        buf[6] = val;
        buf[7] = val;
        buf += 8;
    }

    /* Do the remainder one long at a time. */
    while (buf < bufend)
	*buf++ = val;
}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲三级电影网站| 69堂精品视频| 国产精品一级片在线观看| 日韩中文字幕不卡| 亚洲综合另类小说| 天天操天天干天天综合网| 亚洲日本一区二区三区| 亚洲欧洲性图库| 亚洲午夜av在线| 激情欧美一区二区三区在线观看| 蜜乳av一区二区| 成人黄色网址在线观看| 欧美三区在线观看| 91麻豆精品91久久久久久清纯| 日韩一区二区免费在线观看| 久久久精品2019中文字幕之3| 欧美国产一区在线| 日韩中文字幕一区二区三区| 美国一区二区三区在线播放| 懂色av一区二区三区免费观看| www.欧美日韩国产在线| 91免费版pro下载短视频| 欧美日韩色一区| 亚洲精品免费在线观看| 日本不卡123| 88在线观看91蜜桃国自产| 欧美一级艳片视频免费观看| 久久精品无码一区二区三区| 中文字幕亚洲一区二区av在线| 综合色中文字幕| 成人午夜在线视频| 67194成人在线观看| 综合久久久久久久| 福利视频网站一区二区三区| 欧美一区二区在线免费播放| 国产精品欧美一区二区三区| 日欧美一区二区| 欧美日韩成人综合| 一区二区三区四区不卡视频| 成人国产精品免费网站| 久久久久久久久久久99999| 日韩电影在线免费看| 欧美色视频在线| 亚洲国产精品一区二区久久恐怖片 | 91高清视频免费看| 亚洲视频一区在线| 日本韩国视频一区二区| 国产精品不卡一区二区三区| 97精品久久久久中文字幕| 欧美极品少妇xxxxⅹ高跟鞋| 国产大片一区二区| ...av二区三区久久精品| 91亚洲精品久久久蜜桃网站| 亚洲欧洲中文日韩久久av乱码| 91精选在线观看| 精品一区免费av| 日韩精品中文字幕在线不卡尤物| 国产高清在线观看免费不卡| 亚洲视频1区2区| 欧美一级专区免费大片| 国产一区二区久久| 中文字幕av一区 二区| 欧美巨大另类极品videosbest| 国产aⅴ精品一区二区三区色成熟| 亚洲欧美日韩一区二区| 日韩欧美在线综合网| 国产999精品久久久久久绿帽| 一区二区三区四区激情| 国产欧美一区二区三区在线看蜜臀 | 日日摸夜夜添夜夜添精品视频| 欧美丰满高潮xxxx喷水动漫| av午夜一区麻豆| 国产精品77777| 性做久久久久久免费观看| 亚洲人成小说网站色在线| 精品国产123| 日韩亚洲电影在线| 欧美日本在线看| 色播五月激情综合网| 懂色av一区二区三区免费看| 激情综合一区二区三区| 美女www一区二区| 麻豆91在线播放免费| 亚洲图片激情小说| 亚洲一区电影777| 亚洲一区二区欧美激情| 亚洲美女在线国产| 亚洲黄色小视频| 怡红院av一区二区三区| 国产精品乱人伦| 亚洲人快播电影网| 一区二区三区欧美| 最新国产の精品合集bt伙计| 亚洲同性同志一二三专区| 亚洲免费观看高清在线观看| 亚洲色图自拍偷拍美腿丝袜制服诱惑麻豆 | 欧美性受xxxx黑人xyx性爽| 在线亚洲高清视频| 日韩午夜小视频| 国产精品美女视频| 亚洲精品久久7777| 麻豆中文一区二区| 国产成人亚洲综合a∨猫咪| 国产成人激情av| 在线一区二区三区四区五区| 91精品国产色综合久久不卡蜜臀| 久久久精品tv| 午夜精品成人在线视频| 久久99精品国产麻豆不卡| 99精品一区二区三区| 日韩美一区二区三区| 亚洲欧美日韩国产成人精品影院| 日本不卡123| 成人免费观看视频| 国产亚洲精品中文字幕| 一区二区三区日韩| 色综合天天综合网天天狠天天| 日韩欧美专区在线| 欧美经典一区二区三区| 色婷婷精品大在线视频| 久久久久国产精品厨房| 亚洲成人免费在线观看| 在线免费一区三区| 亚洲少妇30p| 色网综合在线观看| 中文字幕不卡在线播放| 麻豆成人免费电影| 久久久久久久av麻豆果冻| 无吗不卡中文字幕| 欧美日韩激情在线| 久久精品国产色蜜蜜麻豆| 欧美日韩国产一区| 日本欧美在线观看| 欧美精品一区男女天堂| 久久精品国产久精国产爱| 日韩欧美二区三区| 国产91高潮流白浆在线麻豆| 日韩午夜在线播放| 不卡一区二区在线| 夜夜精品视频一区二区| hitomi一区二区三区精品| 亚洲黄色小说网站| 欧美一级国产精品| 99在线热播精品免费| 亚洲电影一区二区三区| 日韩欧美一卡二卡| 91在线一区二区三区| 日本伊人色综合网| 国产欧美日韩三级| 91精品国产综合久久福利软件| 国产真实乱偷精品视频免| 欧美韩国日本一区| 91精品麻豆日日躁夜夜躁| 成人免费毛片a| 亚洲国产综合色| 国产精品久久久久久亚洲毛片| 欧美日韩在线三级| 国产91丝袜在线播放0| 五月综合激情网| 亚洲美女电影在线| 国产精品卡一卡二卡三| 精品久久久网站| 欧美色男人天堂| 91精彩视频在线| 91色视频在线| 99麻豆久久久国产精品免费 | 久久久久99精品国产片| 日韩欧美一区二区视频| 欧美性猛片xxxx免费看久爱| 91理论电影在线观看| 不卡欧美aaaaa| 国产成人综合亚洲网站| 国产精品一区在线| 蜜桃传媒麻豆第一区在线观看| 成人免费在线观看入口| 国产精品不卡在线观看| 一区二区国产视频| 亚洲日本欧美天堂| 丝袜亚洲精品中文字幕一区| 亚洲超碰97人人做人人爱| 亚洲成人av电影在线| 日韩精品免费视频人成| 精品亚洲aⅴ乱码一区二区三区| 香蕉av福利精品导航| 精品综合久久久久久8888| 国产成人免费在线视频| 高清在线不卡av| 欧美在线免费播放| 久久久久国产精品麻豆| 国产精品理论在线观看| 亚洲一二三四区| 激情图区综合网| 99视频热这里只有精品免费| 日韩一级视频免费观看在线| 国产欧美精品国产国产专区| 亚洲欧美在线观看| 国产一区二区三区美女| 一本色道亚洲精品aⅴ| 精品久久久久久亚洲综合网 | heyzo一本久久综合|