|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH v4 6/6] tools/libxc: add wrapper for PHYSDEVOP_msi_set_enable
Add libxc wrapper for PHYSDEVOP_msi_set_enable introduced in
previous commit.
Signed-off-by: Marek Marczykowski-Górecki <marmarek@xxxxxxxxxxxxxxxxxxxxxx>
---
Changes in v3:
- new patch
Changes in v4:
- adjust for updated previous patch
---
tools/libxc/include/xenctrl.h | 7 +++++++
tools/libxc/xc_physdev.c | 21 +++++++++++++++++++++
2 files changed, 28 insertions(+)
diff --git a/tools/libxc/include/xenctrl.h b/tools/libxc/include/xenctrl.h
index 31cdda7..879e926 100644
--- a/tools/libxc/include/xenctrl.h
+++ b/tools/libxc/include/xenctrl.h
@@ -1639,6 +1639,13 @@ int xc_physdev_unmap_pirq(xc_interface *xch,
uint32_t domid,
int pirq);
+int xc_physdev_msi_set_enable(xc_interface *xch,
+ int seg,
+ int bus,
+ int devfn,
+ int mode,
+ int enable);
+
/*
* LOGGING AND ERROR REPORTING
*/
diff --git a/tools/libxc/xc_physdev.c b/tools/libxc/xc_physdev.c
index 460a8e7..af6116f 100644
--- a/tools/libxc/xc_physdev.c
+++ b/tools/libxc/xc_physdev.c
@@ -111,3 +111,24 @@ int xc_physdev_unmap_pirq(xc_interface *xch,
return rc;
}
+int xc_physdev_msi_set_enable(xc_interface *xch,
+ int seg,
+ int bus,
+ int devfn,
+ int mode,
+ int enable)
+{
+ int rc;
+ struct physdev_msi_set_enable op;
+
+ memset(&op, 0, sizeof(struct physdev_msi_set_enable));
+ op.seg = seg;
+ op.bus = bus;
+ op.devfn = devfn;
+ op.mode = mode;
+ op.enable = enable;
+
+ rc = do_physdev_op(xch, PHYSDEVOP_msi_set_enable, &op, sizeof(op));
+
+ return rc;
+}
--
git-series 0.9.1
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |