Lines Matching defs:pArea

119 int HGSMIAreaInitialize(HGSMIAREA *pArea,
126 if ( !pArea /* Check that the area: */
135 pArea->pu8Base = pu8Base;
136 pArea->offBase = offBase;
137 pArea->offLast = cbArea - HGSMIBufferMinimumSize() + offBase;
138 pArea->cbArea = cbArea;
143 void HGSMIAreaClear(HGSMIAREA *pArea)
145 if (pArea)
147 memset(pArea, 0, sizeof(*pArea));
154 HGSMIOFFSET HGSMIBufferInitializeSingle(const HGSMIAREA *pArea,
160 if ( !pArea
172 HGSMISIZE cbMaximumDataSize = pArea->offLast - pArea->offBase;
176 || (uint8_t *)pHeader < pArea->pu8Base
177 || (uint8_t *)pHeader > pArea->pu8Base + cbMaximumDataSize - u32DataSize)
182 HGSMIOFFSET offBuffer = HGSMIPointerToOffset(pArea, pHeader);
282 * @param pArea Area which supposed to contain the buffer.
286 static int hgsmiVerifyBuffer(const HGSMIAREA *pArea,
291 // offBuffer, pArea->pu8Base, pArea->cbArea, pArea->offBase, pArea->offLast));
295 if ( offBuffer < pArea->offBase
296 || offBuffer > pArea->offLast)
299 // offBuffer, pArea->offBase, pArea->offLast));
305 void *pvBuffer = HGSMIOffsetToPointer(pArea, offBuffer);
311 // LogFlowFunc(("datasize check: header.u32DataSize = 0x%x pArea->offLast - offBuffer = 0x%x\n",
312 // header.u32DataSize, pArea->offLast - offBuffer));
314 if (header.u32DataSize <= pArea->offLast - offBuffer)
340 // header.u32DataSize, pArea->offLast - offBuffer));
372 * @param pArea Area which supposed to contain the buffer.
376 int HGSMIBufferProcess(const HGSMIAREA *pArea,
380 // LogFlowFunc(("pArea %p, offBuffer 0x%x\n", pArea, offBuffer));
382 HGSMI_ASSERT_PTR_RETURN(pArea, VERR_INVALID_PARAMETER);
387 int rc = hgsmiVerifyBuffer(pArea, offBuffer, &bufferContext);
402 HGSMI_STRICT_ASSERT(RT_SUCCESS(hgsmiVerifyBuffer(pArea, offBuffer, &bufferContext)));