qdev-ify device assignment
commit6b5bbd04ed7b157ebd6b52d5fa45224db840e150
authorGerd Hoffmann <kraxel@redhat.com>
Tue, 6 Oct 2009 14:13:04 +0000 (6 16:13 +0200)
committerAvi Kivity <avi@redhat.com>
Thu, 8 Oct 2009 13:26:48 +0000 (8 15:26 +0200)
tree238de8f41f714ebe4b12914cf688a3bc5d331f7c
parent1536fc28ae1954e2990c3ee14b4a92624ecfcb68
qdev-ify device assignment

Also cleanup while being at it.  Changes:

  * Converted driver to qdev, named it 'pci-assign'.
  * Killed the pointless AssignedDevInfo struct.
  * Killed a bunch of hooks which are not needed any more now
    that qdev can handle hotplug.

qdev way of doing device assignment is:

  -device pci-assign,host=<hostaddr>,addr=<guestaddr>,id=<name>

Hotplug via monitor:

  device_add $same_syntax_as_above
  device_del $id

Old command line + monitor syntax continues to work.  Mixing
pci_* and device_* monitor commands works too.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Avi Kivity <avi@redhat.com>
hw/device-assignment.c
hw/device-assignment.h
hw/pci-hotplug.c