#
c18c521c |
| 11-Jul-2025 |
ShengYi Hung <aokblast@FreeBSD.org> |
vmm: Support INOUT manual decode.
The inout instruction in AMD SVM requires DecodeAssist feature to decode the segment override prefix. However, without that feature, we are still able to decode by
vmm: Support INOUT manual decode.
The inout instruction in AMD SVM requires DecodeAssist feature to decode the segment override prefix. However, without that feature, we are still able to decode by fetching the instruction directly.
Approved by: markj (mentor) MFC after: 2 weeks Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D51256
show more ...
|
Revision tags: release/14.3.0-p1, release/14.2.0-p4, release/13.5.0-p2, release/14.3.0, release/13.4.0-p5, release/13.5.0-p1, release/14.2.0-p3, release/13.5.0 |
|
#
49a4838a |
| 04-Mar-2025 |
Jose Luis Duran <jlduran@FreeBSD.org> |
vmm: Emulate testb imm8,r/m8
Add support for "testb imm8,r/m8" emulation.
PR: 261940 PR: 282852 Reviewed by: markj, emaste Approved by: emaste (mentor) Obtained from: Illumos (https://www.illumos
vmm: Emulate testb imm8,r/m8
Add support for "testb imm8,r/m8" emulation.
PR: 261940 PR: 282852 Reviewed by: markj, emaste Approved by: emaste (mentor) Obtained from: Illumos (https://www.illumos.org/issues/14483) MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D49208
show more ...
|
Revision tags: release/14.2.0-p2, release/14.1.0-p8, release/13.4.0-p4 |
|
#
c76c2a19 |
| 18-Feb-2025 |
Mark Johnston <markj@FreeBSD.org> |
vmm: Consolidate code which manages guest memory regions
On all three platforms supported by vmm, we have mostly duplicated code to manage guest physical memory regions. Deduplicate much of this co
vmm: Consolidate code which manages guest memory regions
On all three platforms supported by vmm, we have mostly duplicated code to manage guest physical memory regions. Deduplicate much of this code and move it into sys/dev/vmm/vmm_mem.c.
To avoid exporting struct vm outside of machdep vmm.c, add a new struct vm_mem to contain the memory segment descriptors, and add a vm_mem() accessor, akin to vm_vmspace(). This way vmm_mem.c can implement its routines without needing to see the layout of struct vm.
The handling of the per-VM vmspace is also duplicated but will be moved to vmm_mem.c in a follow-up patch.
On amd64, move the ppt_is_mmio() check out of vm_mem_allocated() to keep the code MI, as PPT is only implemented on amd64. There are only a couple of callers, so this is not unreasonable.
No functional change intended.
Reviewed by: jhb Differential Revision: https://reviews.freebsd.org/D48270
show more ...
|
Revision tags: release/14.1.0-p7, release/14.2.0-p1, release/13.4.0-p3, release/14.2.0, release/13.4.0 |
|
#
f3754afd |
| 12-Sep-2024 |
Joshua Rogers <Joshua@Joshua.Hu> |
Remove stray whitespaces from sys/amd64/
Signed-off-by: Joshua Rogers <Joshua@Joshua.Hu> Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1418
|
Revision tags: release/14.1.0, release/13.3.0, release/14.0.0 |
|
#
685dc743 |
| 16-Aug-2023 |
Warner Losh <imp@FreeBSD.org> |
sys: Remove $FreeBSD$: one-line .c pattern
Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
|
#
95ee2897 |
| 16-Aug-2023 |
Warner Losh <imp@FreeBSD.org> |
sys: Remove $FreeBSD$: two-line .h pattern
Remove /^\s*\*\n \*\s+\$FreeBSD\$$\n/
|
#
4d846d26 |
| 10-May-2023 |
Warner Losh <imp@FreeBSD.org> |
spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSD
The SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catch up to that fact and revert to their recommended match of
spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSD
The SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catch up to that fact and revert to their recommended match of BSD-2-Clause.
Discussed with: pfg MFC After: 3 days Sponsored by: Netflix
show more ...
|
Revision tags: release/13.2.0 |
|
#
7d9ef309 |
| 24-Mar-2023 |
John Baldwin <jhb@FreeBSD.org> |
libvmmapi: Add a struct vcpu and use it in most APIs.
This replaces the 'struct vm, int vcpuid' tuple passed to most API calls and is similar to the changes recently made in vmm(4) in the kernel.
s
libvmmapi: Add a struct vcpu and use it in most APIs.
This replaces the 'struct vm, int vcpuid' tuple passed to most API calls and is similar to the changes recently made in vmm(4) in the kernel.
struct vcpu is an opaque type managed by libvmmapi. For now it stores a pointer to the VM context and an integer id.
As an immediate effect this removes the divergence between the kernel and userland for the instruction emulation code introduced by the recent vmm(4) changes.
Since this is a major change to the vmmapi API, bump VMMAPI_VERSION to 0x200 (2.0) and the shared library major version.
While here (and since the major version is bumped), remove unused vcpu argument from vm_setup_pptdev_msi*().
Add new functions vm_suspend_all_cpus() and vm_resume_all_cpus() for use by the debug server. The underyling ioctl (which uses a vcpuid of -1) remains unchanged, but the userlevel API now uses separate functions for global CPU suspend/resume.
Reviewed by: corvink, markj Differential Revision: https://reviews.freebsd.org/D38124
show more ...
|
Revision tags: release/12.4.0 |
|
#
d3956e46 |
| 18-Nov-2022 |
John Baldwin <jhb@FreeBSD.org> |
vmm: Use struct vcpu in the instruction emulation code.
This passes struct vcpu down in place of struct vm and and integer vcpu index through the in-kernel instruction emulation code. To minimize u
vmm: Use struct vcpu in the instruction emulation code.
This passes struct vcpu down in place of struct vm and and integer vcpu index through the in-kernel instruction emulation code. To minimize userland disruption, helper macros are used for the vCPU arguments passed into and through the shared instruction emulation code.
A few other APIs used by the instruction emulation code have also been updated to accept struct vcpu in the kernel including vm_get/set_register and vm_inject_fault.
Reviewed by: corvink, markj Differential Revision: https://reviews.freebsd.org/D37161
show more ...
|
#
2b4fe856 |
| 18-Nov-2022 |
John Baldwin <jhb@FreeBSD.org> |
bhyve: Remove unused vm and vcpu arguments from vm_copy routines.
The arguments identifying the VM and vCPU are only needed for vm_copy_setup.
Reviewed by: corvink, markj Differential Revision: htt
bhyve: Remove unused vm and vcpu arguments from vm_copy routines.
The arguments identifying the VM and vCPU are only needed for vm_copy_setup.
Reviewed by: corvink, markj Differential Revision: https://reviews.freebsd.org/D37158
show more ...
|
#
ed721684 |
| 23-Oct-2022 |
Mark Johnston <markj@FreeBSD.org> |
bhyve: Address some signed/unsigned comparison warnings
MFC after: 1 week
|
#
98d920d9 |
| 08-Oct-2022 |
Mark Johnston <markj@FreeBSD.org> |
bhyve: Annotate unused function parameters
MFC after: 1 week
|
Revision tags: release/13.1.0 |
|
#
d4e82073 |
| 10-Apr-2022 |
Robert Wing <rew@FreeBSD.org> |
vmm_instruction_emul.c: fix bhyve build
The __diagused macro was used to cure a "set but not used" warning. This broke the build for bhyve since __diagused is only defined in the kernel. Define __di
vmm_instruction_emul.c: fix bhyve build
The __diagused macro was used to cure a "set but not used" warning. This broke the build for bhyve since __diagused is only defined in the kernel. Define __diagused when not building the kernel.
Fixes: 5241577a223d ("vmm: fix set but not used warning") Reported by: Jenkins
show more ...
|
#
5241577a |
| 10-Apr-2022 |
Robert Wing <rew@FreeBSD.org> |
vmm: fix set but not used warning
|
Revision tags: release/12.3.0, release/13.0.0, release/12.2.0 |
|
#
e2515283 |
| 27-Aug-2020 |
Glen Barber <gjb@FreeBSD.org> |
MFH
Sponsored by: Rubicon Communications, LLC (netgate.com)
|
#
f3eb12e4 |
| 23-Aug-2020 |
Konstantin Belousov <kib@FreeBSD.org> |
Add bhyve support for LA57 guest mode.
Noted and reviewed by: grehan Sponsored by: The FreeBSD Foundation Differential revision: https://reviews.freebsd.org/D25273
|
#
4daa95f8 |
| 25-Jun-2020 |
Conrad Meyer <cem@FreeBSD.org> |
bhyve(8): For prototyping, reattempt decode in userspace
If userspace has a newer bhyve than the kernel, it may be able to decode and emulate some instructions vmm.ko is unaware of. In this scenari
bhyve(8): For prototyping, reattempt decode in userspace
If userspace has a newer bhyve than the kernel, it may be able to decode and emulate some instructions vmm.ko is unaware of. In this scenario, reset decoder state and try again.
Reviewed by: grehan Differential Revision: https://reviews.freebsd.org/D24464
show more ...
|
Revision tags: release/11.4.0 |
|
#
47332982 |
| 21-Apr-2020 |
Conrad Meyer <cem@FreeBSD.org> |
vmm(4): Decode and emulate BEXTR
Clang 10 -march=native kernels on znver1 emit BEXTR for APIC reads, apparently. Decode and emulate the instruction.
Reviewed by: grehan Differential Revision: http
vmm(4): Decode and emulate BEXTR
Clang 10 -march=native kernels on znver1 emit BEXTR for APIC reads, apparently. Decode and emulate the instruction.
Reviewed by: grehan Differential Revision: https://reviews.freebsd.org/D24463
show more ...
|
#
cfdea69d |
| 21-Apr-2020 |
Conrad Meyer <cem@FreeBSD.org> |
vmm(4): Decode 3-byte VEX-prefixed instructions
Reviewed by: grehan Differential Revision: https://reviews.freebsd.org/D24462
|
#
b645fd45 |
| 16-Apr-2020 |
Conrad Meyer <cem@FreeBSD.org> |
vmm(4): Expose instruction decode to userspace build
Permit instruction decoding logic to be compiled outside of the kernel for rapid iteration and validation.
Reviewed by: grehan Differential Revi
vmm(4): Expose instruction decode to userspace build
Permit instruction decoding logic to be compiled outside of the kernel for rapid iteration and validation.
Reviewed by: grehan Differential Revision: https://reviews.freebsd.org/D24439
show more ...
|
Revision tags: release/12.1.0, release/11.3.0 |
|
#
7f49ce7a |
| 28-Jun-2019 |
Alan Somers <asomers@FreeBSD.org> |
MFHead @349476
Sponsored by: The FreeBSD Foundation
|
#
e4da41f9 |
| 26-Jun-2019 |
Rodney W. Grimes <rgrimes@FreeBSD.org> |
Emulate the "TEST r/m{16,32,64}, imm{16,32,32}" instructions (opcode F7H).
This adds emulation for: test r/m16, imm16 test r/m32, imm32 test r/m64, imm32 sign-extended to 64
OpenBSD guests compi
Emulate the "TEST r/m{16,32,64}, imm{16,32,32}" instructions (opcode F7H).
This adds emulation for: test r/m16, imm16 test r/m32, imm32 test r/m64, imm32 sign-extended to 64
OpenBSD guests compiled with clang 8.0.0 use TEST directly against a Local APIC register instead of separate read via MOV followed by a TEST against the register.
PR: 238794 Submitted by: jhb Reported by: Jason Tubnor jason@tubnor.net Tested by: Jason Tubnor jason@tubnor.net Reviewed by: markj, Patrick Mooney patrick.mooney@joyent.com MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D20755
show more ...
|
#
7648bc9f |
| 13-May-2019 |
Alan Somers <asomers@FreeBSD.org> |
MFHead @347527
Sponsored by: The FreeBSD Foundation
|
#
c2b4cedd |
| 03-May-2019 |
John Baldwin <jhb@FreeBSD.org> |
Emulate the "ADD reg, r/m" instruction (opcode 03H).
OVMF's flash variable storage is using add instructions when indexing the variable store bootrom location.
Submitted by: D Scott Phillips <d.sco
Emulate the "ADD reg, r/m" instruction (opcode 03H).
OVMF's flash variable storage is using add instructions when indexing the variable store bootrom location.
Submitted by: D Scott Phillips <d.scott.phillips@intel.com> Reviewed by: rgrimes MFC after: 1 week Sponsored by: Intel Corporation Differential Revision: https://reviews.freebsd.org/D19975
show more ...
|
Revision tags: release/12.0.0 |
|
#
c6879c6c |
| 23-Oct-2018 |
Dimitry Andric <dim@FreeBSD.org> |
Merge ^/head r339015 through r339669.
|