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

? 歡迎來(lái)到蟲(chóng)蟲(chóng)下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲(chóng)蟲(chóng)下載站

?? usbdcorelib.c

?? 基于VXWORK環(huán)境的ARM9 S2410的USB驅(qū)動(dòng)程序
?? C
?? 第 1 頁(yè) / 共 5 頁(yè)
字號(hào):
		 */		if (pClient->mngmtCallback != NULL)		    (*pClient->mngmtCallback) (pClient->mngmtCallbackParam,			(USBD_NODE_ID) msg.lParam, msg.wParam);		break;	    }	}    while (msg.msg != CALLBACK_FNC_TERMINATE);    /* Mark the callback routine as having terminated. */    OSS_SEM_GIVE (pClient->callbackExit);    }/***************************************************************************** doTransferAbort - Cancel an outstanding IRP** Directs the HCD to cancel the IRP and waits for the IRP callback to* be invoked signalling that the IRP has been unlinked successfully.** RETURNS: S_usbdLib_xxxx*/LOCAL int doTransferAbort    (    pUSBD_PIPE pPipe,		    /* Pipe owning transfer */    pUSB_IRP pIrp		    /* IRP to be cancelled */    )    {    /* The callback which indicates that an IRP has been deleted is     * asynchronous.  However, when deleting an IRP (such as when     * destroying a pipe) we generally need to know when the IRP     * callback has actually been invoked - and hence the IRP unlinked     * from the list of outstanding IRPs on the pipe.     */    pPipe->irpBeingDeleted = pIrp;    pPipe->irpDeleted = FALSE;    /* Instruct the HCD to cancel the IRP */    if (usbHcdIrpCancel (&pPipe->pNode->pBus->pHcd->nexus, pIrp) != OK)	return S_usbdLib_CANNOT_CANCEL;    /* Wait for the IRP callback to be invoked. */    while (!pPipe->irpDeleted)	OSS_THREAD_SLEEP (1);    return OK;    }/***************************************************************************** destroyNotify - de-allocates a USBD_NOTIFY_REQ** RETURNS: N/A*/LOCAL VOID destroyNotify    (    pUSBD_NOTIFY_REQ pNotify    )    {    usbListUnlink (&pNotify->reqLink);    OSS_FREE (pNotify);    }/***************************************************************************** destroyPipe - de-allocates a USBD_PIPE and its resources** RETURNS: N/A*/LOCAL VOID destroyPipe    (    pUSBD_PIPE pPipe    )    {    pUSB_IRP pIrp;    pUSBD_BUS pBus;    if (pPipe != NULL)	{	pPipe->pipeDeletePending = TRUE;	/* Cancel all IRPs outstanding on this pipe.	 *	 * NOTE: Since the IRP completion callbacks are on a different thread,	 * we need to wait until all callbacks have been completed.  This	 * functionality is built into doTransferAbort().	 */	while ((pIrp = usbListFirst (&pPipe->irps)) != NULL)	    doTransferAbort (pPipe, pIrp);	/* Release bandwidth and notify HCD that the pipe is going away. */	pBus = pPipe->pNode->pBus;	pBus->nanoseconds -= pPipe->nanoseconds;	usbHcdPipeDestroy (&pBus->pHcd->nexus, pPipe->hcdHandle);	/* Unlink pipe from owning client's list of pipes */	if (pPipe->pClient != NULL)	    usbListUnlink (&pPipe->clientPipeLink);	/* Unlink pipe from owning node's list of pipes */	if (pPipe->pNode != NULL)	    usbListUnlink (&pPipe->nodePipeLink);	/* Release pipe handle */	if (pPipe->handle != NULL)	    usbHandleDestroy (pPipe->handle);	OSS_FREE (pPipe);	}    }/***************************************************************************** destroyClient - tears down a USBD_CLIENT structure** RETURNS: N/A*/LOCAL VOID destroyClient    (    pUSBD_CLIENT pClient    )    {    pUSBD_NOTIFY_REQ pNotify;    pUSBD_PIPE pPipe;    pUSBD_HCD pHcd;    UINT16 busNo;        /* unlink client from list of clients.     *     * NOTE: usbListUnlink is smart and only unlinks the structure if it is     * actually linked.     */    usbListUnlink (&pClient->clientLink);    /* destroy all notification requests outstanding for the client */    while ((pNotify = usbListFirst (&pClient->notifyReqs)) != NULL)	destroyNotify (pNotify);    /* destroy all pipes owned by this client */    while ((pPipe = usbListFirst (&pClient->pipes)) != NULL)	destroyPipe (pPipe);    /* If this client is the current SOF master for any USBs, then release     * the SOF master status.     */    pHcd = usbListFirst (&hcdList);    while (pHcd != NULL)	{	for (busNo = 0; busNo < pHcd->busCount; busNo++)	    if (pHcd->pBuses [busNo].pSofMasterClient == pClient)		pHcd->pBuses [busNo].pSofMasterClient = NULL;	pHcd = usbListNext (&pHcd->hcdLink);	}    /* Note: callbackQueue is always created after callbackExit and     * before callbackThread     */    if (pClient->callbackThread != NULL)	{	/* Terminate the client callback thread */	usbQueuePut (pClient->callbackQueue, CALLBACK_FNC_TERMINATE,	    0, 0, CALLBACK_TIMEOUT);	OSS_SEM_TAKE (pClient->callbackExit, CALLBACK_TIMEOUT);	OSS_THREAD_DESTROY (pClient->callbackThread);	}    if (pClient->callbackQueue != NULL)	usbQueueDestroy (pClient->callbackQueue);    if (pClient->callbackExit != NULL)	OSS_SEM_DESTROY (pClient->callbackExit);    if (pClient->handle != NULL)	usbHandleDestroy (pClient->handle);    OSS_FREE (pClient);    }/***************************************************************************** fncClientReg - Register a new USBD client** RETURNS: S_usbdLib_xxxx*/LOCAL int fncClientReg    (    pURB_CLIENT_REG pUrb    )    {    pUSBD_CLIENT pClient;    int s;    /* validate URB */    if ((s = validateUrb (pUrb, sizeof (*pUrb), NULL)) != OK)	return s;    /* Create structures/resources/etc., required by new client */    if ((pClient = OSS_CALLOC (sizeof (*pClient))) == NULL)	return S_usbdLib_OUT_OF_MEMORY;    memcpy (pClient->clientName, pUrb->clientName, USBD_NAME_LEN);    if (usbHandleCreate (USBD_CLIENT_SIG, pClient, &pClient->handle) != OK ||	OSS_SEM_CREATE (1, 0, &pClient->callbackExit) != OK ||	usbQueueCreate (CALLBACK_Q_DEPTH, &pClient->callbackQueue) != OK ||	OSS_THREAD_CREATE (clientThread, pClient, OSS_PRIORITY_INHERIT, 	    "tUsbdClnt", &pClient->callbackThread) != OK)	    s = S_usbdLib_OUT_OF_RESOURCES;    else	{	/* The client was initialized successfully. Add it to the list */	usbListLink (&clientList, pClient, &pClient->clientLink, LINK_TAIL);	/* return the client's USBD_CLIENT_HANDLE */	pUrb->header.handle = pClient->handle;	}	    if (s != OK)	{	destroyClient (pClient);	}    return s;    }/***************************************************************************** fncClientUnreg - Unregister a USBD client** RETURNS: S_usbdLib_xxxx*/LOCAL int fncClientUnreg    (    pURB_CLIENT_UNREG pUrb    )    {    pUSBD_CLIENT pClient;    int s;    /* validate Urb */    if ((s = validateUrb (pUrb, sizeof (*pUrb), &pClient)) != OK)	return s;    /* destroy client */    destroyClient (pClient);    return s;    }/***************************************************************************** fncMngmtCallbackSet - sets management callback for a client** RETURNS: S_usbdLib_xxxx*/LOCAL int fncMngmtCallbackSet    (    pURB_MNGMT_CALLBACK_SET pUrb    )    {    pUSBD_CLIENT pClient;    int s;    /* validate URB */    if ((s = validateUrb (pUrb, sizeof (*pUrb), &pClient)) != OK)	return s;    /* Set the management callback */    pClient->mngmtCallback = pUrb->mngmtCallback;    pClient->mngmtCallbackParam = pUrb->mngmtCallbackParam;    return s;    }/***************************************************************************** fncVersionGet - Return USBD version** RETURNS: S_usbdLib_xxxx*/LOCAL int fncVersionGet    (    pURB_VERSION_GET pUrb    )    {    int s;    /* validate urb */    if ((s = validateUrb (pUrb, sizeof (*pUrb), NULL)) != OK)	return s;    /* return version information */    pUrb->version = USBD_VERSION;    strncpy ((char *)pUrb->mfg, USBD_MFG, USBD_NAME_LEN);    return s;    }/***************************************************************************** releaseAddress - release a USB device address** RETURNS: N/A*/LOCAL VOID releaseAddress    (    pUSBD_NODE pNode    )    {    pUSBD_BUS pBus = pNode->pBus;    pBus->adrsVec [pNode->busAddress / 8] &= ~(0x1 << (pNode->busAddress % 8));    }/***************************************************************************** assignAddress - assigns a unique USB address to a node** RETURNS: TRUE if successful, else FALSE*/LOCAL BOOL assignAddress    (    pUSBD_NODE pNode    )    {    pUSBD_BUS pBus = pNode->pBus;    UINT16 i;    /* Find an available address */    for (i = 1; i < USB_MAX_DEVICES; i++)	{	if ((pBus->adrsVec [i / 8] & (0x1 << (i % 8))) == 0)	    {	    /* i is the value of an unused address.  Set the device adrs. */	    if (usbdAddressSet (internalClient, pNode->nodeHandle, i) == OK)		{		pNode->busAddress = i;		pBus->adrsVec [i / 8] |= 0x1 << (i % 8);		return TRUE;		}	    else		{		return FALSE;		}	    }	}    return FALSE;    }/***************************************************************************** notifyIfMatch - Invoke attach callback if appropriate.** Compares the device class/subclass/protocol for <pClassType> and <pNotify>.* If the two match, then invokes the callback in <pNotify> with an attach* code of <attachCode>.** RETURNS: N/A*/LOCAL VOID notifyIfMatch    (    pUSBD_NODE pNode,    pUSBD_NODE_CLASS pClassType,    pUSBD_CLIENT pClient,    pUSBD_NOTIFY_REQ pNotify,    UINT16 attachCode    )    {    pNOTIFICATION pNotification;    /* Do the pClassType and pNotify structures contain matching class     * descriptions?     */    if (pNotify->deviceClass == USBD_NOTIFY_ALL ||	pClassType->deviceClass == pNotify->deviceClass)	{	if (pNotify->deviceSubClass == USBD_NOTIFY_ALL ||	    pClassType->deviceSubClass == pNotify->deviceSubClass)	    {	    if (pNotify->deviceProtocol == USBD_NOTIFY_ALL ||		pClassType->deviceProtocol == pNotify->deviceProtocol)		{		/* We have a match.  Schedule the client attach callback. 		 *		 * NOTE: The pNotification structure is created here and		 * released when consumed in the client callback thread.		 *		 * NOTE: In a very large USB topology (at least several		 * dozen nodes) there is a chance that we could overrun		 * a client's callback queue depending on the type of 		 * notification requests the client has made.  If this happens,		 * the following call to usbQueuePut() may block.  If *that*		 * happens, there is a chance of a deadlock if the client's		 * callback code - invoked from the clientThread() reenters		 * the USBD.  A simple solution, if that situation is observed,		 * is to increase the depth of the callback queue.		 */		if ((pNotification = OSS_CALLOC (sizeof (*pNotification))) 		    != NULL)		    {		    pNotification->callback = pNotify->callback;		    pNotification->nodeId = pNode->nodeHandle;		    pNotification->attachCode = attachCode;		    pNotification->configuration = pClassType->configuration;		    pNotification->interface = pClassType->interface;		    pNotification->deviceClass = pClassType->deviceClass;		    pNotification->deviceSubClass = pClassType->deviceSubClass;		    pNotification->deviceProtocol = pClassType->deviceProtocol;		    usbQueuePut (pClient->callbackQueue, 			CALLBACK_FNC_NOTIFY_ATTACH, 0, (UINT32) pNotification, 			OSS_BLOCK);		    }		}	    }	}    }/***************************************************************************** notifyClients - notify clients of a dynamic attach/removal** Scans the clientList looking for clients who have requested dynamic* attach/removal notification for a class matching <pNode>.  If any* are found, their dynamic attach callback routines will be invoked* with an attach code of <attachCode>.** RETURNS: N/A*/LOCAL VOID notifyClients    (    pUSBD_NODE pNode,    UINT16 attachCode    )    {    pUSBD_CLIENT pClient;    pUSBD_NOTIFY_REQ pNotify;    pUSBD_NODE_CLASS pClassType;    /* Scan for clients which have requested dynamic attach notification. */    pClient = usbListFirst (&clientList);    while (pClient != NULL)	{	/* Walk through the list of notification requests for this client */	pNotify = usbListFirst (&pClient->notifyReqs);	while (pNotify != NULL)	    {	    /* Walk through the class types for this node, looking for one	     * which matches the current client notification request.	     */	    pClassType = usbListFirst (&pNode->classTypes);	    while (pClassType != NULL)		{		notifyIfMatch (pNode, pClassType, pClient, pNotify, attachCode);		pClassType = usbListNext (&pClassType->classLink);		}

?? 快捷鍵說(shuō)明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲图片激情小说| 中文字幕一区二区三区在线播放| 亚洲欧洲日韩一区二区三区| 日韩精品久久久久久| 成人av网站在线观看免费| 91精品国产一区二区| 国产精品久久久久久久久免费桃花| 日日夜夜一区二区| 成人av资源下载| 久久影院午夜片一区| 日本美女一区二区三区| 91久久免费观看| 国产精品色噜噜| 国内精品视频666| 欧美一区二区福利在线| 亚洲在线观看免费视频| 成人黄色av网站在线| 久久久一区二区三区捆绑**| 免费观看在线综合| 欧美精品久久99| 亚洲午夜在线视频| 色综合久久综合中文综合网| 国产精品的网站| 国产福利一区二区三区| 精品日产卡一卡二卡麻豆| 日韩成人av影视| 欧美日韩mp4| 图片区小说区区亚洲影院| 色综合久久综合| 亚洲男人的天堂在线aⅴ视频| 成人毛片视频在线观看| 亚洲国产精品精华液ab| 国产成人自拍网| 久久久久久黄色| 国内不卡的二区三区中文字幕| 欧美一级欧美三级在线观看| 天天影视网天天综合色在线播放| 欧美天堂亚洲电影院在线播放| 亚洲黄一区二区三区| 色av成人天堂桃色av| 樱桃国产成人精品视频| 欧美自拍偷拍一区| 亚洲一二三四区不卡| 欧美日韩国产精选| 午夜久久久久久久久久一区二区| 欧美猛男超大videosgay| 五月激情综合婷婷| 日韩视频免费观看高清在线视频| 免费成人在线影院| 欧美电影免费观看完整版| 免费成人在线观看| 欧美变态口味重另类| 国内精品国产三级国产a久久| 久久精品人人做| 成人爱爱电影网址| 一区二区三区中文字幕精品精品 | 丁香亚洲综合激情啪啪综合| 久久精品夜色噜噜亚洲a∨| 成人性生交大片免费看中文网站| 亚洲欧洲色图综合| 欧美系列在线观看| 男人的天堂久久精品| 久久久久久免费网| 91丨九色丨国产丨porny| 亚洲综合无码一区二区| 91麻豆精品国产91久久久使用方法 | 日韩欧美激情在线| 国产激情偷乱视频一区二区三区| 欧美国产综合色视频| 色香色香欲天天天影视综合网| 午夜影院久久久| 精品动漫一区二区三区在线观看| 国产成人精品免费在线| 亚洲天堂免费看| 在线不卡中文字幕| 国产一区二区主播在线| 国产精品短视频| 欧美日本在线视频| 国产美女在线精品| 一区二区三区欧美| 欧美mv和日韩mv的网站| gogogo免费视频观看亚洲一| 亚洲成人在线观看视频| 久久久久成人黄色影片| 在线观看网站黄不卡| 久久福利视频一区二区| 一色桃子久久精品亚洲| 日韩欧美高清dvd碟片| www.欧美.com| 蜜臀久久久99精品久久久久久| 国产亚洲一区二区在线观看| 欧美亚洲日本国产| 国产精品白丝jk白祙喷水网站 | 久久久电影一区二区三区| 色综合欧美在线| 激情深爱一区二区| 亚洲日本va在线观看| 日韩欧美美女一区二区三区| 99精品在线免费| 美日韩黄色大片| 亚洲男同性视频| www国产成人免费观看视频 深夜成人网| 色综合久久天天| 国精产品一区一区三区mba桃花| 亚洲人亚洲人成电影网站色| 欧美刺激脚交jootjob| 在线观看日韩精品| 国产伦理精品不卡| 午夜在线电影亚洲一区| 中文字幕一区二区三区不卡在线| 欧美肥妇毛茸茸| 972aa.com艺术欧美| 国产综合色视频| 婷婷开心久久网| 中文字幕一区在线观看| 久久噜噜亚洲综合| 4438x亚洲最大成人网| 97超碰欧美中文字幕| 国产乱码精品1区2区3区| 性感美女极品91精品| 亚洲男人天堂av| 日本一区二区三区四区在线视频| 日韩一区二区三区四区五区六区| 91黄色激情网站| 99麻豆久久久国产精品免费| 韩国精品一区二区| 青青草原综合久久大伊人精品优势| 亚洲激情中文1区| 一区在线观看视频| 欧美激情中文不卡| 日韩精品在线看片z| 欧美精品 国产精品| 在线观看www91| 色婷婷精品久久二区二区蜜臀av| 成人一区二区三区| 国产盗摄女厕一区二区三区| 久久精品国产77777蜜臀| 婷婷综合另类小说色区| 亚洲精品国产第一综合99久久 | 欧美一区二区日韩一区二区| 欧美视频一区二区三区在线观看| 97久久精品人人爽人人爽蜜臀| 国产高清久久久| 国产成人在线观看| 韩国精品主播一区二区在线观看 | 国内精品自线一区二区三区视频| 蜜臀a∨国产成人精品| 日本中文在线一区| 三级精品在线观看| 午夜婷婷国产麻豆精品| 午夜激情久久久| 亚洲丶国产丶欧美一区二区三区| 亚洲综合av网| 亚洲一卡二卡三卡四卡无卡久久 | 精品国产麻豆免费人成网站| 欧美成人女星排名| 欧美电视剧在线看免费| 日韩女优av电影| 欧美成人一区二区三区在线观看| 精品裸体舞一区二区三区| 欧美v日韩v国产v| 精品国产乱码久久| 久久在线观看免费| 国产欧美日韩精品在线| 国产精品区一区二区三| 国产精品高潮久久久久无| 亚洲视频在线一区二区| 亚洲激情在线激情| 天天亚洲美女在线视频| 蜜臀国产一区二区三区在线播放| 久久电影网电视剧免费观看| 国产精品中文欧美| 成人av资源下载| 欧美自拍丝袜亚洲| 91精品国产欧美一区二区18 | 欧美日韩一级视频| 欧美一区二区三区免费大片| 欧美videossexotv100| 日本一区二区高清| 亚洲乱码国产乱码精品精98午夜| 亚洲一区在线播放| 免费观看一级特黄欧美大片| 国产老妇另类xxxxx| 99视频在线精品| 欧美亚洲日本国产| 日韩女优视频免费观看| 久久久久久久性| 最新国产精品久久精品| 亚洲国产精品一区二区www在线| 蜜乳av一区二区| 成人激情免费电影网址| 欧洲亚洲国产日韩| 欧美成人性战久久| 韩国v欧美v亚洲v日本v| 国产suv一区二区三区88区| 日本福利一区二区| 欧美一区二区三区性视频| 国产三级欧美三级| 亚洲精品第1页| 韩国女主播成人在线观看|