]> www.infradead.org Git - users/dwmw2/qemu.git/commitdiff
monitor: Convert do_pci_device_hot_remove() to QObject
authorLuiz Capitulino <lcapitulino@redhat.com>
Fri, 16 Oct 2009 15:23:48 +0000 (12:23 -0300)
committerAnthony Liguori <aliguori@us.ibm.com>
Tue, 27 Oct 2009 17:28:57 +0000 (12:28 -0500)
Errors are still directly printed, as we are only converting
regular output.

Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
hw/pci-hotplug.c
qemu-monitor.hx
sysemu.h

index 8a125c90d8ee45baab65093bdceb55d6543255c8..15a2dfb6d956b9d9866b94c0a19d6413e7b1dc18 100644 (file)
@@ -265,7 +265,8 @@ void pci_device_hot_remove(Monitor *mon, const char *pci_addr)
     qdev_unplug(&d->qdev);
 }
 
-void do_pci_device_hot_remove(Monitor *mon, const QDict *qdict)
+void do_pci_device_hot_remove(Monitor *mon, const QDict *qdict,
+                              QObject **ret_data)
 {
     pci_device_hot_remove(mon, qdict_get_str(qdict, "pci_addr"));
 }
index 41fbfd374eeef3811bed2b6d272003182037df67..4610ad4c00c11b2c7fd7ac92eeb6759148b66f23 100644 (file)
@@ -816,7 +816,8 @@ ETEXI
         .args_type  = "pci_addr:s",
         .params     = "[[<domain>:]<bus>:]<slot>",
         .help       = "hot remove PCI device",
-        .mhandler.cmd = do_pci_device_hot_remove,
+        .user_print = monitor_user_noop,
+        .mhandler.cmd_new = do_pci_device_hot_remove,
     },
 #endif
 
index cda58486b8aaafdab854fd644e65c6562eed3f19..17af0242a0dfb8a5f5ecc24d8a3dc381e36a70ab 100644 (file)
--- a/sysemu.h
+++ b/sysemu.h
@@ -208,7 +208,8 @@ DriveInfo *add_init_drive(const char *opts);
 void pci_device_hot_add(Monitor *mon, const QDict *qdict);
 void drive_hot_add(Monitor *mon, const QDict *qdict);
 void pci_device_hot_remove(Monitor *mon, const char *pci_addr);
-void do_pci_device_hot_remove(Monitor *mon, const QDict *qdict);
+void do_pci_device_hot_remove(Monitor *mon, const QDict *qdict,
+                              QObject **ret_data);
 
 /* serial ports */