diff options
author | Hans Rosenfeld <hans.rosenfeld@joyent.com> | 2018-07-16 09:03:51 +0000 |
---|---|---|
committer | Patrick Mooney <pmooney@pfmooney.com> | 2020-05-22 14:27:14 +0000 |
commit | eb9a1df2aeb866bf1de4494433b6d7e5fa07b3ae (patch) | |
tree | f9cc894879d944a84aa3e16bfabc9e16a4fcaf6b /usr/src/lib/libvmmapi/common/vmmapi.h | |
parent | 3c5f2a9de9c6554ce899ad4ebf7978ea7293994a (diff) | |
download | illumos-joyent-eb9a1df2aeb866bf1de4494433b6d7e5fa07b3ae.tar.gz |
12680 want PCI pass-thru in bhyve
Portions contributed by: Patrick Mooney <patrick.mooney@joyent.com>
Portions contributed by: John Levon <john.levon@joyent.com>
Portions contributed by: Andy Fiddaman <omnios@citrus-it.co.uk>
Reviewed by: Patrick Mooney <pmooney@oxide.computer>
Approved by: Dan McDonald <danmcd@joyent.com>
Diffstat (limited to 'usr/src/lib/libvmmapi/common/vmmapi.h')
-rw-r--r-- | usr/src/lib/libvmmapi/common/vmmapi.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/usr/src/lib/libvmmapi/common/vmmapi.h b/usr/src/lib/libvmmapi/common/vmmapi.h index a1507255cb..1b08a9cae5 100644 --- a/usr/src/lib/libvmmapi/common/vmmapi.h +++ b/usr/src/lib/libvmmapi/common/vmmapi.h @@ -177,6 +177,7 @@ int vm_get_capability(struct vmctx *ctx, int vcpu, enum vm_cap_type cap, int *retval); int vm_set_capability(struct vmctx *ctx, int vcpu, enum vm_cap_type cap, int val); +#ifdef __FreeBSD__ int vm_assign_pptdev(struct vmctx *ctx, int bus, int slot, int func); int vm_unassign_pptdev(struct vmctx *ctx, int bus, int slot, int func); int vm_map_pptdev_mmio(struct vmctx *ctx, int bus, int slot, int func, @@ -186,6 +187,20 @@ int vm_setup_pptdev_msi(struct vmctx *ctx, int vcpu, int bus, int slot, int vm_setup_pptdev_msix(struct vmctx *ctx, int vcpu, int bus, int slot, int func, int idx, uint64_t addr, uint64_t msg, uint32_t vector_control); +int vm_get_pptdev_limits(struct vmctx *ctx, int bus, int slot, int func, + int *msi_limit, int *msix_limit); +#else /* __FreeBSD__ */ +int vm_assign_pptdev(struct vmctx *ctx, int pptfd); +int vm_unassign_pptdev(struct vmctx *ctx, int pptfd); +int vm_map_pptdev_mmio(struct vmctx *ctx, int pptfd, vm_paddr_t gpa, + size_t len, vm_paddr_t hpa); +int vm_setup_pptdev_msi(struct vmctx *ctx, int vcpu, int pptfd, + uint64_t addr, uint64_t msg, int numvec); +int vm_setup_pptdev_msix(struct vmctx *ctx, int vcpu, int pptfd, + int idx, uint64_t addr, uint64_t msg, uint32_t vector_control); +int vm_get_pptdev_limits(struct vmctx *ctx, int pptfd, int *msi_limit, + int *msix_limit); +#endif /* __FreeBSD__ */ int vm_get_intinfo(struct vmctx *ctx, int vcpu, uint64_t *i1, uint64_t *i2); int vm_set_intinfo(struct vmctx *ctx, int vcpu, uint64_t exit_intinfo); |