diff mbox series

[1/2] qdev: Document qbus_realize() and qbus_unrealize()

Message ID 20200920114416.353277-2-f4bug@amsat.org
State New
Headers show
Series qdev: Let BusRealize() return a boolean value to indicate error | expand

Commit Message

Philippe Mathieu-Daudé Sept. 20, 2020, 11:44 a.m. UTC
Add some documentation for the qbus_realize() and qbus_unrealize()
functions introduced in commit 9940b2cfbc0.

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
 include/hw/qdev-core.h | 12 ++++++++++++
 1 file changed, 12 insertions(+)
diff mbox series

Patch

diff --git a/include/hw/qdev-core.h b/include/hw/qdev-core.h
index e025ba9653f..02ac1c50b7f 100644
--- a/include/hw/qdev-core.h
+++ b/include/hw/qdev-core.h
@@ -675,7 +675,19 @@  typedef int (qdev_walkerfn)(DeviceState *dev, void *opaque);
 void qbus_create_inplace(void *bus, size_t size, const char *typename,
                          DeviceState *parent, const char *name);
 BusState *qbus_create(const char *typename, DeviceState *parent, const char *name);
+/**
+ * qbus_realize: Realize a bus
+ * @bus: bus to realize
+ * @errp: pointer to error object
+ *
+ * On success, return true.
+ * On failure, store an error through @errp and return false.
+ */
 bool qbus_realize(BusState *bus, Error **errp);
+/**
+ * qbus_realize: Unrealize a bus
+ * @bus: bus to unrealize
+ */
 void qbus_unrealize(BusState *bus);
 
 /* Returns > 0 if either devfn or busfn skip walk somewhere in cursion,