Re: [PATCH v16 14/14] hw/vmapple/vmapple: Add vmapple machine type

2025-01-04 Thread Phil Dennis-Jordan
On Sat, 4 Jan 2025 at 16:15, Akihiko Odaki wrote: > On 2024/12/28 5:36, Philippe Mathieu-Daudé wrote: > > On 23/12/24 23:16, Phil Dennis-Jordan wrote: > > > >> Known issues: > >> - Keyboard and mouse/tablet input is laggy. The reason for this is > >> that macOS's XHCI driver seems to expect

Re: [PATCH v16 14/14] hw/vmapple/vmapple: Add vmapple machine type

2025-01-04 Thread Akihiko Odaki
On 2024/12/28 5:36, Philippe Mathieu-Daudé wrote: On 23/12/24 23:16, Phil Dennis-Jordan wrote: Known issues:   - Keyboard and mouse/tablet input is laggy. The reason for this is     that macOS's XHCI driver seems to expect interrupter mapping to     be disabled when MSI/MSI-X is unavailable. I

Re: [PATCH v5 1/2] memory: Update inline documentation

2025-01-04 Thread BALATON Zoltan
On Sat, 4 Jan 2025, Akihiko Odaki wrote: Do not refer to "memory region's reference count" - Now MemoryRegions do have their own reference counts, but they will not be used when their owners are not themselves. However, the documentation of memory_

[PATCH v8 1/9] hw/pci: Do not add ROM BAR for SR-IOV VF

2025-01-04 Thread Akihiko Odaki
A SR-IOV VF cannot have a ROM BAR. Co-developed-by: Yui Washizu Signed-off-by: Akihiko Odaki --- hw/pci/pci.c | 8 1 file changed, 8 insertions(+) diff --git a/hw/pci/pci.c b/hw/pci/pci.c index 8f160c0c0d8a..c4fa32dc987a 100644 --- a/hw/pci/pci.c +++ b/hw/pci/pci.c @@ -2432,6 +2432,14

[PATCH v8 2/9] hw/pci: Fix SR-IOV VF number calculation

2025-01-04 Thread Akihiko Odaki
pci_config_get_bar_addr() had a division by vf_stride. vf_stride needs to be non-zero when there are multiple VFs, but the specification does not prohibit to make it zero when there is only one VF. Do not perform the division for the first VF to avoid division by zero. Signed-off-by: Akihiko Odak

[PATCH v8 8/9] docs: Document composable SR-IOV device

2025-01-04 Thread Akihiko Odaki
Signed-off-by: Akihiko Odaki --- MAINTAINERS | 1 + docs/system/index.rst | 1 + docs/system/sriov.rst | 36 3 files changed, 38 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 38a290e9c2ce..b0821a17c4fa 100644 --- a/MAINTAINERS +++ b/M

[PATCH v8 5/9] pcie_sriov: Allow user to create SR-IOV device

2025-01-04 Thread Akihiko Odaki
A user can create a SR-IOV device by specifying the PF with the sriov-pf property of the VFs. The VFs must be added before the PF. A user-creatable VF must have PCIDeviceClass::sriov_vf_user_creatable set. Such a VF cannot refer to the PF because it is created before the PF. A PF that user-creata

[PATCH v8 7/9] virtio-net: Implement SR-IOV VF

2025-01-04 Thread Akihiko Odaki
A virtio-net device can be added as a SR-IOV VF to another virtio-pci device that will be the PF. Signed-off-by: Akihiko Odaki --- hw/virtio/virtio-net-pci.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/virtio/virtio-net-pci.c b/hw/virtio/virtio-net-pci.c index e18953ad674b..430b727ea3

[PATCH v8 0/9] virtio-net: add support for SR-IOV emulation

2025-01-04 Thread Akihiko Odaki
Based-on: <20250104-reuse-v18-0-c349eafd8...@daynix.com> ("[PATCH v18 00/14] hw/pci: SR-IOV related fixes and improvements") Introduction This series is based on the RFC series submitted by Yui Washizu[1]. See also [2] for the context. This series enables SR-I

[PATCH v8 4/9] pcie_sriov: Check PCI Express for SR-IOV PF

2025-01-04 Thread Akihiko Odaki
SR-IOV requires PCI Express. Signed-off-by: Akihiko Odaki --- hw/pci/pcie_sriov.c | 5 + 1 file changed, 5 insertions(+) diff --git a/hw/pci/pcie_sriov.c b/hw/pci/pcie_sriov.c index 109b2ebcccba..a5b546abe8bb 100644 --- a/hw/pci/pcie_sriov.c +++ b/hw/pci/pcie_sriov.c @@ -42,6 +42,11 @@ bool

[PATCH v8 9/9] pcie_sriov: Make a PCI device with user-created VF ARI-capable

2025-01-04 Thread Akihiko Odaki
Signed-off-by: Akihiko Odaki --- docs/system/sriov.rst | 3 ++- include/hw/pci/pcie_sriov.h | 7 +-- hw/pci/pcie_sriov.c | 8 +++- hw/virtio/virtio-pci.c | 16 ++-- 4 files changed, 24 insertions(+), 10 deletions(-) diff --git a/docs/system/sriov.rst b/d

[PATCH v8 3/9] pcie_sriov: Ensure PF and VF are mutually exclusive

2025-01-04 Thread Akihiko Odaki
A device cannot be a SR-IOV PF and a VF at the same time. Signed-off-by: Akihiko Odaki --- hw/pci/pcie_sriov.c | 5 + 1 file changed, 5 insertions(+) diff --git a/hw/pci/pcie_sriov.c b/hw/pci/pcie_sriov.c index 1eb4358256de..109b2ebcccba 100644 --- a/hw/pci/pcie_sriov.c +++ b/hw/pci/pcie_sr

[PATCH v8 6/9] virtio-pci: Implement SR-IOV PF

2025-01-04 Thread Akihiko Odaki
Allow user to attach SR-IOV VF to a virtio-pci PF. Signed-off-by: Akihiko Odaki --- include/hw/virtio/virtio-pci.h | 1 + hw/virtio/virtio-pci.c | 20 +++- 2 files changed, 16 insertions(+), 5 deletions(-) diff --git a/include/hw/virtio/virtio-pci.h b/include/hw/virtio/