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

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

?? usbpcistub.c

?? Kontron的ETX-P3T的BSP的源代碼
?? C
?? 第 1 頁 / 共 2 頁
字號:
/* usbPciStub.c - System-specific PCI Functions *//* Copyright 1999-2002 Wind River Systems, Inc. *//*Modification history--------------------01l,13may02,rhe  added sysUsbOhciPciInit to detect USB's ohci spr# 7630801k,07dec01,wef  fixed name description above and warnings.01j,01oct01,pai  changed IVEC() macro definition for T2.2 (Veloce)01i,27sep00,jgn  fix translation code for VxWorks AE01h,17may00,wef  created for pentium bsp 01g,17apr00,wef  in executing 01f, some lines were left out.  replaced them01f,10apr00,wef  change usrUsbPciLib.c to bsp specific stubs to 		 remove bsp dependency01e,08mar00,rcb  Correct prototype for usbPciMemioOffset()...		 was incorrectly called usbPciMemOffset().01d,07mar00,rcb  Add support for MIPS R5000 platform.01c,10dec99,rcb  Add definition for usbPciMemioOffset().  Add conditional		 code to differentiate mcp750 and mtx604.01b,05dec99,rcb  Add code in usbPciIntConnect() and usbPciIntRestore() to		 maintain usage counts for each interrupt number.  This allows		 multiple callers to share a single interrupt.01a,31may99,rcb  First.*//*DESCRIPTIONThis file defines platform-independent functions accessing PCI bus capabilities.  These functions allow PCI device drivers to be written independent of the underlying O/S's PCI access mechanisms.The name of each function in this group begins with "usb" to represent"Device Driver Services."*//* Includes */#include "vxWorks.h"#include "string.h"#include "sysLib.h"#include "cacheLib.h"#include "iv.h"#include "intLib.h"#include "sysLib.h"#include "drv/pci/pciConfigLib.h"   /* VxWorks PCI funcs *//* PLATFORM-DEPENDENT INCLUDES/DEFINITIONS *//* Pentium (e.g, PC Pentium) */#include "drv/pci/pciIntLib.h"/* Mappings for I/O and memory address translation */#define PCI_IO_OFFSET	    0#define PCI_MEM_OFFSET	    0#define PCI_MEMIO_OFFSET    0/* Interrupt enable/disable */#define INTERRUPT_BASE	0x20#define IVEC(irq) 	INUM_TO_IVEC (INT_NUM_GET(irq))#define INT_CONNECT(intNo, func, param) \    pciIntConnect (IVEC (intNo), (VOIDFUNCPTR) func, (int) param)#define INT_DISCONNECT(intNo, func, param) \    pciIntDisconnect (IVEC (intNo), (VOIDFUNCPTR) func)#define INT_ENABLE(i)	sysIntEnablePIC (i)#define INT_DISABLE(i)	sysIntDisablePIC (i)/* more includes */#include "usb/usbPlatform.h"	    /* Basic definitions */#include "usb/usbPciLib.h"	    /* Our API *//* defines *//* MAX OHCI number to find */#define MAX_USB_OHCI_NUM        8/* USB OHCI pci memory size */#define USB_OHCI_PCI_MEMSIZE    0x1000 #ifndef OHCI_CLASS#define OHCI_CLASS              0x0c#endif  /* OHCI_CLASS */#ifndef OHCI_SUBCLASS#define OHCI_SUBCLASS           0x03#endif  /* OHCI_SUBCLASS */#ifndef OHCI_PGMIF#define OHCI_PGMIF              0x10#endif /* OHCI_PGMIF *//* Map I/O functions to underlying system functions. */#define OUR_PCI_IN_BYTE(a)	sysInByte ((a) + PCI_IO_OFFSET)#define OUR_PCI_IN_WORD(a)	sysInWord ((a) + PCI_IO_OFFSET)#define OUR_PCI_IN_DWORD(a)	sysInLong ((a) + PCI_IO_OFFSET)#define OUR_PCI_OUT_BYTE(a,v)	sysOutByte ((a) + PCI_IO_OFFSET, (v))#define OUR_PCI_OUT_WORD(a,v)	sysOutWord ((a) + PCI_IO_OFFSET, (v))#define OUR_PCI_OUT_DWORD(a,v)	sysOutLong ((a) + PCI_IO_OFFSET, (v))/* code tracks usage count for interrupts 0..MAX_INT_NO-1. */#define MAX_INT_NO		16/* imports */IMPORT STATUS    sysMmuMapAdd (void * address, UINT len,                               UINT initialStateMask,                               UINT initialState);/* locals */LOCAL UINT16 intUsage [MAX_INT_NO] = {0};/***************************************************************************** usbPciClassFind - Locates PCI devices by class.** A caller uses this function to locate a PCI device by its PCI class.* The caller must specify the <pciClass>, <subClass>, and <pgmIf> for the* device being sought.	The function returns the first matching device* for <index> = 0, the second for <index> = 1, and so forth.  The* bus number, device number, and function number for the matching device * are returned in the <pBusNo>, <pDeviceNo>, and <pFuncNo> buffers provided * by the caller. *** RETURNS: TRUE if matching device found*	   FALSE if device not found*/BOOL usbPciClassFind    (    UINT8 pciClass,		/* PCI device class */    UINT8 subClass,		/* PCI device sub-class */    UINT8 pgmIf,		/* Programming interface */    UINT16 index,		/* Caller wants nth matching dev */    pUINT8 pBusNo,		/* Bus number of matching dev */    pUINT8 pDeviceNo,		/* Device number of matching dev */    pUINT8 pFuncNo		/* Function number of matching dev */    )    {    int intBusNo;		/* VxWorks returns "int" values */    int intDeviceNo;    int intFuncNo;        /* Use the VxWorks PCI config. library to find a device within the    specified class. */    if (pciFindClass ((pciClass << 16) | (subClass << 8) | pgmIf, index,	&intBusNo, &intDeviceNo, &intFuncNo) != OK)	{	return FALSE;	}    else	{	if (pBusNo)		*pBusNo = (UINT8) intBusNo;	if (pDeviceNo)		*pDeviceNo = (UINT8) intDeviceNo;	if (pFuncNo)		*pFuncNo = (UINT8) intFuncNo;	}    return TRUE;    }/***************************************************************************** usbPciByteGet - Returns a UINT8 configuration value** This function returns the UINT8 value at offset <regOffset> from * the PCI configuration space of the device identified by <busNo>, * <deviceNo>, and <funcNo>.** RETURNS: UINT8 value read from device configuration space*/UINT8 usbPciByteGet     (    UINT8 busNo,		/* Bus number of device */    UINT8 deviceNo,		/* Device number of device */    UINT8 funcNo,		/* Function number of device */    UINT16 regOffset		/* Offset into PCI config space */    )    {    UINT8 value;    if (pciConfigInByte (busNo, deviceNo, funcNo, regOffset, &value) != OK)	return 0;    return value;    }/***************************************************************************** usbPciWordGet - Returns a UINT16 configuration value** This function returns the UINT16 value at offset <regOffset> from * the PCI configuration space of the device identified by <busNo>, * <deviceNo>, and <funcNo>.** NOTE: This function adjusts for big vs. little endian environments.** RETURNS: UINT16 value read from device configuration space*/UINT32 usbPciWordGet    (    UINT8 busNo,		/* Bus number of device */    UINT8 deviceNo,		/* Device number of device */    UINT8 funcNo,		/* Function number of device */    UINT16 regOffset		/* Offset into PCI config space */    )    {    UINT16 value;    if (pciConfigInWord (busNo, deviceNo, funcNo, regOffset, &value) != OK)	return 0;    return value;    }/***************************************************************************** usbPciDwordGet - Returns a UINT32 configuration value** This function returns the UINT32 value at offset <regOffset> from * the PCI configuration space of the device identified by <busNo>, * <deviceNo>, and <funcNo>.** NOTE: This function adjusts for big vs. little endian environments.** RETURNS: UINT32 value read from device configuration space*/UINT32 usbPciDwordGet    (    UINT8 busNo,		/* Bus number of device */    UINT8 deviceNo,		/* Device number of device */    UINT8 funcNo,		/* Function number of device */    UINT16 regOffset		/* Offset into PCI config space */    )    {    UINT32 value;    if (pciConfigInLong (busNo, deviceNo, funcNo, regOffset, &value) != OK)	return 0;    return value;    }/***************************************************************************** usbPciConfigHeaderGet - Reads a device's PCI configuration header** This function reads the PCI configuration header for the device* identified by <busNo>, <deviceNo>, and <funcNo>.  The configuration* header is stored in the <pCfgHdr> buffer provided by the caller.** This function initializes the <pCfgHdr> structure to zeros.  Any * fields which cannot be read from the device's configuration header * will remain zero upon return.  This function does not attempt to read* fields defined as "reserved" in the PCI configuration header.** RETURNS: N/A*/VOID usbPciConfigHeaderGet    (    UINT8 busNo,		/* Bus number of device */    UINT8 deviceNo,		/* Device number of device */    UINT8 funcNo,		/* Function number of device */    pPCI_CFG_HEADER pCfgHdr	/* Buffer provided by caller */    )    {    int i;    /* Do nothing if CfgHdr is NULL */    if (pCfgHdr == NULL)	return;    /* Initialize the buffer to zeros. */    memset (pCfgHdr, 0, sizeof (*pCfgHdr));    /* Read and store each field in the PCI configuration header. */    pCfgHdr->vendorId	= usbPciWordGet (busNo, deviceNo, funcNo, PCI_CFG_VENDOR_ID);    pCfgHdr->deviceId	= usbPciWordGet (busNo, deviceNo, funcNo, PCI_CFG_DEVICE_ID);    pCfgHdr->command	= usbPciWordGet (busNo, deviceNo, funcNo, PCI_CFG_COMMAND);    pCfgHdr->status	= usbPciWordGet (busNo, deviceNo, funcNo, PCI_CFG_STATUS);    pCfgHdr->revisionId = usbPciByteGet (busNo, deviceNo, funcNo, PCI_CFG_REVISION);    pCfgHdr->pgmIf	= usbPciByteGet (busNo, deviceNo, funcNo, PCI_CFG_PROGRAMMING_IF);    pCfgHdr->subClass	= usbPciByteGet (busNo, deviceNo, funcNo, PCI_CFG_SUBCLASS);    pCfgHdr->pciClass	= usbPciByteGet (busNo, deviceNo, funcNo, PCI_CFG_CLASS);    pCfgHdr->cacheLineSize = usbPciByteGet (busNo, deviceNo, funcNo, PCI_CFG_CACHE_LINE_SIZE);    pCfgHdr->latencyTimer = usbPciByteGet (busNo, deviceNo, funcNo, PCI_CFG_LATENCY_TIMER);    pCfgHdr->headerType = usbPciByteGet (busNo, deviceNo, funcNo, PCI_CFG_HEADER_TYPE);    pCfgHdr->bist	= usbPciByteGet (busNo, deviceNo, funcNo, PCI_CFG_BIST);    for (i = 0; i < PCI_CFG_NUM_BASE_REG; i++)	pCfgHdr->baseReg [i] = usbPciDwordGet (busNo, deviceNo, funcNo, 	    PCI_CFG_BASE_ADDRESS_0 + i * sizeof (UINT32));    pCfgHdr->romBase	= usbPciDwordGet (busNo, deviceNo, funcNo, PCI_CFG_EXPANSION_ROM);    pCfgHdr->intLine	= usbPciByteGet (busNo, deviceNo, funcNo, PCI_CFG_DEV_INT_LINE);    pCfgHdr->intPin	= usbPciByteGet (busNo, deviceNo, funcNo, PCI_CFG_DEV_INT_PIN);    pCfgHdr->minGrant	= usbPciByteGet (busNo, deviceNo, funcNo, PCI_CFG_MIN_GRANT);    pCfgHdr->maxLatency = usbPciByteGet (busNo, deviceNo, funcNo, PCI_CFG_MAX_LATENCY);    }/***************************************************************************** usbPciByteIn - input a byte from PCI I/O space** Inputs a byte from a PCI I/O address <address>.** RETURNS: byte input from i/o address*/UINT8 usbPciByteIn

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
性做久久久久久免费观看| 91丨porny丨中文| 99久久精品国产网站| 欧美年轻男男videosbes| 欧美国产激情一区二区三区蜜月| 亚洲摸摸操操av| 国产成人午夜高潮毛片| 91精品一区二区三区久久久久久 | 7777精品伊人久久久大香线蕉经典版下载 | 日韩欧美国产wwwww| 亚洲女人****多毛耸耸8| 韩国精品免费视频| 91.xcao| 亚洲在线中文字幕| 91精彩视频在线观看| √…a在线天堂一区| 国产99久久精品| 精品不卡在线视频| 久久国产成人午夜av影院| 在线播放中文一区| 亚洲超碰精品一区二区| 一本一道久久a久久精品| 国产精品国产a| 91视频观看视频| 国产精品电影一区二区| 成人黄色777网| 国产精品国产三级国产aⅴ无密码| 国产精品中文有码| 久久新电视剧免费观看| 九色porny丨国产精品| 日韩欧美黄色影院| 久久99精品国产麻豆婷婷| 精品欧美乱码久久久久久| 韩日精品视频一区| 26uuu国产一区二区三区| 精品一区二区三区在线观看| 精品99999| 国产成人精品免费在线| 国产精品久久免费看| 91啪九色porn原创视频在线观看| 亚洲视频在线一区观看| 欧美在线短视频| 三级欧美韩日大片在线看| 日韩一级黄色大片| 久久国产生活片100| 国产亚洲一区二区三区四区| 国产盗摄精品一区二区三区在线| 国产欧美一区二区三区鸳鸯浴| 成人免费视频网站在线观看| 亚洲美女免费视频| 欧美三级韩国三级日本一级| 日韩精品久久久久久| 日韩欧美一区二区久久婷婷| 国产一区二区电影| 亚洲精品一卡二卡| 91精品一区二区三区在线观看| 精品一区二区三区免费视频| 国产精品每日更新| 欧美高清视频在线高清观看mv色露露十八| 日韩高清电影一区| 中文一区在线播放| 欧美色男人天堂| 国产精品18久久久久久久久| 亚洲精品国产无天堂网2021| 91精品国产91久久久久久一区二区| 精品一区二区三区不卡 | 99re这里只有精品视频首页| 亚洲风情在线资源站| 久久色中文字幕| 欧美综合一区二区| 国产电影一区二区三区| 亚洲国产中文字幕| 欧美韩国日本不卡| 9191国产精品| 色综合咪咪久久| 国产一区二区三区黄视频| 亚洲综合免费观看高清完整版| 精品国产一区久久| 欧美色图免费看| www.久久精品| 久久99国产精品麻豆| 性做久久久久久久久| 国产精品久久久久久妇女6080| 欧美一区二区视频在线观看2020| 成人免费视频国产在线观看| 蜜臀国产一区二区三区在线播放| 亚洲人成网站在线| 国产亚洲精品7777| 日韩一区二区三区视频在线观看| 色欲综合视频天天天| 国产91精品在线观看| 蜜臀a∨国产成人精品| 亚洲综合丝袜美腿| 国产精品久久久久久久久免费丝袜| 精品日韩99亚洲| 91精品婷婷国产综合久久| 91福利精品第一导航| www.亚洲免费av| 成人黄色网址在线观看| 国产一区二区导航在线播放| 精品伊人久久久久7777人| 亚洲五码中文字幕| 亚洲欧美日本在线| 国产精品天美传媒| 国产欧美一区二区精品性| 久久伊99综合婷婷久久伊| 日韩一区二区精品在线观看| 欧美日韩国产高清一区| 欧美三级电影网| 欧美卡1卡2卡| 欧美日本在线观看| 欧美另类久久久品| 91超碰这里只有精品国产| 欧美日韩精品一区视频| 欧美日韩另类国产亚洲欧美一级| 欧美日韩综合不卡| 欧美精品 日韩| 日韩精品中文字幕一区二区三区| 欧美xingq一区二区| 2021中文字幕一区亚洲| 国产亚洲精品7777| 日韩一区中文字幕| 一区二区三区四区精品在线视频 | 欧美视频一二三区| 在线综合视频播放| 欧美大黄免费观看| 国产喷白浆一区二区三区| 国产精品色在线观看| 亚洲精品乱码久久久久久久久| 亚洲尤物在线视频观看| 免费在线观看一区| 国产精品一区二区免费不卡| 成人午夜精品在线| 在线一区二区视频| 日韩一区二区三区四区| 欧美国产97人人爽人人喊| 一区二区三区美女视频| 日韩成人av影视| 国产精品自拍一区| 91网页版在线| 91精品国产福利| 国产亚洲一二三区| 亚洲综合成人在线| 国产精品综合二区| 欧洲一区在线观看| 欧美电影免费观看高清完整版在线| 久久久久久久久久久久电影| 亚洲美女在线国产| 韩国一区二区三区| 91福利资源站| 国产视频在线观看一区二区三区| 亚洲精品国久久99热| 国产自产v一区二区三区c| 在线视频国内自拍亚洲视频| 日韩欧美国产一二三区| 亚洲黄色在线视频| 黑人精品欧美一区二区蜜桃| 在线看国产日韩| 欧美国产97人人爽人人喊| 日本不卡视频一二三区| 99久久国产综合精品麻豆| 精品日本一线二线三线不卡 | 国产精品你懂的在线欣赏| 亚洲图片欧美视频| 成人激情综合网站| 日韩欧美精品在线视频| 一区二区三区日韩欧美精品| 狠狠色丁香婷婷综合| 欧美日韩aaa| 亚洲精品你懂的| 风间由美中文字幕在线看视频国产欧美| 欧美无乱码久久久免费午夜一区| 欧美激情一区二区三区蜜桃视频| 日日夜夜一区二区| 97精品视频在线观看自产线路二| 亚洲精品在线三区| 丝袜诱惑亚洲看片| 91久久香蕉国产日韩欧美9色| 久久久久久久久久电影| 久久精品国产免费| 欧美日韩精品是欧美日韩精品| 国产精品黄色在线观看| 国产suv精品一区二区6| 亚洲精品在线观| 精久久久久久久久久久| 日韩一区二区在线播放| 日韩福利电影在线观看| 欧美性视频一区二区三区| 亚洲免费在线观看视频| 99re热这里只有精品视频| 国产精品水嫩水嫩| 成人av在线观| 1000精品久久久久久久久| zzijzzij亚洲日本少妇熟睡| 中文字幕精品三区| www.亚洲免费av| 亚洲视频一区在线| 在线免费精品视频| 亚洲国产综合91精品麻豆| 欧美午夜在线一二页|