diff --git a/tools/ocaml/libs/xl/xl_stubs.c b/tools/ocaml/libs/xl/xl_stubs.c index 33302b7fd9..3f7420f1bb 100644 --- a/tools/ocaml/libs/xl/xl_stubs.c +++ b/tools/ocaml/libs/xl/xl_stubs.c @@ -638,7 +638,7 @@ value stub_xl_pci_remove(value info, value domid) device_pci_val(&gc, &c_info, info); INIT_CTX(); - ret = libxl_device_pci_remove(&ctx, Int_val(domid), &c_info); + ret = libxl_device_pci_remove(&ctx, Int_val(domid), &c_info, 0); if (ret != 0) failwith_xl("pci_remove", &lg); FREE_CTX(); diff --git a/tools/python/xen/lowlevel/xl/xl.c b/tools/python/xen/lowlevel/xl/xl.c index a0d5a06eb8..6ac2cc42ff 100644 --- a/tools/python/xen/lowlevel/xl/xl.c +++ b/tools/python/xen/lowlevel/xl/xl.c @@ -441,15 +441,16 @@ static PyObject *pyxl_pci_del(XlObject *self, PyObject *args) { Py_device_pci *pci; PyObject *obj; - int domid; - if ( !PyArg_ParseTuple(args, "iO", &domid, &obj) ) + int domid, force = 0; + + if ( !PyArg_ParseTuple(args, "iO|i", &domid, &obj, &force) ) return NULL; if ( !Pydevice_pci_Check(obj) ) { PyErr_SetString(PyExc_TypeError, "Xxpected xl.device_pci"); return NULL; } pci = (Py_device_pci *)obj; - if ( libxl_device_pci_remove(&self->ctx, domid, &pci->obj) ) { + if ( libxl_device_pci_remove(&self->ctx, domid, &pci->obj, force) ) { PyErr_SetString(xl_error_obj, "cannot remove pci device"); return NULL; }