Changeset 45678 in vbox for trunk/src/VBox/Runtime/r3/posix/fileaio-posix.cpp
- Timestamp:
- Apr 23, 2013 11:28:41 AM (12 years ago)
- svn:sync-xref-src-repo-rev:
- 85204
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Runtime/r3/posix/fileaio-posix.cpp
r39143 r45678 123 123 /** Flag whether the thread is currently waiting in the syscall. */ 124 124 volatile bool fWaiting; 125 /** Flags given during creation. */ 126 uint32_t fFlags; 125 127 /** Magic value (RTFILEAIOCTX_MAGIC). */ 126 128 uint32_t u32Magic; … … 523 525 524 526 525 RTDECL(int) RTFileAioCtxCreate(PRTFILEAIOCTX phAioCtx, uint32_t cAioReqsMax) 527 RTDECL(int) RTFileAioCtxCreate(PRTFILEAIOCTX phAioCtx, uint32_t cAioReqsMax, 528 uint32_t fFlags) 526 529 { 527 530 PRTFILEAIOCTXINTERNAL pCtxInt; … … 529 532 530 533 AssertPtrReturn(phAioCtx, VERR_INVALID_POINTER); 534 AssertReturn(!(fFlags & ~RTFILEAIOCTX_FLAGS_VALID_MASK), VERR_INVALID_PARAMETER); 531 535 532 536 if (cAioReqsMax == RTFILEAIO_UNLIMITED_REQS) … … 551 555 pCtxInt->cMaxRequests = cAioReqsMax; 552 556 pCtxInt->cReqsWaitMax = cReqsWaitMax; 557 pCtxInt->fFlags = fFlags; 553 558 *phAioCtx = (RTFILEAIOCTX)pCtxInt; 554 559 … … 872 877 int32_t cRequestsWaiting = ASMAtomicReadS32(&pCtxInt->cRequests); 873 878 874 if (RT_UNLIKELY(cRequestsWaiting <= 0)) 879 if ( RT_UNLIKELY(cRequestsWaiting <= 0) 880 && !(pCtxInt->fFlags & RTFILEAIOCTX_FLAGS_WAIT_WITHOUT_PENDING_REQUESTS)) 875 881 return VERR_FILE_AIO_NO_REQUEST; 876 882
Note:
See TracChangeset
for help on using the changeset viewer.