Lines Matching defs:pReqInt
115 PRTFILEAIOREQINTERNAL pReqInt = (PRTFILEAIOREQINTERNAL)RTMemAllocZ(sizeof(RTFILEAIOREQINTERNAL));
116 if (RT_UNLIKELY(!pReqInt))
120 pReqInt->AioCB.aio_sigevent.sigev_notify = SIGEV_PORT;
121 pReqInt->AioCB.aio_sigevent.sigev_value.sival_ptr = &pReqInt->PortNotifier;
122 pReqInt->PortNotifier.portnfy_user = pReqInt;
123 pReqInt->pCtxInt = NULL;
124 pReqInt->u32Magic = RTFILEAIOREQ_MAGIC;
125 RTFILEAIOREQ_SET_STATE(pReqInt, COMPLETED);
127 *phReq = (RTFILEAIOREQ)pReqInt;
139 PRTFILEAIOREQINTERNAL pReqInt = hReq;
140 RTFILEAIOREQ_VALID_RETURN(pReqInt);
141 RTFILEAIOREQ_NOT_STATE_RETURN_RC(pReqInt, SUBMITTED, VERR_FILE_AIO_IN_PROGRESS);
146 ASMAtomicUoWriteU32(&pReqInt->u32Magic, ~RTFILEAIOREQ_MAGIC);
147 RTMemFree(pReqInt);
162 PRTFILEAIOREQINTERNAL pReqInt = hReq;
163 RTFILEAIOREQ_VALID_RETURN(pReqInt);
164 RTFILEAIOREQ_NOT_STATE_RETURN_RC(pReqInt, SUBMITTED, VERR_FILE_AIO_IN_PROGRESS);
170 pReqInt->AioCB.aio_lio_opcode = uTransferDirection;
171 pReqInt->AioCB.aio_fildes = RTFileToNative(hFile);
172 pReqInt->AioCB.aio_offset = off;
173 pReqInt->AioCB.aio_nbytes = cbTransfer;
174 pReqInt->AioCB.aio_buf = pvBuf;
175 pReqInt->fFlush = false;
176 pReqInt->pvUser = pvUser;
177 pReqInt->pCtxInt = NULL;
178 RTFILEAIOREQ_SET_STATE(pReqInt, PREPARED);
199 PRTFILEAIOREQINTERNAL pReqInt = (PRTFILEAIOREQINTERNAL)hReq;
201 RTFILEAIOREQ_VALID_RETURN(pReqInt);
202 RTFILEAIOREQ_NOT_STATE_RETURN_RC(pReqInt, SUBMITTED, VERR_FILE_AIO_IN_PROGRESS);
205 pReqInt->fFlush = true;
206 pReqInt->AioCB.aio_fildes = RTFileToNative(hFile);
207 pReqInt->AioCB.aio_offset = 0;
208 pReqInt->AioCB.aio_nbytes = 0;
209 pReqInt->AioCB.aio_buf = NULL;
210 pReqInt->pvUser = pvUser;
211 RTFILEAIOREQ_SET_STATE(pReqInt, PREPARED);
218 PRTFILEAIOREQINTERNAL pReqInt = hReq;
219 RTFILEAIOREQ_VALID_RETURN_RC(pReqInt, NULL);
221 return pReqInt->pvUser;
226 PRTFILEAIOREQINTERNAL pReqInt = hReq;
227 RTFILEAIOREQ_VALID_RETURN(pReqInt);
228 RTFILEAIOREQ_STATE_RETURN_RC(pReqInt, SUBMITTED, VERR_FILE_AIO_NOT_SUBMITTED);
230 int rcSolaris = aio_cancel(pReqInt->AioCB.aio_fildes, &pReqInt->AioCB);
238 AssertMsg(VALID_PTR(pReqInt->pCtxInt),
241 ASMAtomicDecS32(&pReqInt->pCtxInt->cRequests);
242 RTFILEAIOREQ_SET_STATE(pReqInt, COMPLETED);
255 PRTFILEAIOREQINTERNAL pReqInt = hReq;
256 RTFILEAIOREQ_VALID_RETURN(pReqInt);
257 RTFILEAIOREQ_NOT_STATE_RETURN_RC(pReqInt, SUBMITTED, VERR_FILE_AIO_IN_PROGRESS);
258 RTFILEAIOREQ_NOT_STATE_RETURN_RC(pReqInt, PREPARED, VERR_FILE_AIO_NOT_SUBMITTED);
261 int rcSol = aio_error(&pReqInt->AioCB);
267 *pcbTransfered = aio_return(&pReqInt->AioCB);
349 PRTFILEAIOREQINTERNAL pReqInt;
353 pReqInt = pahReqs[i];
354 if (RTFILEAIOREQ_IS_NOT_VALID(pReqInt))
359 pReqInt = pahReqs[iUndo];
360 RTFILEAIOREQ_SET_STATE(pReqInt, PREPARED);
361 pReqInt->pCtxInt = NULL;
367 pReqInt->PortNotifier.portnfy_port = pCtxInt->iPort;
368 pReqInt->pCtxInt = pCtxInt;
369 RTFILEAIOREQ_SET_STATE(pReqInt, SUBMITTED);
371 if (pReqInt->fFlush)
390 pReqInt = pahReqs[i];
391 rcSol = aio_error(&pReqInt->AioCB);
395 RTFILEAIOREQ_SET_STATE(pReqInt, PREPARED);
396 pReqInt->pCtxInt = NULL;
401 RTFILEAIOREQ_SET_STATE(pReqInt, COMPLETED);
414 pReqInt = pahReqs[0];
415 RTFILEAIOREQ_VALID_RETURN(pReqInt);
422 rcSol = aio_fsync(O_SYNC, &pReqInt->AioCB);
425 RTFILEAIOREQ_SET_STATE(pReqInt, COMPLETED);
504 PRTFILEAIOREQINTERNAL pReqInt = (PRTFILEAIOREQINTERNAL)aPortEvents[i].portev_user;
505 AssertPtr(pReqInt);
506 Assert(pReqInt->u32Magic == RTFILEAIOREQ_MAGIC);
509 pahReqs[cRequestsCompleted++] = pReqInt;
512 RTFILEAIOREQ_SET_STATE(pReqInt, COMPLETED);