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

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

?? doc2k-systffs.c

?? VxWorks5.5版本下的TrueFFS文件系統demo源代碼
?? C
?? 第 1 頁 / 共 2 頁
字號:
/* sysTffs.c - PC 386/486 system-dependent TrueFFS library *//* Copyright 1984-1997 Wind River Systems, Inc. */#include "copyright_wrs.h"/* FAT-FTL Lite Software Development Kit * Copyright (C) M-Systems Ltd. 1995-1997	*//*modification history--------------------01d,31may99,yp   Added comments suggested in SPR #2531901c,05feb99,yp   fixed SPR #22515. Bad preprocessor define01b,03jun98,yp   made scan addresses BSP specific01a,02jun98,yp   derived from pc386-sysTffs.c*//*DESCRIPTIONThis library provides board-specific hardware access routines for TrueFFS.  In effect, these routines comprise the socket component driver (or drivers)for your flash device hardware.  At socket registration time, TrueFFS stores pointers to the functions of 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, these external functions are flFitInSocketWindow() and flDelayLoop().  You should never have any need to call these functions.  However, one of the most import functions defined in this file is neitherreferenced in an 'FLSocket' structure, nor is it externally callable.  Thisfunction is sysTffsInit().  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 driverassociated 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 but BSP-specific externally callable helper function.  Internally, it calls tffsDevFormat() with a pointer to a 'FormatParams' structure 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().  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_NFTL"To include the NAND-based translation layer module..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_CDSN"For Toshiba, Samsung: NAND CDSN flash devices..IP "INCLUDE_MTD_DOC2"For Toshiba, Samsung: NAND DOC 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..LPTo exclude any of the modules mentioned above, edit sysTffs.c and undefineits associated symbolic constant.INCLUDE FILES: flsocket.hSEE ALSO : tffsDevFormat tffsRawio*//* includes */#include "vxWorks.h"#include "config.h"#include "tffs/flsocket.h"#include "tffs/pcic.h"/* defines */#define	INCLUDE_MTD_DOC2		/* Toshiba, Samsung: NAND, DOC */#define	INCLUDE_TL_NFTL			/* NFTL translation layer */#define	INCLUDE_SOCKET_DOC		/* DOC socket interface */#define INCLUDE_TFFS_BOOT_IMAGE		/* include tffsBootImagePut() */#define	WINDOW_ID	0		/* PCIC window used (0-4) */#define	VPP_DELAY_MSEC	100		/* Millisecs to wait for Vpp ramp up */#ifdef  MBX860_BD_SIZE			/* only way to know if bsp is MBX860 */#define DOC2_SCAN_ADRS_0 (CPU_PCI_ISA_MEM_BA + 0xc8000)         /* start */#define DOC2_SCAN_ADRS_1 (CPU_PCI_ISA_MEM_BA + 0xf0000)         /* end */#else	/* ! MBX860 */#define DOC2_SCAN_ADRS_0 (0xc8000)                              /* start */#define DOC2_SCAN_ADRS_1 (0xf0000)                              /* end */#endif  /* MBX 860 */#define KILL_TIME_FUNC	 ((iz * iz) / (iz + iz)) / ((iy + iz) / (iy * iz))#define PC_WINDOW	1		/* PCIC window no. used by TFFS */#define PC_EXTRAWS	1		/* PCIC wait state used by TFFS */#define PC_SOCKET_NAME_DOC "DOC"	/* DOC socket name for DOC *//* externs */IMPORT unsigned windowBaseAddress (unsigned driveNo, unsigned long startAddr,                                   unsigned long endAddr);   /* nfdc2148.c *//* globals */char pcDriveNo[2] = {NONE, NONE};       /* drive number of the sockets *//* locals */LOCAL UINT32 sysTffsMsecLoopCount = 0;	/* loop count to consume milli sec *//* forward declarations */#ifdef	INCLUDE_SOCKET_DOCLOCAL FLStatus		docRegister (void);LOCAL unsigned		docWindowBaseAddress (unsigned driveNo);LOCAL FLBoolean		docCardDetected (FLSocket vol);LOCAL void		docVccOn (FLSocket vol);LOCAL void		docVccOff (FLSocket vol);#ifdef	SOCKET_12_VOLTSLOCAL FLStatus		docVppOn (FLSocket vol);LOCAL void		docVppOff (FLSocket vol);#endif	/* SOCKET_12_VOLTS */LOCAL FLStatus		docInitSocket (FLSocket vol);LOCAL void		docSetWindow (FLSocket vol);LOCAL void		docSetMappingContext (FLSocket vol, unsigned page);LOCAL FLBoolean		docGetAndClearCardChangeIndicator (FLSocket vol);LOCAL FLBoolean		docWriteProtected (FLSocket vol);#ifdef	EXITLOCAL void		docFreeSocket (FLSocket vol);#endif	/* EXIT */#endif	/* INCLUDE_SOCKET_DOC */#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 given 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 should be 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;    (void) docRegister ();			/* Disk On Chip */    }#ifdef	INCLUDE_SOCKET_DOC/********************************************************************************* docRegister - registration routine for M-Systems Disk On Chip (DOC) *		socket component driver** This routine populates the 'vol' structure for a logical drive with the* socket component driver routines for the M-System DOC. All socket routines* are referanced through the 'vol' structure and never from here directly** RETURNS: flOK, or flTooManyComponents if there're too many drives,*                or flAdapterNotFound if there's no controller.*/LOCAL FLStatus docRegister (void)    {    FLSocket vol;    if (noOfDrives >= DRIVES)        return (flTooManyComponents);    pVol = flSocketOf (noOfDrives);    vol.window.baseAddress =	docWindowBaseAddress (vol.volNo);    if (vol.window.baseAddress == 0)        return (flAdapterNotFound);    vol.cardDetected =		docCardDetected;    vol.VccOn =			docVccOn;    vol.VccOff =		docVccOff;#ifdef SOCKET_12_VOLTS    vol.VppOn =			docVppOn;    vol.VppOff =		docVppOff;#endif    vol.initSocket =		docInitSocket;    vol.setWindow =		docSetWindow;    vol.setMappingContext =	docSetMappingContext;    vol.getAndClearCardChangeIndicator = docGetAndClearCardChangeIndicator;    vol.writeProtected =	docWriteProtected;#ifdef EXIT    vol.freeSocket =		docFreeSocket;#endif    tffsSocket[noOfDrives] = PC_SOCKET_NAME_DOC;    noOfDrives++;    return (flOK);    } /********************************************************************************* docWindowBaseAddress - Return the host base address of the DOC2 window** This routine Return the host base address of the window.* It scans the host address range from DOC2_SCAN_ADRS_0 to DOC2_SCAN_ADRS_1* (inclusive) attempting to identify DiskOnChip 2000 memory window.** RETURNS: Host physical address of window divided by 4 KB*/LOCAL unsigned docWindowBaseAddress    (    unsigned driveNo		/* drive number */    )    {    return (windowBaseAddress (driveNo, DOC2_SCAN_ADRS_0, DOC2_SCAN_ADRS_1));    }/********************************************************************************* docCardDetected - detect if a card is present (inserted)** This routine detects if a card is present (inserted).** RETURNS: TRUE, or FALSE if the card is not present.*/LOCAL FLBoolean docCardDetected    (    FLSocket vol		/* pointer identifying drive */    )    {    return (TRUE);    }/********************************************************************************* docVccOn - 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.** RETURNS: N/A

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
极品少妇xxxx偷拍精品少妇| 欧美精品777| 在线成人免费视频| 国产精品无码永久免费888| 亚洲综合一二三区| 岛国精品一区二区| 日韩欧美三级在线| 亚洲一区影音先锋| 97久久精品人人澡人人爽| 精品少妇一区二区三区视频免付费| 中文字幕佐山爱一区二区免费| 国产精品亚洲а∨天堂免在线| 欧美精品aⅴ在线视频| 亚洲乱码中文字幕综合| 高清日韩电视剧大全免费| 精品人在线二区三区| 丝袜a∨在线一区二区三区不卡| 色综合中文综合网| 亚洲午夜免费福利视频| 成人午夜av电影| 久久在线观看免费| 日本亚洲最大的色成网站www| 91黄色激情网站| 综合久久国产九一剧情麻豆| 国产.欧美.日韩| 国产欧美精品在线观看| 国产在线播放一区| 欧美精品一区二| 久久国产人妖系列| 欧美va日韩va| 国产精品一区二区男女羞羞无遮挡| 正在播放亚洲一区| 日本不卡中文字幕| 91麻豆精品国产91久久久久久久久| 成人免费视频在线观看| 99re这里只有精品视频首页| 亚洲欧美区自拍先锋| 色综合久久中文字幕综合网| 一区二区三区免费网站| 在线亚洲高清视频| 亚洲成年人影院| 91麻豆精品国产综合久久久久久 | 色94色欧美sute亚洲线路一久| 国产精品传媒视频| 色综合一个色综合| 一区二区视频在线看| 欧美午夜寂寞影院| 青青草国产成人99久久| 精品福利在线导航| 成人综合在线观看| 亚洲午夜在线观看视频在线| 91麻豆精品国产91久久久久| 久99久精品视频免费观看| 久久久精品综合| 91蜜桃免费观看视频| 午夜电影网亚洲视频| 久久久www成人免费毛片麻豆| 久久久不卡网国产精品一区| 亚洲国产精品久久不卡毛片 | 国产精品天美传媒沈樵| 午夜精品福利视频网站| 欧美成人三级电影在线| 国产成人在线视频网站| 日韩美女视频一区| 在线电影一区二区三区| 国产91色综合久久免费分享| 亚洲精品欧美激情| 日韩欧美国产综合一区| 99精品在线观看视频| 亚洲高清免费观看| 国产午夜精品美女毛片视频| 欧美在线高清视频| 激情小说亚洲一区| 亚洲欧美日韩国产手机在线| 日韩欧美卡一卡二| 色丁香久综合在线久综合在线观看| 美女爽到高潮91| 亚洲精品你懂的| 久久蜜桃一区二区| 777a∨成人精品桃花网| av亚洲精华国产精华| 另类小说欧美激情| 亚洲成人免费电影| 国产精品日产欧美久久久久| 555www色欧美视频| 色av一区二区| 成人免费视频免费观看| 人人精品人人爱| 亚洲午夜免费福利视频| 国产精品白丝在线| 国产日韩精品一区二区浪潮av | 成人午夜精品在线| 亚洲色图视频网| 欧美一区二区免费| 91视频在线观看免费| 国产在线精品一区二区夜色| 热久久国产精品| 亚洲自拍偷拍麻豆| 亚洲色图自拍偷拍美腿丝袜制服诱惑麻豆 | 91精品婷婷国产综合久久| 91丨porny丨户外露出| 国产成人精品影院| 久久99热99| 精品一区二区免费视频| 日韩成人精品在线观看| 亚洲高清不卡在线| 亚洲一二三专区| 一区二区三区影院| 亚洲欧美电影一区二区| 亚洲视频在线一区| 亚洲免费高清视频在线| 亚洲日本护士毛茸茸| 色综合久久88色综合天天| 久久99精品久久久久婷婷| 无码av免费一区二区三区试看| 亚洲狠狠爱一区二区三区| 亚洲视频一二三区| 亚洲另类在线一区| 夜夜精品视频一区二区 | 亚洲激情图片一区| 樱花草国产18久久久久| 亚洲精品国产精华液| 伊人开心综合网| 亚洲激情一二三区| 午夜精品爽啪视频| 蜜臀av性久久久久蜜臀aⅴ四虎 | 欧美一区二区三区电影| 欧美一区二区日韩| 久久影院午夜论| 中文字幕中文在线不卡住| 亚洲精品日韩综合观看成人91| 一区二区三区在线免费视频| 三级一区在线视频先锋| 激情亚洲综合在线| 99热99精品| 欧美精品免费视频| 久久久一区二区三区捆绑**| 亚洲欧洲www| 一区二区三区91| 亚洲成年人网站在线观看| 日本欧美在线看| 国产精品一区二区三区99| 99久久伊人久久99| 欧美欧美欧美欧美首页| 精品国产乱子伦一区| 国产精品免费久久久久| 亚洲一区二区三区四区在线免费观看 | 日本特黄久久久高潮| 成人黄色电影在线| 日本电影亚洲天堂一区| 欧美日韩一区二区三区不卡 | 在线综合+亚洲+欧美中文字幕| 日韩午夜电影av| 国产精品伦理在线| 香蕉久久一区二区不卡无毒影院| 国产在线观看一区二区| 99re在线视频这里只有精品| 5858s免费视频成人| 国产精品美日韩| 免费在线观看精品| av网站免费线看精品| 日韩一区二区不卡| 亚洲精品水蜜桃| 国产成人精品一区二区三区四区| 欧美日韩极品在线观看一区| 久久久91精品国产一区二区三区| 亚洲国产精品人人做人人爽| 丁香婷婷综合五月| 欧美一级淫片007| 亚洲色图.com| 国产91对白在线观看九色| ww亚洲ww在线观看国产| 欧美日韩一区二区三区四区五区| 久久综合九色综合97_久久久| 亚洲国产一区二区三区| 99精品视频在线观看免费| 日韩午夜三级在线| 日韩在线播放一区二区| proumb性欧美在线观看| 国产午夜久久久久| 美女任你摸久久| 欧美久久一二三四区| 一级女性全黄久久生活片免费| av激情亚洲男人天堂| 国产精品欧美极品| 国产精品1024久久| 精品久久人人做人人爽| 蜜臀va亚洲va欧美va天堂| 欧美性大战久久久久久久蜜臀| 日韩毛片精品高清免费| 9久草视频在线视频精品| 国产欧美精品一区aⅴ影院| 国产麻豆欧美日韩一区| 久久久国产精品不卡| 国产一区中文字幕| 久久久久99精品国产片| 国产精华液一区二区三区| 国产欧美日韩另类一区| 国产福利视频一区二区三区| 久久精品夜色噜噜亚洲a∨|