summaryrefslogtreecommitdiffstats
path: root/libvirt-override.c
diff options
context:
space:
mode:
Diffstat (limited to 'libvirt-override.c')
-rw-r--r--libvirt-override.c24
1 files changed, 24 insertions, 0 deletions
diff --git a/libvirt-override.c b/libvirt-override.c
index b5650e2..b020342 100644
--- a/libvirt-override.c
+++ b/libvirt-override.c
@@ -4543,6 +4543,29 @@ libvirt_virDomainSendKey(PyObject *self ATTRIBUTE_UNUSED,
return py_retval;
}
+static PyObject *
+libvirt_virDomainMigrateGetMaxSpeed(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
+ PyObject *py_retval;
+ int c_retval;
+ unsigned long bandwidth;
+ virDomainPtr domain;
+ PyObject *pyobj_domain;
+
+ if (!PyArg_ParseTuple(args, (char *)"O:virDomainMigrateGetMaxSpeed", &pyobj_domain))
+ return(NULL);
+
+ domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);
+
+ LIBVIRT_BEGIN_ALLOW_THREADS;
+ c_retval = virDomainMigrateGetMaxSpeed(domain, &bandwidth, 0);
+ LIBVIRT_END_ALLOW_THREADS;
+
+ if (c_retval < 0)
+ return VIR_PY_INT_FAIL;
+ py_retval = libvirt_ulongWrap(bandwidth);
+ return(py_retval);
+}
+
/************************************************************************
* *
* The registration stuff *
@@ -4632,6 +4655,7 @@ static PyMethodDef libvirtMethods[] = {
{(char *) "virDomainRevertToSnapshot", libvirt_virDomainRevertToSnapshot, METH_VARARGS, NULL},
{(char *) "virDomainGetBlockJobInfo", libvirt_virDomainGetBlockJobInfo, METH_VARARGS, NULL},
{(char *) "virDomainSendKey", libvirt_virDomainSendKey, METH_VARARGS, NULL},
+ {(char *) "virDomainMigrateGetMaxSpeed", libvirt_virDomainMigrateGetMaxSpeed, METH_VARARGS, NULL},
{NULL, NULL, 0, NULL}
};