Re: How to pass through off-chip USB controller
Hi Binbin, Edwin,
The error Tonny got at the time was with this combination (so not the latest as of today): - HV/DM: f815415 - SOS: Clear 24030 w/ 4.14.57-69 kernel
Looking it up on Github, this is the line you’re asking for: https://github.com/projectacrn/acrn-hypervisor/blob/acrn-2018w30.4-140000p/devicemodel/hw/pci/passthrough.c#L560
And yes, that’s the one you have below
J Geoffroy
From: acrn-users@... [mailto:acrn-users@...]
On Behalf Of Wu, Binbin
Hi Tonny, static void msix_table_write(struct vmctx *ctx, int vcpu, struct passthru_dev *ptdev, uint64_t offset, int size, uint64_t data) { struct pci_vdev *dev; struct msix_table_entry *entry; uint8_t *dest8; uint16_t *dest16; uint32_t *dest32; uint64_t *dest64; size_t entry_offset; uint32_t vector_control; int index;
dev = ptdev->dev; if (offset >= dev->msix.pba_offset && offset < dev->msix.pba_offset + dev->msix.pba_size) { switch (size) { case 1: dest8 = (uint8_t *)(dev->msix.pba_page + offset - dev->msix.pba_page_offset); *dest8 = data; break; case 2: dest16 = (uint16_t *)(dev->msix.pba_page + offset - dev->msix.pba_page_offset); *dest16 = data; break; case 4: dest32 = (uint32_t *)(dev->msix.pba_page + offset - dev->msix.pba_page_offset); *dest32 = data; //is hw/pci/passthrough.c:560 this line of code? break; case 8: dest64 = (uint64_t *)(dev->msix.pba_page + offset - dev->msix.pba_page_offset); *dest64 = data; break; default: break; } return; }
|
|