亚洲欧美第一页_禁久久精品乱码_粉嫩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一区二区三区免费野_久草精品视频
欧美天堂一区二区三区| 91精品国产综合久久婷婷香蕉| 久久www免费人成看片高清| 亚洲免费色视频| 国产精品视频一二三| 91精品国产91久久久久久一区二区| 91视频91自| 91视频国产资源| 欧美xxxxx裸体时装秀| 欧美亚洲自拍偷拍| 一本高清dvd不卡在线观看| 丁香婷婷综合网| 国产xxx精品视频大全| 国产高清在线精品| 国模冰冰炮一区二区| 国产一区二区三区精品视频| 美女久久久精品| 另类小说综合欧美亚洲| 久久精品国产秦先生| 美女一区二区久久| 久色婷婷小香蕉久久| 久久99精品视频| 精品一区二区三区在线观看国产| 亚洲一区在线免费观看| 中文字幕色av一区二区三区| 亚洲精品一区二区三区香蕉| 91精品国产乱| 欧美一区二区三区四区久久| 日韩丝袜情趣美女图片| 欧美不卡一区二区三区| 99精品久久久久久| 精品制服美女丁香| 亚洲天堂福利av| 欧美成人bangbros| 精品成人在线观看| 国产亚洲欧美色| 国产精品久久久久影院老司| 自拍偷拍国产精品| 亚洲精品欧美在线| 亚洲成人高清在线| 蜜桃精品在线观看| 久久国产成人午夜av影院| 国产主播一区二区三区| 成人国产视频在线观看| 欧美性猛交xxxxxx富婆| 日韩一区二区三区av| 国产亚洲成年网址在线观看| 中文字幕在线不卡一区 | 精品少妇一区二区三区在线视频| 久久先锋资源网| 亚洲欧洲国产日本综合| 婷婷国产在线综合| 国产酒店精品激情| 99久精品国产| 在线综合视频播放| 国产欧美精品一区二区色综合朱莉| 1024成人网| 奇米精品一区二区三区在线观看 | 亚洲成人免费影院| 国产一区在线精品| 色老综合老女人久久久| 欧美一区二区成人6969| 中文字幕av一区 二区| 亚洲一区二区精品久久av| 久久国产成人午夜av影院| 91小视频在线观看| 日韩欧美不卡一区| 亚洲精品成人在线| 青青草国产成人av片免费| 国产综合久久久久影院| 色播五月激情综合网| 久久亚洲一级片| 性欧美大战久久久久久久久| 国产精品99久久久久久久vr| 欧美日韩午夜精品| 欧美国产乱子伦| 蜜桃av噜噜一区二区三区小说| 99久久99久久久精品齐齐| 欧美日韩国产综合视频在线观看| 国产女同性恋一区二区| 免费观看在线综合色| 色香蕉久久蜜桃| 国产精品沙发午睡系列990531| 视频一区视频二区中文字幕| av亚洲精华国产精华| 精品对白一区国产伦| 亚洲丝袜另类动漫二区| 免费高清成人在线| 色婷婷精品久久二区二区蜜臂av| 欧美日韩国产综合草草| 最新日韩av在线| 激情六月婷婷久久| 欧美日韩一级二级三级| 亚洲日本在线天堂| 国产成人免费视频精品含羞草妖精| 欧美系列亚洲系列| 国产精品二三区| 狠狠色狠狠色综合日日91app| 欧美色涩在线第一页| 亚洲日本电影在线| 国产成人精品免费看| 日韩精品中文字幕在线不卡尤物 | 亚洲精品水蜜桃| 国产99精品视频| 精品国产免费人成电影在线观看四季| 三级亚洲高清视频| 欧美性色综合网| 亚洲摸摸操操av| 99国产精品久久久久久久久久| 久久久www成人免费无遮挡大片| 美女脱光内衣内裤视频久久影院| 精品视频在线免费看| 一区二区三区美女| 99re8在线精品视频免费播放| 国产精品免费久久久久| 国产成人丝袜美腿| 国产欧美日韩久久| 国产精品91xxx| 久久精品人人做人人爽97| 国产综合成人久久大片91| 欧美精品123区| 亚洲电影激情视频网站| 欧美日韩亚洲综合在线| 五月天婷婷综合| 欧美一级在线观看| 亚洲午夜在线视频| 欧美在线小视频| 亚洲一区二区欧美激情| 91国内精品野花午夜精品| 亚洲欧美一区二区三区孕妇| 色综合天天综合给合国产| 亚洲精品国产成人久久av盗摄| 欧美性感一区二区三区| 日韩经典中文字幕一区| 91精品久久久久久久91蜜桃| a4yy欧美一区二区三区| 亚洲麻豆国产自偷在线| 在线观看亚洲专区| 蜜臀av国产精品久久久久| 久久精品视频免费观看| 成人免费视频视频在线观看免费 | 欧美一区日韩一区| 久久99国产精品麻豆| 国产三级精品三级在线专区| 99久久综合狠狠综合久久| 一区二区三区中文字幕| 欧美日韩久久一区二区| 麻豆精品国产91久久久久久| 久久这里只有精品视频网| 波多野结衣亚洲一区| 一区二区国产视频| 亚洲天堂久久久久久久| 4438亚洲最大| 国产成人一级电影| 一区二区三区四区激情| 日韩午夜激情免费电影| 成人久久久精品乱码一区二区三区| 玉米视频成人免费看| 欧美一级高清片在线观看| 捆绑调教一区二区三区| 欧美国产一区视频在线观看| 成人天堂资源www在线| 亚洲精品国产成人久久av盗摄| 欧美自拍偷拍午夜视频| 久久不见久久见免费视频7| 国产精品传媒视频| 69p69国产精品| 成人激情动漫在线观看| 日韩激情视频网站| 国产精品嫩草影院com| 欧美精品第1页| 国产成人av电影在线| 日韩精品亚洲专区| 国产精品三级av| 欧美一区二区在线看| 97久久精品人人澡人人爽| 热久久国产精品| 成人欧美一区二区三区黑人麻豆| 日韩视频免费观看高清完整版在线观看| 成人网页在线观看| 老司机精品视频导航| 亚洲宅男天堂在线观看无病毒| 国产日本一区二区| 国产精品主播直播| 欧美精品一区二区三区蜜桃| 国产一区视频网站| 国产精品色婷婷久久58| 成人免费观看av| 国产一区二区在线观看视频| 日韩黄色在线观看| 亚洲国产sm捆绑调教视频| 亚洲欧洲一区二区三区| 亚洲国产精品av| 国产欧美一区在线| 久久免费视频色| 国产三级一区二区| 久久精品在线观看| 国产午夜亚洲精品理论片色戒| 久久婷婷成人综合色| 26uuu另类欧美|