Wei Liu
57e9b80123
vmm: provide oem_strings option
...
Signed-off-by: Wei Liu <liuwe@microsoft.com>
2022-08-08 08:59:19 +01:00
Wei Liu
964985bb5c
arch: provide OEM strings entry support in SMBIOS
...
Signed-off-by: Wei Liu <liuwe@microsoft.com>
2022-08-08 08:59:19 +01:00
Wei Liu
cb18edb535
arch: return the correct size for SMBIOS occupied space
...
The original value didn't include the size of the entry point structure.
The caused the last entry to be corrupted by other code.
Signed-off-by: Wei Liu <liuwe@microsoft.com>
2022-08-05 16:34:20 +01:00
Wei Liu
05e0daa411
arch: fix end of table entry in smbios
...
Previously the code used the SmbiosSysInfo structure for that purpose.
Handle 0x0003, DMI type 127, 27 bytes
<TRUNCATED>
Wrong DMI structures length: 130 bytes announced, structures occupy 131 bytes.
Fix this by using the correct structure and padding.
Signed-off-by: Wei Liu <liuwe@microsoft.com>
2022-08-05 16:34:20 +01:00
Wei Liu
a62b611659
arch: improve some structures in smbios code
...
There is no need to manually implement Clone for some structures.
It is better to explicitly spell out repr(C) to avoid the compiler
reordering the fields.
Signed-off-by: Wei Liu <liuwe@microsoft.com>
2022-08-05 16:34:20 +01:00
Rob Bradford
3df8c6fd3b
deps: Bulk upgrade dependencies
...
Some dependencies are not tracking the latest version in the .toml file
so update all dependencies to the latest version.
Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2022-08-04 18:53:33 +01:00
dependabot[bot]
a3bb459bff
build: bump thiserror from 1.0.31 to 1.0.32
...
Bumps [thiserror](https://github.com/dtolnay/thiserror ) from 1.0.31 to 1.0.32.
- [Release notes](https://github.com/dtolnay/thiserror/releases )
- [Commits](https://github.com/dtolnay/thiserror/compare/1.0.31...1.0.32 )
---
updated-dependencies:
- dependency-name: thiserror
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2022-08-04 15:27:08 +00:00
dependabot[bot]
bb444f3e7c
build: bump libc from 0.2.126 to 0.2.127
...
Bumps [libc](https://github.com/rust-lang/libc ) from 0.2.126 to 0.2.127.
- [Release notes](https://github.com/rust-lang/libc/releases )
- [Commits](https://github.com/rust-lang/libc/compare/0.2.126...0.2.127 )
---
updated-dependencies:
- dependency-name: libc
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2022-08-04 10:39:47 +00:00
dependabot[bot]
4052a89268
build: bump serde from 1.0.141 to 1.0.142
...
Bumps [serde](https://github.com/serde-rs/serde ) from 1.0.141 to 1.0.142.
- [Release notes](https://github.com/serde-rs/serde/releases )
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.141...v1.0.142 )
---
updated-dependencies:
- dependency-name: serde
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2022-08-04 09:06:58 +00:00
lizhaoxin1
bc3a276b43
arch, vmm: Expose platform uuid via SMBIOS
...
Parse and set uuid.
Signed-off-by: lizhaoxin1 <Lxiaoyouling@163.com>
Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2022-08-04 09:20:06 +02:00
dependabot[bot]
487458c9f8
build: bump anyhow from 1.0.58 to 1.0.59
...
Bumps [anyhow](https://github.com/dtolnay/anyhow ) from 1.0.58 to 1.0.59.
- [Release notes](https://github.com/dtolnay/anyhow/releases )
- [Commits](https://github.com/dtolnay/anyhow/compare/1.0.58...1.0.59 )
---
updated-dependencies:
- dependency-name: anyhow
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2022-08-03 00:05:18 +00:00
dependabot[bot]
5f539e429a
build: bump serde from 1.0.140 to 1.0.141
...
Bumps [serde](https://github.com/serde-rs/serde ) from 1.0.140 to 1.0.141.
- [Release notes](https://github.com/serde-rs/serde/releases )
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.140...v1.0.141 )
---
updated-dependencies:
- dependency-name: serde
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2022-08-02 01:06:45 +00:00
Michael Zhao
7199119bb2
hypervisor: Remove Vcpu::read_mpidr()
on AArch64
...
Replaced `read_mpidr()` with `get_sys_reg()`.
Signed-off-by: Michael Zhao <michael.zhao@arm.com>
2022-07-29 11:45:12 +01:00
Michael Zhao
ecb66b5e94
arch: Declare system registers on AArch64
...
Signed-off-by: Michael Zhao <michael.zhao@arm.com>
2022-07-29 11:45:12 +01:00
Wei Liu
2afd0e626a
tree-wide: drop unneeded dependencies
...
Signed-off-by: Wei Liu <liuwe@microsoft.com>
2022-07-22 22:29:49 +01:00
Wei Liu
ff7773044c
tree-wide: drop some unneeded allow clauses
...
Signed-off-by: Wei Liu <liuwe@microsoft.com>
2022-07-22 14:37:03 +01:00
dependabot[bot]
269b78ca0f
build: bump serde from 1.0.139 to 1.0.140
...
Bumps [serde](https://github.com/serde-rs/serde ) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/serde/releases )
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.139...v1.0.140 )
---
updated-dependencies:
- dependency-name: serde
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2022-07-21 13:17:32 +00:00
dependabot[bot]
b440cb7d23
build: bump vmm-sys-util from 0.9.0 to 0.10.0
...
This patch requires the vhost-user-backend crate to be bumped from 0.5.0
to 0.5.1.
Bumps [vmm-sys-util](https://github.com/rust-vmm/vmm-sys-util ) from 0.9.0 to 0.10.0.
- [Release notes](https://github.com/rust-vmm/vmm-sys-util/releases )
- [Changelog](https://github.com/rust-vmm/vmm-sys-util/blob/main/CHANGELOG.md )
- [Commits](https://github.com/rust-vmm/vmm-sys-util/compare/v0.9.0...v0.10.0 )
---
updated-dependencies:
- dependency-name: vmm-sys-util
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
2022-07-20 09:40:28 +00:00
Wei Liu
05e5106b9b
hypervisor x86: provide a generic LapicState structure
...
This requires making get/set_lapic_reg part of the type.
For the moment we cannot provide a default variant for the new type,
because picking one will be wrong for the other hypervisor, so I just
drop the test cases that requires LapicState::default().
Signed-off-by: Wei Liu <liuwe@microsoft.com>
2022-07-19 09:38:38 +01:00
Wei Liu
6a8c0fc887
hypervisor: provide a generic FpuState structure
...
Signed-off-by: Wei Liu <liuwe@microsoft.com>
2022-07-18 22:15:30 +01:00
Wei Liu
08135fa085
hypervisor: provide a generic CpudIdEntry structure
...
Signed-off-by: Wei Liu <liuwe@microsoft.com>
2022-07-18 22:15:30 +01:00
Wei Liu
45fbf840db
hypervisor, vmm: move away from CpuId type
...
CpuId is an alias type for the flexible array structure type over
CpuIdEntry. The type itself and the type of the element in the array
portion are tied to the underlying hypervisor.
Switch to using CpuIdEntry slice or vector directly. The construction of
CpuId type is left to hypervisors.
This allows us to decouple CpuIdEntry from hypervisors more easily.
No functional change intended.
Signed-off-by: Wei Liu <liuwe@microsoft.com>
2022-07-18 22:15:30 +01:00
Wei Liu
f1ab86fecb
hypervisor: x86: provide a generic SpecialRegisters structure
...
Signed-off-by: Wei Liu <liuwe@microsoft.com>
2022-07-15 10:21:43 +01:00
Wei Liu
75797827d5
hypervisor: x86: provide a generic SegmentRegister structure
...
And drop SegmentRegisterOps since it is no longer required.
Signed-off-by: Wei Liu <liuwe@microsoft.com>
2022-07-15 10:21:43 +01:00
Wei Liu
8b7781e267
hypervisor: x86: provide a generic StandardRegisters structure
...
We only need to do this for x86 since MSHV does not have aarch64 support
yet. This reduces unnecessary code churn.
Signed-off-by: Wei Liu <liuwe@microsoft.com>
2022-07-15 10:21:43 +01:00
dependabot[bot]
a99c33ccfa
build: bump serde from 1.0.138 to 1.0.139
...
Bumps [serde](https://github.com/serde-rs/serde ) from 1.0.138 to 1.0.139.
- [Release notes](https://github.com/serde-rs/serde/releases )
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.138...v1.0.139 )
---
updated-dependencies:
- dependency-name: serde
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2022-07-11 23:54:20 +00:00
Wei Liu
84bbaf06d1
hypervisor: turn boot_msr_entries into a trait method
...
This allows dispatching to either KVM or MSHV automatically.
No functional change.
Signed-off-by: Wei Liu <liuwe@microsoft.com>
2022-07-08 16:49:58 +01:00
dependabot[bot]
4f611c8654
build: bump serde from 1.0.137 to 1.0.138
...
Bumps [serde](https://github.com/serde-rs/serde ) from 1.0.137 to 1.0.138.
- [Release notes](https://github.com/serde-rs/serde/releases )
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.137...v1.0.138 )
---
updated-dependencies:
- dependency-name: serde
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2022-07-06 00:56:48 +00:00
Rob Bradford
2716bc3311
build: Fix beta clippy issue (derive_partial_eq_without_eq)
...
warning: you are deriving `PartialEq` and can implement `Eq`
--> vmm/src/serial_manager.rs:59:30
|
59 | #[derive(Debug, Clone, Copy, PartialEq)]
| ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2022-06-30 20:50:45 +01:00
dependabot[bot]
eb55d0809e
build: bump anyhow from 1.0.57 to 1.0.58
...
Bumps [anyhow](https://github.com/dtolnay/anyhow ) from 1.0.57 to 1.0.58.
- [Release notes](https://github.com/dtolnay/anyhow/releases )
- [Commits](https://github.com/dtolnay/anyhow/compare/1.0.57...1.0.58 )
---
updated-dependencies:
- dependency-name: anyhow
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2022-06-21 00:46:25 +00:00
Michael Zhao
a7a15d56dd
aarch64: Move setup_regs
to hypervisor
...
`setup_regs` of AArch64 calls KVM sepecific code. Now move it to
`hypervisor` crate.
Signed-off-by: Michael Zhao <michael.zhao@arm.com>
2022-06-06 11:07:46 +01:00
Michael Zhao
957d3a7443
aarch64: Simplify GIC related structs definition
...
Combined the `GicDevice` struct in `arch` crate and the `Gic` struct in
`devices` crate.
After moving the KVM specific code for GIC in `arch`, a very thin wapper
layer `GicDevice` was left in `arch` crate. It is easy to combine it
with the `Gic` in `devices` crate.
Signed-off-by: Michael Zhao <michael.zhao@arm.com>
2022-06-06 10:17:26 +08:00
Michael Zhao
04949755c0
arch: Switch to new GIC interface
...
Signed-off-by: Michael Zhao <michael.zhao@arm.com>
2022-06-06 10:17:26 +08:00
Michael Zhao
b8dbb26647
hypervisor: Refactor save_pending_tables
of Vgic
...
Signed-off-by: Michael Zhao <michael.zhao@arm.com>
2022-06-06 10:17:26 +08:00
Michael Zhao
0fd6521759
aarch64: Avoid depending on layout
in GIC code
...
Removing the dependency on `layout` helps moving GIC code into
`hypervisor` crate.
Signed-off-by: Michael Zhao <michael.zhao@arm.com>
2022-05-27 10:57:50 +08:00
Michael Zhao
4a2d3cb4f5
aarch64: Refactor KvmGicV3Its::new()
...
Signed-off-by: Michael Zhao <michael.zhao@arm.com>
2022-05-27 10:57:50 +08:00
Michael Zhao
3fe20cc09a
aarch64: Remove GicDevice
trait
...
`GicDevice` trait was defined for the common part of GicV3 and ITS.
Now that the standalone GicV3 do not exist, `GicDevice` is not needed.
Signed-off-by: Michael Zhao <michael.zhao@arm.com>
2022-05-27 10:57:50 +08:00
Michael Zhao
fd581b1afb
aarch64: Combine the code of GicV3 and GicV3Its
...
Why combine:
- GicV3 is not required alone
- GicV3 and GicV3Its has separate snapshot/pause code. But the code of
GicV3 was never used.
- Reduce the code complexity of GIC related traits and structs.
Signed-off-by: Michael Zhao <michael.zhao@arm.com>
2022-05-27 10:57:50 +08:00
Michael Zhao
1e732bf532
aarch64: Remove versionize
& versionize_derive
...
Remove the not-mandatory dependencies in gic source code.
Signed-off-by: Michael Zhao <michael.zhao@arm.com>
2022-05-27 10:57:50 +08:00
dependabot[bot]
0e16ffbcff
build: bump libc from 0.2.125 to 0.2.126
...
Bumps [libc](https://github.com/rust-lang/libc ) from 0.2.125 to 0.2.126.
- [Release notes](https://github.com/rust-lang/libc/releases )
- [Commits](https://github.com/rust-lang/libc/compare/0.2.125...0.2.126 )
---
updated-dependencies:
- dependency-name: libc
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2022-05-18 07:14:37 +00:00
Maksym Pavlenko
3a0429c998
cargo: Clean up serde dependencies
...
There is no need to include serde_derive separately,
as it can be specified as serde feature instead.
Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com>
2022-05-18 08:21:19 +02:00
dependabot[bot]
7db7410920
build: bump virtio-queue from 0.2.0 to 0.3.0
...
Bumps [virtio-queue](https://github.com/rust-vmm/vm-virtio ) from 0.2.0 to 0.3.0.
- [Release notes](https://github.com/rust-vmm/vm-virtio/releases )
- [Commits](https://github.com/rust-vmm/vm-virtio/compare/virtio-queue-v0.2.0...virtio-queue-v0.3.0 )
Also relies on main branch from vhost-user-backend since it moved to
virtio-queue 0.3.0 as well, and without this change it wouldn't compile.
---
updated-dependencies:
- dependency-name: virtio-queue
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
2022-05-16 11:47:20 +02:00
Rob Bradford
12f11b5619
arch: x86_64: Remove glob import from hypervisor regs module
...
Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2022-05-13 15:39:22 +02:00
Rob Bradford
2caf5e3b2b
arch: Use more descriptive name for hypervisor::Vcpu than fd
...
This variable name is residual from when these functions acted directly
on the vCPU fd rather than the hypervisor wrapper.
Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2022-05-13 15:39:22 +02:00
Rob Bradford
cd0df05808
vmm, arch: CpuId is x86_64 specific so import from the x86_64 module
...
It will be removed as a top-level export from the hypervisor crate.
Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2022-05-13 15:39:22 +02:00
dependabot[bot]
30e06eaaba
build: bump log from 0.4.16 to 0.4.17
...
Bumps [log](https://github.com/rust-lang/log ) from 0.4.16 to 0.4.17.
- [Release notes](https://github.com/rust-lang/log/releases )
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md )
- [Commits](https://github.com/rust-lang/log/commits/0.4.17 )
---
updated-dependencies:
- dependency-name: log
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2022-05-03 01:00:20 +00:00
dependabot[bot]
960a9e0ff7
build: bump libc from 0.2.124 to 0.2.125
...
Bumps [libc](https://github.com/rust-lang/libc ) from 0.2.124 to 0.2.125.
- [Release notes](https://github.com/rust-lang/libc/releases )
- [Commits](https://github.com/rust-lang/libc/compare/0.2.124...0.2.125 )
---
updated-dependencies:
- dependency-name: libc
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2022-05-02 18:15:25 +00:00
dependabot[bot]
3277c27e0d
build: bump serde_derive from 1.0.136 to 1.0.137
...
Bumps [serde_derive](https://github.com/serde-rs/serde ) from 1.0.136 to 1.0.137.
- [Release notes](https://github.com/serde-rs/serde/releases )
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.136...v1.0.137 )
---
updated-dependencies:
- dependency-name: serde_derive
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2022-05-02 17:27:47 +00:00
dependabot[bot]
691d9b16db
build: bump serde from 1.0.136 to 1.0.137
...
Bumps [serde](https://github.com/serde-rs/serde ) from 1.0.136 to 1.0.137.
- [Release notes](https://github.com/serde-rs/serde/releases )
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.136...v1.0.137 )
---
updated-dependencies:
- dependency-name: serde
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2022-05-02 15:52:41 +00:00
dependabot[bot]
b60e6f7cb1
build: bump thiserror from 1.0.30 to 1.0.31
...
Bumps [thiserror](https://github.com/dtolnay/thiserror ) from 1.0.30 to 1.0.31.
- [Release notes](https://github.com/dtolnay/thiserror/releases )
- [Commits](https://github.com/dtolnay/thiserror/compare/1.0.30...1.0.31 )
---
updated-dependencies:
- dependency-name: thiserror
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2022-05-02 09:53:42 +00:00