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

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

?? sysend.c

?? vxworks for Sam2410 bsp NoNet
?? C
?? 第 1 頁 / 共 3 頁
字號:
    /*     * The following code tries to automatically detect and configure     * all instances of supported Ethernet cards.     */    for (ix = 0; ix < BOARD_TYPE_NB; ix++)	{	for (iy = 0; iy < INTEGRATOR_MAX_END_DEVS; iy++)	    {	    if (pciFindDevice ((int) boardResources[ix].vendorId,			       (int) boardResources[ix].deviceId,			       iy, (int *)&pciBus, (int *)(&pciDevice), 			       (int *)(&pciFunc)) != OK)		{		break;	/* skip to next vendor/product pair */		}	    /* board detected */	    boardType = boardResources[ix].type;	    /*	     * Update the END device table	     *	     * pciDevice for PCI cards plugged in is in the range 10 to 12.	     */	    pRsrc = &(pciResources[pciDevice - 10]);	    if (pRsrc->configType == AUTO)		{		/* Assign resources (interrupt, I/O) */		pciAssignResources (pciBus, pciDevice, pciFunc);		/* get memory base address and I/O base address */#ifdef INCLUDE_DEC21X40END		if ((boardType >= DEC_START) &&		    (boardType < (DEC_START + TYPE_ALLOC)))		    {		    pciConfigInLong ((int)pciBus, (int)pciDevice, (int)pciFunc,				     PCI_CFG_BASE_ADDRESS_0,				     (int *)&pRsrc->iobaseCsr);		    pciConfigInLong ((int)pciBus, (int)pciDevice, (int)pciFunc,				     PCI_CFG_BASE_ADDRESS_1,				     (int *)&pRsrc->membaseCsr);		    pciConfigInByte ((int)pciBus, (int)pciDevice, (int)pciFunc,				     PCI_CFG_DEV_INT_LINE, (char *)&pRsrc->irq);		    pRsrc->membaseCsr &= ~CSR_BASE_MSK;		    pRsrc->iobaseCsr &= ~CSR_BASE_MSK;		    /* overwrite the resource table with read value */		    pRsrc->irqvec       = IVEC_TO_INUM(pRsrc->irq);		    }#endif /* INCLUDE_DEC21X40END */#ifdef INCLUDE_FEI82557END		if ((boardType >= FEI_START) && 		    (boardType < (FEI_START + TYPE_ALLOC)))                    {                    pFeiRes = &feiResources [unit];                    pciConfigInLong ((int)pciBus, (int)pciDevice, (int)pciFunc,                                     PCI_CFG_BASE_ADDRESS_0,                                     (int *)&pFeiRes->membaseCsr);                    /* Convert to CPU address */                    pFeiRes->membaseCsr += PCI2CPU_MEM_OFFSET;                    pciConfigInLong ((int)pciBus, (int)pciDevice, (int)pciFunc,                                     PCI_CFG_BASE_ADDRESS_1,                                     (int *)&pFeiRes->iobaseCsr);                    pFeiRes->iobaseCsr &= ~PCI_BASE_IO;                    pFeiRes->iobaseCsr += PCI2CPU_IO_OFFSET;                    pciConfigInByte (pciBus, pciDevice, pciFunc,                                     PCI_CFG_DEV_INT_LINE,                                     &pFeiRes->irq);                    }#endif /* INCLUDE_FEI82557END */		}	    else		/* Force PCI configuration */		{#ifdef INCLUDE_DEC21X40END		if ((boardType >= DEC_START) &&		    (boardType < (DEC_START + TYPE_ALLOC)))		    {		    /* set memory base address and I/O base address */		    pciConfigOutLong (pciBus, pciDevice, pciFunc,				      PCI_CFG_BASE_ADDRESS_0,				      pRsrc->iobaseCsr | PCI_BASE_IO);		    pciConfigOutLong (pciBus, pciDevice, pciFunc,				      PCI_CFG_BASE_ADDRESS_1,				      pRsrc->membaseCsr);		    pciConfigOutByte (pciBus, pciDevice, pciFunc,				      PCI_CFG_DEV_INT_LINE, pRsrc->irq);		    }#endif /* INCLUDE_DEC21X40END */#ifdef INCLUDE_FEI82557END		if ((boardType >= FEI_START) && 		    (boardType < (FEI_START + TYPE_ALLOC)))                    {                    pFeiRes = &feiResources [unit];                    pciConfigOutLong (pciBus, pciDevice, pciFunc,                                      PCI_CFG_BASE_ADDRESS_0,                                      pRsrc->membaseCsr);                    pFeiRes->membaseCsr = pRsrc->membaseCsr + PCI2CPU_MEM_OFFSET;                    pciConfigOutLong (pciBus, pciDevice, pciFunc,                                      PCI_CFG_BASE_ADDRESS_1,                                      pRsrc->iobaseCsr | PCI_BASE_IO);                    pFeiRes->iobaseCsr = pRsrc->iobaseCsr + PCI2CPU_IO_OFFSET;                    pciConfigOutByte (pciBus, pciDevice, pciFunc,                                      PCI_CFG_DEV_INT_LINE, pRsrc->irq);                    pFeiRes->irq = pRsrc->irq;		    }#endif /* INCLUDE_FEI82557END */		}	    /*	     * Update the END device table & dynamically create the load	     * string we need for this device	     */#ifdef INCLUDE_DEC21X40END	    if ((boardType >= DEC_START) &&		(boardType < (DEC_START + TYPE_ALLOC)))		{		/*		 * END load string format:		 *  "<deviceAddr>:<pciAddr>:<iVec>:<iLevel>:<numRds>:<numTds>:\		 *  <memBase>:<memSize>:<userFlags>:<phyAddr>:<pPhyTbl>:\		 *  <phyFlags>:<offset>"		 */#ifdef INTEGRATOR_ENET_FIXED_BUF_ADRS		pRsrc->buf = (void *)sysEnetBufAdrs [unit];		pRsrc->cpuToPciOffset = 0;#else /* INTEGRATOR_ENET_FIXED_BUF_ADRS */		pRsrc->cpuToPciOffset = PCI2DRAM_BASE_ADRS;#ifdef INTEGRATOR_ENET_CHECK_BUFFERS		if (pRsrc->buf = cacheDmaMalloc (INTEGRATOR_DEC_BUF_SIZE),		    pRsrc->buf == NULL)		    {		    /* cannot log msg at this point in initialisation timeline*/		    return ERROR;		    }		if (((UINT32)pRsrc->buf) < INTEGRATOR_HDR_SSRAM_SIZE)		    {		    /* cannot log msg at this point in initialisation timeline*/		    return ERROR;		    }#else /* INTEGRATOR_ENET_CHECK_BUFFERS */		pRsrc->buf = (void *)NONE;#endif /* INTEGRATOR_ENET_CHECK_BUFFERS */#endif /* INTEGRATOR_ENET_FIXED_BUF_ADRS */		sprintf (endLoadStr[currentEndDevice],			 "%#x:%#x:%#x:%#x:-1:-1:%#x:%#x:%#x:%#x:%#x:%#x:2:-1:0:",                         /* Note: unit is prepended by the mux driver */			 pRsrc->iobaseCsr + PCI2CPU_IO_OFFSET,  /*devAdrs*/			 pRsrc->cpuToPciOffset,                 /*pciMemBase*/			 pRsrc->irq, pRsrc->irqvec,             /*ivec,ilevel*/                         /* numRds=default, numTds=default */			 (UINT32)pRsrc->buf,                   /*memBase*/			 INTEGRATOR_DEC_BUF_SIZE,              /*memSize*/			 boardResources[ix].decUsrFlags,        /*usrFlags*/                         1, 0,                       /* phyAddr,pMiiPhyTbl,*/                         DEC_USR_MII_10MB  |                          DEC_USR_MII_HD    | DEC_USR_MII_100MB |                         DEC_USR_MII_FD    | DEC_USR_MII_BUS_MON                         );		endDevTbl[currentEndDevice].unit = unit++;		endDevTbl[currentEndDevice].endLoadFunc = dec21x40EndLoad;		endDevTbl[currentEndDevice].endLoadString =						endLoadStr[currentEndDevice];		endDevTbl[currentEndDevice].endLoan = DEC_BUFF_LOAN;		currentEndDevice++;		/* enable mapped memory and I/O addresses */		pciConfigOutWord (pciBus, pciDevice, pciFunc, PCI_CFG_COMMAND,				  PCI_CMD_IO_ENABLE | PCI_CMD_MASTER_ENABLE);		/* disable sleep mode */		pciConfigOutByte (pciBus, pciDevice, pciFunc, PCI_CFG_MODE,				  SLEEP_MODE_DIS);	        }#endif /* INCLUDE_DEC21X40END */#ifdef INCLUDE_FEI82557END            if ((boardType >= FEI_START) &&                (boardType < (FEI_START + TYPE_ALLOC)))                {#ifdef INTEGRATOR_ENET_FIXED_BUF_ADRS		pRsrc->buf = (void *)sysEnetBufAdrs [unit];#else  /* INTEGRATOR_ENET_FIXED_BUF_ADRS */#ifdef INTEGRATOR_ENET_CHECK_BUFFERS		if (pRsrc->buf = cacheDmaMalloc (INTEGRATOR_FEI_BUF_SIZE),		    pRsrc->buf == NULL)		    {		    /* cannot log msg at this point in initialisation timeline*/		    return ERROR;		    }		if (((UINT32)pRsrc->buf) < INTEGRATOR_HDR_SSRAM_SIZE)		    {		    /* cannot log msg at this point in initialisation timeline*/		    return ERROR;		    }#else /* INTEGRATOR_ENET_CHECK_BUFFERS */		pRsrc->buf = (void *)NONE;#endif /* INTEGRATOR_ENET_CHECK_BUFFERS */#endif /* INTEGRATOR_ENET_FIXED_BUF_ADRS */                sprintf (endLoadStr[currentEndDevice],                        "0x%08X:0x%08X:0x%X:0x%X:0x00:2",			(UINT32)pRsrc->buf, INTEGRATOR_FEI_BUF_SIZE,			INTEGRATOR_FEI_NUM_CFDS, INTEGRATOR_FEI_NUM_RFDS);                endDevTbl[currentEndDevice].unit = unit++;                endDevTbl[currentEndDevice].endLoadFunc = fei82557EndLoad;                endDevTbl[currentEndDevice].endLoadString =                                                endLoadStr[currentEndDevice];                endDevTbl[currentEndDevice].endLoan = 1;                currentEndDevice++;                /* enable mapped I/O addresses */                pciConfigOutWord (pciBus, pciDevice, pciFunc,                          PCI_CFG_COMMAND, PCI_CMD_IO_ENABLE |                          PCI_CMD_MASTER_ENABLE);		}#endif /* INCLUDE_FEI82557END */	    /* Configured the maximum number of adaptors? */	    if (currentEndDevice == INTEGRATOR_MAX_END_DEVS)		{		return OK;		}	    }	}    if ((unit == 0) || (pciDevice > PCI_MAX_DEV))	{	return ERROR;	}    return OK;    }#ifdef INCLUDE_DEC21X40END/********************************************************************************* sysLanIntEnable - enable dec21X4X interrupts** This routine enables dec21X4X interrupts.  This may involve operations on* interrupt control hardware.** RETURNS: OK or ERROR for invalid arguments.*/STATUS sysLanIntEnable    (    int	level		/* level number */    )    {    return (intEnable(level));    }/********************************************************************************* sysLanIntDisable - disable dec21X4X interrupts** This routine disables dec21X4X interrupts.  This may involve operations on* interrupt control hardware.** RETURNS: OK or ERROR for invalid arguments.*/STATUS sysLanIntDisable    (    int	level		/* level number */    )    {    return (intDisable(level));    }/********************************************************************************* sysDec21x40EnetAddrGet - get Ethernet address** This routine provides a target-specific interface for accessing a* device Ethernet address.** RETURNS: OK or ERROR if could not be obtained.*/STATUS sysDec21x40EnetAddrGet    (    int		unit,    char *	enetAdrs    )    {    /*     * There isn't a target-specific interface for accessing a     * device Ethernet address.     */    return (ERROR);    }#endif /* INCLUDE_DEC21X40END */#ifdef INCLUDE_FEI82557END#ifndef INTEGRATOR_ENET_FIXED_BUF_ADRS/********************************************************************************* sys557CpuToPci - Convert a CPU memory address to a PCI address** Must convert virtual address to a physical address, then convert the* physical address to a PCI address (PCI2DRAM_BASE_ADRS is the offset of the* CPU's memory on the PCI bus,* i.e. PCI address = (CPU physical address + PCI2DRAM_BASE_ADRS)** This routine works only for addresses in SDRAM.** WARNING: No attempt is made to ensure that the address passed into this* function is valid.** RETURNS: PCI address corresponding to the CPU virtual address provided*/UINT32 sys557CpuToPci    (    int		unit,		/* ignored */    UINT32	addr    )    {    unit = unit;		/* silence compiler */#ifdef SYS_FEI_DEBUG    logMsg ("sys557CpuToPci %#x -> %#x\n", addr, addr + PCI2DRAM_BASE_ADRS,	    0,0,0,0);#endif    return (UINT32)((CACHE_DMA_VIRT_TO_PHYS(addr)) + PCI2DRAM_BASE_ADRS);    }/********************************************************************************* sys557PciToCpu - Convert a PCI memory address to a CPU address** This is the reverse of the previous function. Here we convert from a PCI* address to a physical address in the CPU's address space, then use the* current translation tables to find the corresponding virtual address.** This routine works only for addresses in SDRAM.** WARNING: No attempt is made to ensure that the address passed into this* function is valid.** RETURNS: CPU virtual address for specified PCI address*/UINT32 sys557PciToCpu    (    int		unit,		/* ignored */    UINT32	addr    )    {    unit = unit;		/* silence compiler */#ifdef SYS_FEI_DEBUG    logMsg ("sys557PciToCpu %#x -> %#x\n", addr, addr - PCI2DRAM_BASE_ADRS,	    0,0,0,0);#endif    return (UINT32)(CACHE_DMA_PHYS_TO_VIRT(addr - PCI2DRAM_BASE_ADRS));    }#endif /* INTEGRATOR_ENET_FIXED_BUF_ADRS *//********************************************************************************* sysDelay - a small delay**/void sysDelay (void)    {    volatile UINT32 p;    /* Read from ROM, a known timing */    p = *(volatile UINT32 *)ROM_TEXT_ADRS;    /*     * Create a little more delay: some arithmetic operations that     * involve immediate constants that cannot be performed in one     * instruction.  Clearly it is possible that compiler changes will     * affect this code and leave this no longer calibrated.     */    p &=0xffff;    p +=0xff11;    p +=0xff51;    return;    }/********************************************************************************* sys557Init - prepare LAN adapter for 82557 initialization** This routine is expected to perform any adapter-specific or target-specific* initialization that must be done prior to initializing the 82557.** The 82557 driver calls this routine from the driver attach routine before* any other routines in this library.** This routine returns the interrupt level the <pIntLvl> parameter.** RETURNS: OK or ERROR if the adapter could not be prepared for initialization.*/STATUS sys557Init    (    int	unit,			/* unit number */    FEI_BOARD_INFO * pBoard     /* board information for the end driver */    )    {    volatile FEI_RESOURCE * pReso = &feiResources [unit];    UINT16	sum          = 0;    int		ix;    int		iy;    UINT16	value;#ifndef INTEGRATOR_ENET_FIXED_BUF_ADRS    void *	testbuf = 0;	/* keep compiler quite */#endif    /*     * Locate the 82557 based adapter - PRO100B, INBUSINESS and XXX.     * Note that since the INBUSINESS adapter is based upon the PRO100B     * board type, it is initialised and driven like one.     */#ifdef SYS_FEI_DEBUG    printf ("fei%d: I/O %08X membase %08X irq %d\n", unit, pReso->iobaseCsr,	    pReso->membaseCsr, pReso->irq);#endif

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲欧美另类图片小说| 国产传媒日韩欧美成人| 激情综合网激情| 大胆欧美人体老妇| 欧美性生活大片视频| 久久久久国产精品免费免费搜索| 一区二区理论电影在线观看| 国产精品一卡二卡| 日韩一区二区视频| 亚洲电影在线播放| 成人av中文字幕| 日韩一区二区三区电影在线观看| 亚洲欧美日韩国产中文在线| 国产一区美女在线| 欧美丰满美乳xxx高潮www| 亚洲欧美日韩在线播放| 成人一区二区三区视频在线观看| 欧美不卡一区二区三区| 亚洲国产日韩一级| 在线观看免费亚洲| 最新日韩av在线| 成人精品一区二区三区四区| 精品久久久久久久久久久久包黑料| 亚洲一区二区三区小说| 99国产精品一区| 中文字幕成人av| 成人动漫一区二区| 国产精品美女久久久久aⅴ国产馆 国产精品美女久久久久av爽李琼 国产精品美女久久久久高潮 | 日韩av电影免费观看高清完整版| 色综合久久久久综合99| 亚洲欧美在线另类| 99久久777色| 亚洲欧美一区二区三区久本道91| 99这里都是精品| 成人欧美一区二区三区在线播放| 成人免费福利片| 中文字幕日本乱码精品影院| 成人午夜又粗又硬又大| 亚洲天堂久久久久久久| 色呦呦国产精品| 亚洲一区二区成人在线观看| 欧美日韩一区二区三区四区 | 日韩福利电影在线观看| 欧美亚洲综合一区| 首页国产欧美日韩丝袜| 91精品国产综合久久久蜜臀图片| 精品一区二区三区在线视频| 久久九九全国免费| 91伊人久久大香线蕉| 一区二区三区自拍| 在线不卡a资源高清| 欧美aaaaa成人免费观看视频| 欧美一区二区三区影视| 国产一区二区在线影院| 国产精品福利av| 欧美在线看片a免费观看| 天堂影院一区二区| 久久久久青草大香线综合精品| 国产一区二区三区在线观看免费| 国产精品久久久久久一区二区三区| 99久久久无码国产精品| 亚洲1区2区3区视频| 精品国产网站在线观看| 99精品视频在线观看免费| 亚洲国产精品视频| 久久久久成人黄色影片| 一本大道久久a久久综合婷婷| 日韩电影在线免费观看| 中文字幕av一区二区三区免费看| 欧美日韩国产首页在线观看| 激情综合网激情| 亚洲男同1069视频| 亚洲精品一区二区三区福利| 色狠狠桃花综合| 狠狠色伊人亚洲综合成人| 亚洲女人****多毛耸耸8| 亚洲精品一区二区三区精华液| 91黄色激情网站| 国内精品免费**视频| 亚洲一区在线看| 国产精品久久久久久妇女6080 | 亚洲一区二区三区四区五区中文| 日韩女优视频免费观看| 欧美午夜一区二区三区免费大片| 国精产品一区一区三区mba视频 | 精品一区二区日韩| 中文字幕一区二区三区不卡在线| 日韩欧美综合在线| 欧美无砖砖区免费| 高清不卡在线观看av| 免费看日韩精品| 亚洲国产欧美另类丝袜| 成人欧美一区二区三区1314| 久久综合九色综合97_久久久| 欧美色图免费看| 97精品超碰一区二区三区| 国产在线麻豆精品观看| 亚洲成人高清在线| 一区二区高清在线| 亚洲三级视频在线观看| 国产日韩欧美精品一区| 久久久久久亚洲综合影院红桃| 欧美日韩视频一区二区| 在线国产亚洲欧美| 欧美亚洲尤物久久| 欧美日韩视频一区二区| 欧美性猛片aaaaaaa做受| 91黄视频在线观看| 欧美日韩中文字幕一区| 在线观看日韩精品| 欧美日韩一卡二卡三卡| 欧美日韩在线不卡| 欧美影院一区二区| 欧美三级在线看| 欧美三日本三级三级在线播放| 欧美午夜不卡视频| 91精品国产美女浴室洗澡无遮挡| 精品视频一区二区不卡| 欧美日韩一区二区三区不卡| 欧美美女激情18p| 欧美高清激情brazzers| 欧美一级黄色片| 精品国产免费久久| 久久精品男人的天堂| 中文字幕一区三区| 伊人一区二区三区| 亚洲不卡在线观看| 麻豆精品国产传媒mv男同| 久久国产麻豆精品| 丁香天五香天堂综合| 一本到不卡精品视频在线观看| 欧洲一区二区三区在线| 欧美一级片免费看| 久久免费国产精品| 成人欧美一区二区三区小说| 亚洲一区电影777| 久久精品国产色蜜蜜麻豆| 国产高清成人在线| 在线视频欧美区| 精品粉嫩aⅴ一区二区三区四区| 欧美精品一区二区蜜臀亚洲| 国产精品久久久久久妇女6080 | 欧美精品在线观看一区二区| 91精品国产乱| 国产欧美一区二区精品忘忧草| 国产精品二三区| 日韩av中文在线观看| 国产a级毛片一区| 欧美色欧美亚洲另类二区| 精品国产一二三| 亚洲综合图片区| 国产一区二区三区免费| 91国在线观看| 久久久噜噜噜久久中文字幕色伊伊 | 伊人一区二区三区| 另类小说欧美激情| 色噜噜狠狠色综合中国| 欧美草草影院在线视频| 亚洲精品v日韩精品| 狠狠色狠狠色综合日日91app| 91首页免费视频| 日韩欧美亚洲国产精品字幕久久久| 日本一区二区三级电影在线观看| 亚洲一区视频在线| 国产91丝袜在线18| 欧美一区二区三区免费视频| 国产精品成人网| 国产在线播精品第三| 精品视频在线免费| 最近日韩中文字幕| 国产精品一区二区三区乱码| 欧美日韩高清影院| 综合久久综合久久| 国产精品一区二区三区四区| 欧美一区二区三区电影| 亚洲精品国产成人久久av盗摄 | 欧美视频日韩视频| 中文久久乱码一区二区| 久久国产精品第一页| 欧美在线免费播放| 亚洲美女视频在线观看| 成人的网站免费观看| 精品久久一二三区| 首页欧美精品中文字幕| 欧美性高清videossexo| 亚洲精品国产a| 99v久久综合狠狠综合久久| 亚洲国产精品v| 国产精选一区二区三区| 精品国产伦理网| 蜜臀a∨国产成人精品| 在线电影一区二区三区| 亚洲一区二区三区三| 欧美综合欧美视频| 一区二区三区四区精品在线视频| 波多野结衣视频一区| 国产女人水真多18毛片18精品视频| 激情文学综合网| 26uuu成人网一区二区三区| 国产一区二区三区日韩|