Changeset 39503 in vbox
- Timestamp:
- Dec 1, 2011 9:36:44 PM (13 years ago)
- svn:sync-xref-src-repo-rev:
- 75174
- Location:
- trunk
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/iprt/mangling.h
r39498 r39503 1016 1016 # define RTRandU64 RT_MANGLER(RTRandU64) 1017 1017 # define RTRandU64Ex RT_MANGLER(RTRandU64Ex) 1018 # define RTReqQueueAlloc 1019 # define RTReqQueueCall 1020 # define RTReqQueueCallEx 1021 # define RTReqQueueCallV 1022 # define RTReqQueueCallVoid 1018 # define RTReqQueueAlloc RT_MANGLER(RTReqQueueAlloc) 1019 # define RTReqQueueCall RT_MANGLER(RTReqQueueCall) 1020 # define RTReqQueueCallEx RT_MANGLER(RTReqQueueCallEx) 1021 # define RTReqQueueCallV RT_MANGLER(RTReqQueueCallV) 1022 # define RTReqQueueCallVoid RT_MANGLER(RTReqQueueCallVoid) 1023 1023 # define RTReqQueueCreate RT_MANGLER(RTReqQueueCreate) 1024 1024 # define RTReqQueueDestroy RT_MANGLER(RTReqQueueDestroy) 1025 1025 # define RTReqFree RT_MANGLER(RTReqFree) 1026 # define RTReqQueueIsBusy 1027 # define RTReqQueueProcess 1028 # define RTReqSubmit 1026 # define RTReqQueueIsBusy RT_MANGLER(RTReqQueueIsBusy) 1027 # define RTReqQueueProcess RT_MANGLER(RTReqQueueProcess) 1028 # define RTReqSubmit RT_MANGLER(RTReqSubmit) 1029 1029 # define RTReqWait RT_MANGLER(RTReqWait) 1030 # define RTReqGetStatus RT_MANGLER(RTReqGetStatus) 1030 1031 # define RTS3BucketsDestroy RT_MANGLER(RTS3BucketsDestroy) 1031 1032 # define RTS3Create RT_MANGLER(RTS3Create) -
trunk/include/iprt/req.h
r39500 r39503 107 107 * This is used to request an action in the queue handler thread. 108 108 */ 109 #if defined(IN_RT) || defined(IN_RT_R3) || defined(IN_RT_R0) || defined(IN_RT_RC) 109 110 typedef struct RTREQ 110 111 { … … 116 117 volatile bool fPoolOrQueue; 117 118 /** IPRT status code for the completed request. */ 118 volatile int32_t iStatus ;119 volatile int32_t iStatusX; 119 120 /** Request state. */ 120 121 volatile RTREQSTATE enmState; … … 155 156 } u; 156 157 } RTREQ; 158 #else 159 typedef struct RTREQ RTREQ; 160 #endif 157 161 /** Pointer to an RT request packet. */ 158 162 typedef RTREQ *PRTREQ; … … 375 379 RTDECL(int) RTReqWait(PRTREQ pReq, RTMSINTERVAL cMillies); 376 380 381 /** 382 * Get the status of the request. 383 * 384 * @returns Status code in the IPRT tradition. 385 * 386 * @param pReq The request. 387 */ 388 RTDECL(int) RTReqGetStatus(PRTREQ pReq); 377 389 378 390 #endif /* IN_RING3 */ -
trunk/src/VBox/Runtime/common/misc/req.cpp
r39500 r39503 78 78 */ 79 79 pReq->enmState = RTREQSTATE_FREE; 80 pReq->iStatus 80 pReq->iStatusX = VERR_RT_REQUEST_STATUS_FREED; 81 81 pReq->enmType = RTREQTYPE_INVALID; 82 82 … … 211 211 } 212 212 RT_EXPORT_SYMBOL(RTReqWait); 213 214 215 RTDECL(int) RTReqGetStatus(PRTREQ pReq) 216 { 217 AssertPtrReturn(pReq, VERR_INVALID_POINTER); 218 AssertReturn(pReq->u32Magic == RTREQ_MAGIC, VERR_INVALID_POINTER); 219 return pReq->iStatusX; 220 } 221 RT_EXPORT_SYMBOL(RTReqGetStatus); 222 213 223 214 224 … … 331 341 * Complete the request. 332 342 */ 333 pReq->iStatus 343 pReq->iStatusX = rcReq; 334 344 pReq->enmState = RTREQSTATE_COMPLETED; 335 345 if (pReq->fFlags & RTREQFLAGS_NO_WAIT) -
trunk/src/VBox/Runtime/common/misc/reqqueue.cpp
r39502 r39503 82 82 for (unsigned i = 0; i < RT_ELEMENTS(pQueue->apReqFree); i++) 83 83 { 84 PRTREQ pReq = (PRTREQ)ASMAtomicXchgPtr( &pQueue->apReqFree[i], NULL);84 PRTREQ pReq = (PRTREQ)ASMAtomicXchgPtr((void **)&pQueue->apReqFree[i], NULL); 85 85 while (pReq) 86 86 { … … 419 419 Assert(pReq->uOwner.hQueue == pQueue); 420 420 ASMAtomicWriteNullPtr(&pReq->pNext); 421 pReq->iStatus 421 pReq->iStatusX = VERR_RT_REQUEST_STATUS_STILL_PENDING; 422 422 pReq->enmState = RTREQSTATE_ALLOCATED; 423 423 pReq->fFlags = RTREQFLAGS_IPRT_STATUS; … … 454 454 pReq->fEventSemClear= true; 455 455 pReq->fPoolOrQueue = false; 456 pReq->iStatus 456 pReq->iStatusX = VERR_RT_REQUEST_STATUS_STILL_PENDING; 457 457 pReq->enmState = RTREQSTATE_ALLOCATED; 458 458 pReq->pNext = NULL;
Note:
See TracChangeset
for help on using the changeset viewer.