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

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

?? systffs.c

?? INTEL IXP425的VXWORKS BSP
?? C
?? 第 1 頁 / 共 2 頁
字號:
/* sysTffsStub.c - BSP stub for TrueFFS Socket Component Driver */

/* Copyright 1984-2000 Wind River Systems, Inc. */
#include "copyright_wrs.h"

/*
modification history
--------------------
01e,22may02,nrv  Adding INCLUDE_MTD_CFIAMD
01d,13nov01,nrv  made use of PRJ_BUILD
01c,09nov01,nrv  merging in T3 version with some cleanup
01b,14dec00,yp   Documentation cleanup
01a,29nov00,yp   derived from ads860 sysTffs.c 01j.
*/

/*
This stub file provides the user with the means to create a TrueFFS compliant 
socket component driver for use with any BSP. This is sample code and it is
expected, even required, to be modified after it is added to a BSP by the 
project facility when the component INCLUDE_TFFS is added to a kernel project.
Look for #error and TODO statements in the sample code.

This stub does not provides code, just some procedural macros that the
generic driver code will use.

DESCRIPTION
This library must provide board-specific hardware access routines for TrueFFS.
In effect, these routines comprise the socket component driver (or drivers)
for your flash device.  At socket registration time, TrueFFS stores
the functions provided by this socket component driver in an 'FLSocket'
structure.  When TrueFFS needs to access the flash device, it uses these
functions. 
 
Because this file is, for the most part, a device driver that exports its
functionality by registering function pointers with TrueFFS, very few of the
functions defined here are externally callable.  For the record, the only
external functions are flFitInSocketWindow() and flDelayLoop(), and you should
never have to call them.
 
However, one of the most important functions defined in this file is neither
referenced in an 'FLSocket' structure, nor is it externally callable.  This
function is sysTffsInit() and it should only be called by TrueFFS.  TrueFFS 
calls this function at initialization time to register socket component 
drivers for all the flash devices attached to your target.  It is this call 
to sysTffs() that results in assigning drive numbers to the flash devices on 
your target hardware.  Drive numbers are assigned by the order in which the 
socket component drivers are registered. The first to be registered is drive 
0, the second is drive 1, and so on up to 4.  As shipped, TrueFFS supports up 
to five flash drives.
 
After registering socket component drivers for a flash device, you may
format the flash medium even though there is not yet a block device driver
associated with the flash (see the reference entry for the tffsDevCreate()
routine).  To format the flash medium for use with TrueFFS,
call tffsDevFormat() or, for some BSPs, sysTffsFormat().
 
The sysTffsFormat() routine is an optional,BSP-specific helper routine that
can be called externally. Internally, sysTffsFormat() calls tffsDevFormat() 
with a pointer to a 'FormatParams' structure that is initialized to values 
that leave a space on the flash device for a boot image. This space is outside 
the region managed by TrueFFS.  This special region is necessary for boot
images because the normal translation and wear-leveling services of TrueFFS
are incompatible with the needs of the boot program and the boot image it
relies upon.  To write a boot image (or any other data) into this area,
use tffsBootImagePut(). 
 
The function sysTffsFormat() is only provided when a Flash SIMM has to have 
the TrueFFS file system in some desired fraction of it. It is provided only 
for the purpose of simplifying the process of formatting a Flash part that 
that should be subdivided.

The Flash SIMM might also be referred to as RFA (Resident Flash Array) in the 
following text.

Example implentations of sysTffs.c can be found in the directory

    $(WIND_BASE)/target/src/drv/tffs/sockets

The files sds860-sysTffs.c and pc386-sysTffs.c have support for single and dual 
socketed PCMCIA devices as well if that might be useful to you. They both 
support multiple sockets.


Finally, this file also contains define statements for symbolic constants
that determine which MTDs, translation layer modules, and other utilities
are ultimately included in TrueFFS.  These defines are as follows:

.IP "INCLUDE_TL_FTL"
To include the NOR-based translation layer module.
.IP "INCLUDE_TL_SSFDC"
To include the SSFDC-appropriate translation layer module.
.IP "INCLUDE_MTD_I28F016"
For Intel 28f016 flash devices.
.IP "INCLUDE_MTD_I28F008"
For Intel 28f008 flash devices.
.IP "INCLUDE_MTD_I28F008_BAJA"
For Intel 28f008 flash devices on the Heurikon Baja 4700.
.IP "INCLUDE_MTD_AMD"
For AMD, Fujitsu: 29F0{40,80,16} 8-bit flash devices.
.IP "INCLUDE_MTD_CFIAMD"
For CFI compliant AMD, Fujitsu flash devices.
.IP "INCLUDE_MTD_CFISCS"
For CFI/SCS flash devices.
.IP "INCLUDE_MTD_WAMD"
For AMD, Fujitsu 29F0{40,80,16} 16-bit flash devices.
.IP "INCLUDE_TFFS_BOOT_IMAGE"
To include tffsBootImagePut() in TrueFFS for Tornado.
.LP
To exclude any of the modules mentioned above, edit sysTffs.c and undefine
its associated symbolic constant.


INCLUDE FILES: flsocket.h, tffsDrv.h
*/


/* includes */

#include "vxWorks.h"
#include "taskLib.h"
#include "config.h"
#include "tffs/flsocket.h"
#include "tffs/tffsDrv.h"

#define INCLUDE_MTD_CFISCS
#undef INCLUDE_MTD_USR           /* xfsun define */

/* defines */

#ifndef PRJ_BUILD
#undef  INCLUDE_MTD_I28F016             /* Intel: 28f016 */
#undef  INCLUDE_MTD_I28F008             /* Intel: 28f008 */
#undef  INCLUDE_MTD_AMD                 /* AMD, Fujitsu: 29f0{40,80,16} 8bit */
#undef  INCLUDE_MTD_CFIAMD              /* CFI driver for AMD Flash Part */
#define INCLUDE_MTD_CFISCS              /* CFI/SCS */
#undef  INCLUDE_MTD_WAMD                /* AMD, Fujitsu: 29f0{40,80,16} 16bit */
#define INCLUDE_TL_FTL                  /* FTL translation layer */
#undef  INCLUDE_TL_SSFDC                /* SSFDC translation layer */
#undef  INCLUDE_SOCKET_SIMM             /* SIMM socket interface */
#undef  INCLUDE_SOCKET_PCMCIA           /* PCMCIA socket interface */
#endif  /* PRJ_BUILD */

/* TODO : 
 * If you don't use TrueFFS to write your boot image you might want
 * to undefine this.
 */

#define INCLUDE_TFFS_BOOT_IMAGE		/* include tffsBootImagePut() */

/* TODO : 
 * set these to board specific values.
 * The values used here are fictional.
 */

#define	FLASH_BASE_ADRS		0x50000000	/* Flash memory base address */
#define	FLASH_SIZE		0x00400000	/* Flash memory size */
#define VCC_DELAY_MSEC		100	/* Millisecs to wait for Vcc ramp up */
#define VPP_DELAY_MSEC		100	/* Millisecs to wait for Vpp ramp up */
#define KILL_TIME_FUNC	 ((iz * iz) / (iz + iz)) / ((iy + iz) / (iy * iz))


/* locals */

LOCAL UINT32 sysTffsMsecLoopCount = 0;


/* forward declarations */

LOCAL FLBoolean		rfaCardDetected (FLSocket vol);
LOCAL void		rfaVccOn (FLSocket vol);
LOCAL void		rfaVccOff (FLSocket vol);
#ifdef	SOCKET_12_VOLTS
LOCAL FLStatus		rfaVppOn (FLSocket vol);
LOCAL void		rfaVppOff (FLSocket vol);
#endif	/* SOCKET_12_VOLTS */
LOCAL FLStatus		rfaInitSocket (FLSocket vol);
LOCAL void		rfaSetWindow (FLSocket vol);
LOCAL void		rfaSetMappingContext (FLSocket vol, unsigned page);
LOCAL FLBoolean		rfaGetAndClearCardChangeIndicator (FLSocket vol);
LOCAL FLBoolean		rfaWriteProtected (FLSocket vol);
LOCAL void		rfaRegister (void);


#ifndef DOC
#include "tffs/tffsConfig.c"
#endif /* DOC */

/*******************************************************************************
*
* sysTffsInit - board level initialization for TFFS
*
* This routine calls the socket registration routines for the socket component
* drivers that will be used with this BSP. The order of registration signifies
* the logical drive number assigned to the drive associated with the socket.
*
* RETURNS: N/A
*/

LOCAL void sysTffsInit (void)
    {
    UINT32 ix = 0;
    UINT32 iy = 1;
    UINT32 iz = 2;
    int oldTick;

    /* we assume followings:
     *   - no interrupts except timer is happening.
     *   - the loop count that consumes 1 msec is in 32 bit.
     * it is done in the early stage of usrRoot() in tffsDrv().  */

    oldTick = tickGet();
    while (oldTick == tickGet())	/* wait for next clock interrupt */
	;

    oldTick = tickGet();
    while (oldTick == tickGet())	/* loop one clock tick */
	{
	iy = KILL_TIME_FUNC;		/* consume time */
	ix++;				/* increment the counter */
	}
    
    sysTffsMsecLoopCount = ix * sysClkRateGet() / 1000;

    /* TODO:
     * Call each sockets register routine here
     */

    rfaRegister ();			/* RFA socket interface register */

    }

/*******************************************************************************
*
* rfaRegister - install routines for the Flash RFA
*
* This routine installs necessary functions for the Resident Flash Array(RFA).
*
* RETURNS: N/A
*/

LOCAL void rfaRegister (void)
    {
    FLSocket vol = flSocketOf (noOfDrives);

    tffsSocket[noOfDrives] =	"RFA";
    vol.window.baseAddress =	FLASH_BASE_ADRS >> 12;
    vol.cardDetected =		rfaCardDetected;
    vol.VccOn =			rfaVccOn;
    vol.VccOff =		rfaVccOff;
#ifdef SOCKET_12_VOLTS
    vol.VppOn =			rfaVppOn;
    vol.VppOff =		rfaVppOff;
#endif
    vol.initSocket =		rfaInitSocket;
    vol.setWindow =		rfaSetWindow;
    vol.setMappingContext =	rfaSetMappingContext;
    vol.getAndClearCardChangeIndicator = rfaGetAndClearCardChangeIndicator;
    vol.writeProtected =	rfaWriteProtected;
    noOfDrives++;
    }

/*******************************************************************************
*
* rfaCardDetected - detect if a card is present (inserted)
*
* This routine detects if a card is present (inserted).
* Always return TRUE in RFA environments since device is not removable.
*
* RETURNS: TRUE, or FALSE if the card is not present.
*/

LOCAL FLBoolean rfaCardDetected
    (
    FLSocket vol		/* pointer identifying drive */
    )
    {
    return (TRUE);
    }

/*******************************************************************************
*
* rfaVccOn - turn on Vcc (3.3/5 Volts)
*
* This routine turns on Vcc (3.3/5 Volts).  Vcc must be known to be good
* on exit. Assumed to be ON constantly in RFA environment.
*
* RETURNS: N/A
*/

LOCAL void rfaVccOn
    (
    FLSocket vol		/* pointer identifying drive */
    )
    {
    }

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美电视剧免费全集观看| 亚洲三级电影全部在线观看高清| 久久久精品中文字幕麻豆发布| 中文字幕亚洲电影| 激情综合一区二区三区| 欧美日韩一区在线观看| 欧美激情一区二区三区不卡 | 精品亚洲免费视频| 一本久道中文字幕精品亚洲嫩| 精品日韩av一区二区| 日日夜夜精品免费视频| 91在线你懂得| 国产精品美女久久久久aⅴ国产馆| 日本不卡视频在线| 69精品人人人人| 亚洲一区二区欧美日韩| 日本韩国一区二区三区视频| 亚洲国产高清在线| 国产精品99久久久| 久久婷婷国产综合精品青草| 日韩av网站在线观看| 欧美午夜不卡视频| 亚洲一级二级在线| 精油按摩中文字幕久久| 欧美va在线播放| 久久机这里只有精品| 在线成人免费观看| 裸体在线国模精品偷拍| 精品国产亚洲在线| 国产河南妇女毛片精品久久久| 久久免费国产精品| 风间由美中文字幕在线看视频国产欧美| 精品国产一区二区精华| 国产精品一区二区你懂的| 久久综合九色综合97婷婷女人| 久久精品噜噜噜成人av农村| 精品国产免费一区二区三区四区 | 国产99久久久精品| 国产日韩欧美一区二区三区综合| 国产成人综合亚洲网站| 国产精品国产三级国产aⅴ无密码 国产精品国产三级国产aⅴ原创 | 亚洲蜜臀av乱码久久精品蜜桃| 波多野结衣视频一区| **欧美大码日韩| 欧美视频一区二区在线观看| 日韩和欧美一区二区三区| 日韩午夜激情电影| 国产高清亚洲一区| 亚洲精品日日夜夜| 日韩欧美中文一区| 国产精品一线二线三线| 国产精品成人免费| 欧美日韩国产bt| 久久99久久精品欧美| 国产精品久久久爽爽爽麻豆色哟哟| 99久久免费国产| 强制捆绑调教一区二区| 久久久精品一品道一区| 91黄色激情网站| 久久97超碰国产精品超碰| 国产精品国产三级国产aⅴ入口| 欧美色图天堂网| 国内精品国产三级国产a久久| 亚洲欧洲精品天堂一级| 国产精品传媒在线| 欧美日韩国产a| 大胆欧美人体老妇| 日韩精品亚洲一区二区三区免费| 久久久青草青青国产亚洲免观| 色综合天天综合网国产成人综合天| 丝袜亚洲另类欧美| 国产精品久久久久7777按摩| 91精品综合久久久久久| 成人av网址在线| 另类人妖一区二区av| 亚洲天堂2016| 久久久久久久久久久久电影 | 久久亚洲综合色一区二区三区| 91小视频免费观看| 国内精品伊人久久久久av影院 | 国产一区二三区好的| 亚洲伊人色欲综合网| 国产欧美日韩久久| 欧美成人精品高清在线播放| 色综合天天天天做夜夜夜夜做| 国产一区二区按摩在线观看| 性做久久久久久免费观看| 亚洲视频精选在线| 久久久精品日韩欧美| 日韩欧美成人午夜| 91精品国产综合久久香蕉的特点 | 黑人巨大精品欧美一区| 亚洲成a人在线观看| 亚洲免费在线播放| 中文字幕在线免费不卡| 国产欧美日韩在线看| 欧美成人一区二区三区| 欧美老女人第四色| 色欧美乱欧美15图片| www.欧美.com| 91亚洲男人天堂| 99久久婷婷国产综合精品电影| 国产成人免费视频| 国产精品一区三区| 懂色av一区二区三区免费观看| 国产一区二区看久久| 国产精品夜夜爽| 国产乱对白刺激视频不卡 | 视频在线观看一区| 亚洲高清免费一级二级三级| 一片黄亚洲嫩模| 亚洲综合在线视频| 亚洲成人av一区二区三区| 亚洲成人午夜电影| 日韩中文字幕麻豆| 日本aⅴ免费视频一区二区三区 | 99久久精品免费看| 91小视频免费观看| 欧美综合一区二区| 欧美三级日韩三级| 日韩亚洲欧美高清| 精品国产亚洲在线| 中文天堂在线一区| 亚洲精选免费视频| 亚洲韩国精品一区| 丝袜诱惑亚洲看片 | 麻豆精品视频在线观看视频| 久久电影国产免费久久电影| 国产精品88av| 99这里都是精品| 欧美系列一区二区| 91精品欧美福利在线观看| 欧美电影免费观看完整版| 国产亚洲va综合人人澡精品| 亚洲另类色综合网站| 视频一区在线播放| 国产suv精品一区二区883| 色综合天天天天做夜夜夜夜做| 欧美色综合网站| 久久亚洲捆绑美女| 自拍偷拍欧美精品| 美女国产一区二区| 99久久99久久综合| 欧美一区二区三区在线电影| 国产亚洲欧美一级| 亚洲午夜免费电影| 国产精品一区二区三区99| 色成年激情久久综合| 久久一区二区视频| 亚洲永久精品大片| 国产一区二区三区在线观看免费视频| 91在线视频播放地址| 精品国产一区二区三区av性色 | 精品视频在线看| 国产亚洲精品久| 日本成人中文字幕在线视频 | 日韩视频中午一区| 亚洲欧美偷拍另类a∨色屁股| 日本不卡不码高清免费观看| www.视频一区| 精品国产乱码久久久久久久久| 亚洲女与黑人做爰| 国产电影一区二区三区| 9191精品国产综合久久久久久 | 麻豆freexxxx性91精品| 日本精品视频一区二区三区| 久久久国产午夜精品| 水蜜桃久久夜色精品一区的特点| 成人av手机在线观看| www国产精品av| 五月天欧美精品| 一本一道久久a久久精品| 亚洲国产高清不卡| 国产一区二区女| 日韩欧美综合一区| 午夜精品久久久久久久| 一本久久a久久免费精品不卡| 中文av字幕一区| 国产成人激情av| 久久久久久一级片| 狠狠色综合日日| 在线播放中文一区| 亚欧色一区w666天堂| 在线观看不卡一区| 一区二区三区精品在线观看| eeuss鲁片一区二区三区| 国产性天天综合网| 国产成人午夜精品影院观看视频 | 蜜桃视频免费观看一区| 欧美日韩二区三区| 亚洲综合久久久| 色呦呦国产精品| 国产专区欧美精品| 2017欧美狠狠色| 极品美女销魂一区二区三区| 欧美精品一区二区三区蜜臀| 韩国午夜理伦三级不卡影院| 久久网站热最新地址| 国产.欧美.日韩| 日韩一区日韩二区|