Skip to contentSkip to conversation

About virtio device hotplug in Q35!

Qemu-devel Zhong Yang 2 participants 3 messages Jul 24, 2017

lore
Share & tools
lore

Zhong Yang

author
#0 lore raw

Hello all,

When we did virtio device hotplug in Q35 platform, which always failed in hotplug.

Would you please tell me how to configure VM to make virtio device hotplug work in Q35 platform? Many thanks!

Regards,

Yang zhong

#1 lore raw
Quoted 2 lines · Zhong Yang

Hello all,

Hi,

Quoted 2 lines

When we did virtio device hotplug in Q35 platform, which always failed in hotplug.

Can we please see the QEMU command line and the description of the hotplug steps?

Quoted 2 lines

Would you please tell me how to configure VM to make virtio device hotplug work in Q35 platform? Many thanks!

The virtio devices can be hot-plugged into PCIe Root Ports:
HMP example:
Start the VM with several PCIe Root Ports:

   <qemu-bin> -M q35 -monitor stdio \
                     -device pcie-root-port,id=rp1 \
                     -device pcie-root port,id=rp2 \
                     ...
 Then from QEMU's hmp:
     device-add virtio-net-pci,id=n1,bus=rp1
     ...

I hope it helps,
Marcel

Quoted 5 lines

Regards,

Yang zhong

author
#2 lore raw

On Mon, Jul 24, 2017 at 08:05:54AM +0300, Marcel Apfelbaum wrote:

+ Anthony

Quoted 36 lines · Zhong Yang
Quoted 2 lines

Hello all,

Hi,

Quoted 2 lines

When we did virtio device hotplug in Q35 platform, which always failed in hotplug.

Can we please see the QEMU command line and the description of the hotplug steps?

Quoted 2 lines

Would you please tell me how to configure VM to make virtio device hotplug work in Q35 platform? Many thanks!

The virtio devices can be hot-plugged into PCIe Root Ports:
HMP example:
Start the VM with several PCIe Root Ports:

   <qemu-bin> -M q35 -monitor stdio \
                     -device pcie-root-port,id=rp1 \
                     -device pcie-root port,id=rp2 \
                     ...
 Then from QEMU's hmp:
     device-add virtio-net-pci,id=n1,bus=rp1
     ...

I hope it helps,
Marcel

Quoted 5 lines

Regards,

Yang zhong