Skip to contentSkip to conversation

sedf get in XendClient API

PATCH Applied David Isaac Wolinsky 2 participants 2 messages Oct 13, 2005 – Oct 19, 2005

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 sedf get in XendClient API

Here are some patches I compiled to get sedf_get to the XendClient API... sadly, however, the current xc frontend is missing a variable (weight) and needed to be edited.

Below are my "homemade" patches (I did this since my code base is EXTREMELY old... however the code is still valid)

tools/python/xen/lowlevel/xc/xc.c
line 766

static PyObject *pyxc_sedf_domain_get(PyObject *self,
PyObject *args, PyObject *kwds)

...

- return Py_BuildValue("{s:i,s:L,s:L,s:L,s:i}",

-                         "domain",    domid,
-                         "period",    period,
-                         "slice",     slice,

- "latency", latency,
- "extratime", extratime);

+ return Py_BuildValue("{s:i,s:L,s:L,s:L,s:i,s:i}",

+                         "domain",    domid,
+                         "period",    period,
+                         "slice",     slice,

+ "latency", latency,
+ "extratime", extratime
+ "weight", weight);

tools/python/xen/xend/XendClient.py
line 351

class URL:

...

+ def xend_domain_cpu_sedf_get(self, id):
+ return self.xendPost(self.domainurl(id),
+ {'op' : 'cpu_sedf_get'})

tools/python/xen/xend/server/SrvDomain.py

class SrvDomain(SrvDir):
line 212

...

+ def op_cpu_sedf_get(self, op, req):
+ fn = FormFn(self.xd.domain_cpu_sedf_get,
+ [['dom', 'int']])
+ val = fn(req.args, {'dom': self.dom.id})
+ return val

If need be I'll supply the traditional patches....

Regards,
David Wolinsky

Applied
#1 lore raw
Quoted 3 lines · David Isaac Wolinsky

Here are some patches I compiled to get sedf_get to the XendClient API... sadly, however, the current xc frontend is missing a variable (weight) and needed to be edited.

Applied, thank you. Were you intending to stop at the XendClient level? This change does not push the sedf_get functionality all the way through to xm, and I wonder whether you intended to do so.

Ewan.