Changeset 81815 in vbox for trunk/src/VBox/Devices/VirtIO
- Timestamp:
- Nov 12, 2019 6:46:14 PM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/VirtIO/Virtio_1_0.cpp
r81814 r81815 597 597 PVIRTQSTATE pVirtq = &pVirtio->virtqState[idxQueue]; 598 598 599 P VIRTIOSGSEG paSegsIn = (PVIRTIOSGSEG)RTMemAlloc(VIRTQ_MAX_SIZE * sizeof(VIRTIOSGSEG));599 PCVIRTIOSGSEG paSegsIn = (PVIRTIOSGSEG)RTMemAlloc(VIRTQ_MAX_SIZE * sizeof(VIRTIOSGSEG)); 600 600 AssertReturn(paSegsIn, VERR_NO_MEMORY); 601 601 602 P VIRTIOSGSEG paSegsOut = (PVIRTIOSGSEG)RTMemAlloc(VIRTQ_MAX_SIZE * sizeof(VIRTIOSGSEG));602 PCVIRTIOSGSEG paSegsOut = (PVIRTIOSGSEG)RTMemAlloc(VIRTQ_MAX_SIZE * sizeof(VIRTIOSGSEG)); 603 603 AssertReturn(paSegsOut, VERR_NO_MEMORY); 604 604 … … 652 652 Log3Func(("%s IN desc_idx=%u seg=%u addr=%RGp cb=%u\n", QUEUE_NAME(pVirtio, idxQueue), uDescIdx, cSegsIn, desc.GCPhysBuf, desc.cb)); 653 653 cbIn += desc.cb; 654 pSeg = &(paSegsIn[cSegsIn++]);654 pSeg = (PVIRTIOSGSEG)&(paSegsIn[cSegsIn++]); 655 655 } 656 656 else … … 658 658 Log3Func(("%s OUT desc_idx=%u seg=%u addr=%RGp cb=%u\n", QUEUE_NAME(pVirtio, idxQueue), uDescIdx, cSegsOut, desc.GCPhysBuf, desc.cb)); 659 659 cbOut += desc.cb; 660 pSeg = &(paSegsOut[cSegsOut++]);660 pSeg = (PVIRTIOSGSEG)&(paSegsOut[cSegsOut++]); 661 661 } 662 662 … … 670 670 AssertReturn(pSgPhysIn, VERR_NO_MEMORY); 671 671 672 virtioCoreSgBufInit(pSgPhysIn, (PCVIRTIOSGSEG)paSegsIn, cSegsIn);672 virtioCoreSgBufInit(pSgPhysIn, paSegsIn, cSegsIn); 673 673 674 674 PVIRTIOSGBUF pSgPhysOut = (PVIRTIOSGBUF)RTMemAllocZ(sizeof(VIRTIOSGBUF)); 675 675 AssertReturn(pSgPhysOut, VERR_NO_MEMORY); 676 676 677 virtioCoreSgBufInit(pSgPhysOut, (PCVIRTIOSGSEG)paSegsOut, cSegsOut);677 virtioCoreSgBufInit(pSgPhysOut, paSegsOut, cSegsOut); 678 678 679 679 PVIRTIO_DESC_CHAIN_T pDescChain = (PVIRTIO_DESC_CHAIN_T)RTMemAllocZ(sizeof(VIRTIO_DESC_CHAIN_T));
Note:
See TracChangeset
for help on using the changeset viewer.