[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH 3 of 8] Export xc_domain_resume to xend
# HG changeset patch # User Brendan Cully <brendan@xxxxxxxxx> # Date 1168565202 28800 # Node ID 2cdbd7c62a0efe182082317a7f4bd3fde73e925b # Parent 30e07c0e462be0d6237ac461b1fd1ba046dbe7c1 Export xc_domain_resume to xend. Signed-off-by: Brendan Cully <brendan@xxxxxxxxx> diff -r 30e07c0e462b -r 2cdbd7c62a0e tools/python/xen/lowlevel/xc/xc.c --- a/tools/python/xen/lowlevel/xc/xc.c Thu Jan 11 17:26:42 2007 -0800 +++ b/tools/python/xen/lowlevel/xc/xc.c Thu Jan 11 17:26:42 2007 -0800 @@ -160,6 +160,10 @@ static PyObject *pyxc_domain_destroy(XcO return dom_op(self, args, xc_domain_destroy); } +static PyObject *pyxc_domain_resume(XcObject *self, PyObject *args) +{ + return dom_op(self, args, xc_domain_resume); +} static PyObject *pyxc_vcpu_setaffinity(XcObject *self, PyObject *args, @@ -1027,6 +1031,13 @@ static PyMethodDef pyxc_methods[] = { METH_VARARGS, "\n" "Destroy a domain.\n" " dom [int]: Identifier of domain to be destroyed.\n\n" + "Returns: [int] 0 on success; -1 on error.\n" }, + + { "domain_resume", + (PyCFunction)pyxc_domain_resume, + METH_VARARGS, "\n" + "Resume execution of a suspended domain.\n" + " dom [int]: Identifier of domain to be resumed.\n\n" "Returns: [int] 0 on success; -1 on error.\n" }, { "vcpu_setaffinity", diff -r 30e07c0e462b -r 2cdbd7c62a0e tools/python/xen/xend/XendDomainInfo.py --- a/tools/python/xen/xend/XendDomainInfo.py Thu Jan 11 17:26:42 2007 -0800 +++ b/tools/python/xen/xend/XendDomainInfo.py Thu Jan 11 17:26:42 2007 -0800 @@ -1528,6 +1528,15 @@ class XendDomainInfo: self.cleanupDomain() + def resumeDomain(self): + log.debug("XendDomainInfo.resumeDomain(%s)", str(self.domid)) + + try: + if self.domid is not None: + xc.domain_resume(self.domid) + except: + log.exception("XendDomainInfo.resume: xc.domain_resume failed on domain %s." % (str(self.domid))) + # # Channels for xenstore and console # _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |