Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
464 commits
Select commit Hold shift + click to select a range
c1cc058
fix: compute jailer cpu time without underflow
roypat Feb 10, 2025
c96a1c9
fix: stop double counting jailer time in process_startup_time_cpu_us
roypat Feb 10, 2025
0975cd4
refactor: clarify computation of jailer_cpu_time_us
roypat Feb 10, 2025
561068a
fix: fail physical counter test if phy counter reg isn't in snapshot
roypat Feb 12, 2025
d1badbb
do not fail balloon test if deflate_oom is false and guest crashes
roypat Feb 13, 2025
5cf6525
add `restart_syscall(2)` to seccomp allowlist
roypat Feb 13, 2025
d6a14fb
test: explicitly exclude `restart_syscall` from seccomp analysis
roypat Feb 13, 2025
e6ceb57
test: catch correct exception in memory.py
roypat Feb 14, 2025
5a378ce
devtool: fix permissions on .python/ after cmd_sandbox
roypat Feb 14, 2025
6521be5
test: stop printing host dmesg on test failure
roypat Feb 14, 2025
07ce762
build(deps): Bump the firecracker group with 6 updates
dependabot[bot] Feb 17, 2025
2167247
fix: handle overflow when computing mmap offset during restore
roypat Feb 18, 2025
51bbc77
fix(jailer): Make "init" in new PID NS a session leader
zulinx86 Feb 20, 2025
9af26f1
refactor: move arch specific code from vm.rs into modules
roypat Jan 29, 2025
5eaf2eb
refactor: Split `VmError` enum into arch specific versions
roypat Jan 29, 2025
de011a0
refactor: Split `struct Vm` into arch-specific structs
roypat Jan 29, 2025
add1d52
refactor: Store msrs_to_save in `struct Vm` instead of `Kvm`
roypat Jan 29, 2025
9aa8357
refactor: move vcpu creation into `struct Vm`
roypat Jan 29, 2025
d4394dd
refactor(test): use vm.create_vcpus() instead of open coding it
roypat Jan 31, 2025
73e86de
refactor(test): be more consistent in using vm-creation utilities
roypat Jan 31, 2025
56b4979
refactor: avoid an unwrap in set_kvm_memory_regions
roypat Feb 4, 2025
f9269aa
refactor: move KVM_SET_TSS_ADDR call into Vm::arch_create
roypat Feb 4, 2025
76d9095
fix: delete never constructed error enum variants
roypat Feb 7, 2025
538702b
fix(test): dont drop guest memory before using it
roypat Feb 10, 2025
15699a3
feat: AMD support larger extended function entries
JackThomson2 Jan 14, 2025
26a3a1e
doc: Update changelog
JackThomson2 Feb 19, 2025
80c5596
refactor: Rename VmError::VmFd to VmError::CreateVm
zulinx86 Feb 21, 2025
1e1d8ae
fix: Retry KVM_CREATE_VM on EINTR
zulinx86 Feb 21, 2025
a7c90b7
chore: Add CHANGELOG entry for retrying KVM_CREATE_VM on EINTR
zulinx86 Feb 24, 2025
3fb9a2a
build(deps): Bump the firecracker group with 18 updates
dependabot[bot] Feb 24, 2025
57ea620
Reduce amount of data downloaded from GitHub in resources/rebuild.sh
roypat Feb 26, 2025
9ff2c7b
fix: Add keyboard drivers to CI guest kernels
roypat Feb 26, 2025
ecad2fd
feat: add support got Graviton 4 cpu detection
ShadowCurse Feb 26, 2025
32ebbbe
feat: add Graviton 4 guest cpu features
ShadowCurse Feb 26, 2025
dd0bf86
feat: add Graviton 4 host vs guest cpu difference
ShadowCurse Feb 26, 2025
34337a6
fix formatting in fast_page_fault_helper.c
roypat Feb 27, 2025
44b4c1b
fix(test): check for mmap errors before using pointer
roypat Feb 27, 2025
0617286
fast_page_fault_helper: return 1 instead of -1 in case of error
roypat Feb 27, 2025
51167e6
fix(test): install signal mask in fast_page_fault_helper
roypat Feb 27, 2025
7e90988
refactor(test): introduce utils_uffd.py
roypat Feb 27, 2025
a8f38cb
refactor(test): make uffd_handle_paths not be a fixture
roypat Feb 27, 2025
0ec23ad
fix: do not build debug a default seccomp policy in debug binaries
Manciukic Feb 28, 2025
5890dbe
doc(seccomp): mention that debug builds don't have a default seccomp
Manciukic Feb 28, 2025
fe54515
doc(changelog): add note about empty seccomp policy in debug builds
Manciukic Mar 3, 2025
c54ecd7
chore: update CHANGELOG in preparation of 1.11 release
Manciukic Mar 3, 2025
b4cb9d3
chore: bump version to 1.12.0-dev
Manciukic Mar 3, 2025
74a5161
doc(vsock): clarify vsock support on snapshot/restore
Manciukic Mar 5, 2025
6a00728
chore(jailer): clarify main function wrapping
ShadowCurse Mar 5, 2025
020e343
refactor(jailer): use C-string literals
ShadowCurse Mar 5, 2025
8411b07
refactor(jailer): use CStr for strings
ShadowCurse Mar 5, 2025
473b07b
pvh/arch: Introduce EntryPoint struct
cperciva Oct 2, 2022
bb38ffa
pvh/arch-x86_64: Initialize vCPU regs for PVH
cperciva Oct 2, 2022
0553a6b
pvh/arch-x86_64: Write start_info to guest memory
cperciva Oct 2, 2022
9fd0e9c
test_licenses: Accept Oracle copyright
cperciva Dec 30, 2022
afa43ef
Add FreeBSD kernel+rootfs build instructions
cperciva Jul 14, 2023
d61624d
Add docs/pvh.md
cperciva Jul 14, 2023
8fe4982
CHANGELOG: Mention PVH boot mode
cperciva Jul 14, 2023
c52bde1
test: verify PVH boot protocol is used
roypat Nov 11, 2024
e904649
fix: dont hardcode "main" in gitlint test
roypat Nov 11, 2024
38a6faf
test: skip test_gitlint on PR #5048
roypat Feb 24, 2025
a24bae5
Revert "test: skip test_gitlint on PR #5048"
roypat Mar 6, 2025
8da9fc9
fix: Allow jailer to continue with partial CPU cache info
gudmundur Mar 5, 2025
83119b8
feat: add option to not add kani bk step
ShadowCurse Mar 6, 2025
ed0d202
chore: increase timeout for kani tests
ShadowCurse Mar 6, 2025
07ccd0d
refactor(jailer): proper path creation
ShadowCurse Mar 6, 2025
cc5d6b4
refactor(jailer): remove arch dependent ptr cast
ShadowCurse Mar 7, 2025
3e68863
refactor(test): stop hardcoding uffd socket path everywhere
roypat Mar 3, 2025
a7b16d0
test: have fast_page_fault_helper print time memset took
roypat Feb 27, 2025
e326b35
refactor(uffd): Make example UFFD fast in absense of balloon device
roypat Mar 3, 2025
4c362b1
refactor(test): Store binary_dir inside microvm
roypat Mar 4, 2025
3f73d03
test: replace workspace_dir arg with binary_dir in get_binary
roypat Mar 4, 2025
87ed2b3
test: pass through kwargs from uffd_handler() to get_example()
roypat Mar 4, 2025
ed4ed93
devtool: also copy example binaries when doing build --rev
roypat Mar 4, 2025
aea9a2e
fix(test): stop passing guest kernel when building vms from snapshot
roypat Mar 3, 2025
190c06a
test_snapshot_ab: rename guest_kernel_acpi to guest_kernel
roypat Mar 3, 2025
0781a3c
test: store uffd handler in microvm attribute
roypat Mar 4, 2025
271d8a8
test: Add MicroVMFactory.build_n_from_snapshot
roypat Mar 3, 2025
294841e
test: use build_n_from_snapshot to replace explicit loops
roypat Mar 3, 2025
31ee851
test_snapshot_ab: move metrics dimension setting into configure_vm
roypat Mar 3, 2025
137d413
test_snapshot_ab: start VM inside configure_vm
roypat Mar 3, 2025
8c20fd1
test_snapshot_ab: open code sample_latency
roypat Mar 3, 2025
93467bd
test: add post-restore latency test
roypat Feb 27, 2025
5ed54bf
test: Also emit post-restore latency metrics for huge pages
roypat Mar 4, 2025
e3e8769
test: Add post-restore population latency test
roypat Mar 4, 2025
1461e28
fix(ab): its dict.keys(), not dict.key()
roypat Mar 4, 2025
fbd0aa1
test(ab): allow dimensions to be split into multiple lists
roypat Mar 4, 2025
2f8228f
refactor: rename uffd_valid_handler to uffd_on_demand_handler
roypat Mar 6, 2025
fbb230a
test: avoid memsetting in favor of just touching one byte per page
roypat Mar 6, 2025
333bc2d
fix: allocate more huge pages for performance tests
roypat Mar 6, 2025
2c74c65
chore(aarch64): increase the max_value for timer reset test
ShadowCurse Mar 10, 2025
c9c90ec
fix(test): actually assert error msg in test_api_mmds_config
roypat Feb 25, 2025
a657044
test: eliminate unused variable from test_api_put_update_pre_boot
roypat Feb 25, 2025
d145cdd
fix(test): Fix io_engine related tests
roypat Feb 25, 2025
123a8da
fix(test): Catch correct ConnectionError in test_deflate_on_oom
roypat Feb 26, 2025
ee47730
test: run test_ctrl_al_del with all guest kernels
roypat Mar 7, 2025
db6d29b
fix: do not try to use put_dimensions to merge dimension sets
roypat Mar 10, 2025
402452e
feat: Generate bindings to enable Intel AMX's TILEDATA for XSAVE
zulinx86 Feb 28, 2025
d20ab91
refactor: Remove Eq and PartialEq from KvmError
zulinx86 Feb 28, 2025
d44732d
feat(vmm): Request permission for Intel AMX
zulinx86 Mar 3, 2025
803140d
feat(vmm): Use structs and methods for `KVM_CAP_XSAVE2`
zulinx86 Mar 7, 2025
60f75c2
feat(seccomp): Allow to call KVM_GET_XSAVE2
zulinx86 Mar 10, 2025
cb71cd7
test: Detect Intel Sapphire Rapids as CPU model
zulinx86 Mar 5, 2025
a667480
test: Verify Intel AMX is reported inside guest
zulinx86 Mar 10, 2025
1accef6
chore: Declare Intel AMX support in README
zulinx86 Mar 10, 2025
5277cbb
chore: Update fingerprint
JackThomson2 Mar 10, 2025
0b32062
test: Enable reset physical counter on AL
JackThomson2 Mar 10, 2025
d2db352
test: Bump physical counter comparison
JackThomson2 Mar 10, 2025
2f9fc70
build(deps): Bump the firecracker group across 1 directory with 33 up…
dependabot[bot] Mar 12, 2025
4b7abf6
fix: Clippy warnings
JackThomson2 Mar 12, 2025
cce210a
fix: Remove redundant seccomp rule
JackThomson2 Mar 12, 2025
1d98a21
Revert "fix: test_sec_audit: ignore cargo audit output"
roypat Mar 12, 2025
0debda8
devctr: pin cargo-deny to 0.17.0
roypat Mar 12, 2025
f43f4dc
chore: bump devctr version
roypat Mar 12, 2025
ba1e839
fix(doc): Avoid confusion of CPUID.(EAX=0xB,ECX=1) normalization
zulinx86 Mar 12, 2025
7c0dc1e
fix(doc): Simplify explanation of extended topology leaf
zulinx86 Mar 12, 2025
8495af9
kani: stop using deprecated cli args
roypat Mar 13, 2025
0fff2c8
buildkite: run kani if devctr is modified
roypat Mar 13, 2025
35d6afd
refactor: stop using loops in byte_order.rs
roypat Mar 13, 2025
dd0d932
kani: remove stubbing from dumbo harnesses
roypat Mar 13, 2025
1b9ba6f
test: Modernize test_send_ctrl_alt_del
roypat Feb 25, 2025
73564b7
fix: drop i8042.nopnp argument from default kernel cmdline
roypat Mar 12, 2025
91cea5e
doc: add changelog entry about fixing CTRL+ALT+DEL
roypat Mar 13, 2025
a6491d8
chore(devctr): use poetry.group.dev.dependencies
Manciukic Mar 12, 2025
fc4483f
chore(devctr): update poetry lock file
Manciukic Mar 12, 2025
ced9dfa
chore(devctr): update rust toolchain to 1.85.0
Manciukic Mar 12, 2025
9099eac
chore(clippy): fix "operator precedence can trip the unwary"
Manciukic Mar 12, 2025
b98ed6e
chore(clippy): mark packed repr ABI explicit as C
Manciukic Mar 12, 2025
5e8379f
chore(example): fix compilation warning for unused return
Manciukic Mar 12, 2025
c436548
chore(clippy): fix `map_or` can be simplified
Manciukic Mar 12, 2025
0e8ab58
chore(clippy): fix needless call to `as_bytes`
Manciukic Mar 12, 2025
7386413
chore(clippy): make pointer cast explicit
Manciukic Mar 12, 2025
b3a0d37
chore(devctr): bump to v79
Manciukic Mar 12, 2025
72b01fc
chore(clippy): remove unnecessary "ref" in match
Manciukic Mar 12, 2025
6ee0d91
chore(clippy): mark env vars set/remove as unsafe
Manciukic Mar 12, 2025
74aecaa
chore(clippy): explicitly mark unsafe calls in unsafe functions
Manciukic Mar 12, 2025
5c19583
chore(clippy): mark extern blocks as unsafe
Manciukic Mar 12, 2025
4d88845
chore(bindgen): use generated as prefix instead of gen
Manciukic Mar 12, 2025
82de14b
chore: regenerate auto-generated files in new generated/ prefix
Manciukic Mar 12, 2025
c846b99
chore: switch to Rust 2024 edition
Manciukic Mar 12, 2025
da878fb
chore: run cargo fmt on new edition
Manciukic Mar 12, 2025
6cee4a8
chore(clippy): fix unneeded late initialization
Manciukic Mar 13, 2025
e7f6051
chore: Ignore paste unmaintained warning
JackThomson2 Mar 13, 2025
0d9904c
refactor(vmm): Reorder normalization of feature info leaf
zulinx86 Mar 13, 2025
272fe8f
refactor(vmm): Use CPUID notation used in Intel SDM
zulinx86 Mar 13, 2025
3acda67
refactor(vmm): Use CPUID notation used in AMD APM
zulinx86 Mar 13, 2025
b2136d2
refactor(vmm): Remove unneeded constants
zulinx86 Mar 13, 2025
ebbf837
refactor(vmm): Refer to Intel SDM rather than Intel x2APIC spec
zulinx86 Mar 13, 2025
4a9ccd2
refactor(vmm): Update variable names and comments with SDM notation
zulinx86 Mar 13, 2025
68e7a4c
refactor(vmm): Error if subleaf >= 2 given for leaf 0xB
zulinx86 Mar 13, 2025
6220711
fix(vmm): Calc right-shift bits to address socket ID
zulinx86 Mar 13, 2025
f915b23
refactor(vmm): Better error messages for CPUID normalization
zulinx86 Mar 13, 2025
95fc34b
refactor(vmm): Bit-range manipulation with RangeInclusive
zulinx86 Mar 13, 2025
2ad0570
doc: Simplify normalized register list
zulinx86 Mar 13, 2025
9ea85d5
feat(vmm): Normalize CPUID leaf 0x1F
zulinx86 Mar 13, 2025
384a1a4
refactor: Remove unneeded turbo fish (::) in unit test
zulinx86 Mar 13, 2025
30e857b
test: Skip frequency check if host not report it
zulinx86 Mar 13, 2025
8b09bdd
test: Skip CPUID.(EAX=1FH,ECX=2) in test_cpu_config_dump_vs_actual
zulinx86 Mar 13, 2025
f1f7794
test: Skip MSR 0xE1 in test_cpu_config_dump_vs_actual
zulinx86 Mar 13, 2025
3bc126d
test: Skip MSR 0x1C4 in test_cpu_config_dump_vs_actual
zulinx86 Mar 13, 2025
f4d6aa5
test: Use any guest kernels in test_host_vs_guest_cpu_features
zulinx86 Mar 11, 2025
165b20d
test: test_host_vs_guest_cpu_features on Intel Sapphire Rapids
zulinx86 Mar 11, 2025
983a20a
test: Ignore REPTAR on Intel Sapphire Rapids
zulinx86 Mar 12, 2025
b41a64c
chore: Use Amazon Linux 2023 for per-arch step
zulinx86 Mar 14, 2025
25ba9cf
chore: Make any instances acceptable in fingerprint test
zulinx86 Mar 14, 2025
9b76935
chore: Make any platforms acceptable in CPU template test
zulinx86 Mar 14, 2025
8c60d91
chore: Add fingerprint of Intel Sapphire Rapids
zulinx86 Mar 14, 2025
36f6222
chore: Add fingerprint of AMD Genoa
zulinx86 Mar 14, 2025
3476905
chore: Add fingerprint of Graviton4
zulinx86 Mar 14, 2025
4e9b215
chore: Regather fingerprints for x86-64 instance types
zulinx86 Mar 14, 2025
200a955
Adding host device renaming for snapshot restore
andrewla Aug 14, 2024
f0d233d
Tests for snapshot network renames
andrewla Aug 14, 2024
7c7884c
Adding documentation and changelog
andrewla Aug 15, 2024
b4117e5
feat: Add m7a as a tested instance
JackThomson2 Mar 17, 2025
9d58501
test: Ignore m7a tcp throughput
JackThomson2 Mar 17, 2025
a6b0188
doc: Add AMD Genoa support to changelog
JackThomson2 Mar 17, 2025
c9fa6fe
test: Add m7a to cpu template pipeline
JackThomson2 Mar 17, 2025
431b829
doc: update FAQ to stop saying we dont have ACPI
roypat Mar 17, 2025
888c5f3
chore(doc): remove arm64 snapshot reg length limitation
ShadowCurse Mar 18, 2025
3db826f
doc: update quickstart guide to download latest artifacts
Manciukic Mar 17, 2025
b35ea23
chore(doc): clarify kernel policy and remove 4.14
Manciukic Mar 17, 2025
27c91e8
fix(release): fix release_notes.py
Manciukic Mar 17, 2025
6b8a95b
chore(release): update release policy with 1.11
Manciukic Mar 17, 2025
f40ed33
fix(changelog): move PVH to unreleased section
Manciukic Mar 17, 2025
70d6e7f
chore(credits): cherry-pick updated credits from release branch
Manciukic Mar 17, 2025
07c07bd
fix: rename page_size_kib to page_size
acsmyth Dec 6, 2024
fc85170
fix: try to make UFFD handlers more robust
bchalios Mar 19, 2025
4385509
chore: enable SVE and PAC custom template for G4
ShadowCurse Mar 19, 2025
5598322
feat(tests): test snapshot cycle restore with cpu templates
ShadowCurse Mar 19, 2025
c4a9ea9
refactor(tests): rename test_5_snapshots and reduce the number of cycles
ShadowCurse Mar 19, 2025
aa73f45
fix(tests): adjust G4 guest features with sve+pac cpu template
ShadowCurse Mar 20, 2025
69522c8
fix: sleep between retries during UFFD handler negotiation
bchalios Mar 21, 2025
fc55a48
test: increase cases for test_population_latency
bchalios Mar 21, 2025
83a9a55
doc: clarify kernel configuration usage in our repo
bchalios Mar 21, 2025
0ee10bb
refactor: move arch specific KVM code into modules
bchalios Mar 20, 2025
56c573a
chore: move KVM architecture-specific state in vmm::arch module
bchalios Mar 24, 2025
0f3e8b3
chore: move `vmm::vstate` code under `vmm::arch`
bchalios Mar 24, 2025
6b5f4b1
refactor: don't duplicate VIRTIO_F_* constants in generated modules
roypat Mar 24, 2025
c7b216f
fix: make cargo test pass with gdb feature
roypat Mar 20, 2025
ba11d47
refactor: de-generify fdt.rs
roypat Mar 21, 2025
ff8ca93
refactor: do not redefine x86 constant in test_vsock_bof
roypat Mar 24, 2025
76f1527
refactor: introduce mib_to_bytes helper
roypat Mar 21, 2025
4181e98
refactor: drop pointless .map() calls
roypat Mar 24, 2025
c52f1a7
refactor: move StartMicrovmError::AllocateResources into VmmError
roypat Mar 24, 2025
5bc902b
refactor: Have create_vmm_and_vcpus return VmmError
roypat Mar 24, 2025
83f77b3
refactor: use #[from] in VmmError
roypat Mar 24, 2025
99b7e2c
refactor: impl From<VmmError> for StartMicrovmError
roypat Mar 24, 2025
cf9e48e
test(api): exclude /snapshot/load from duration check
kalyazin Mar 24, 2025
56729e7
test(devtool): sextuple number of preallocated huge pages
kalyazin Mar 24, 2025
a6c9559
build(deps): Bump the firecracker group with 13 updates
dependabot[bot] Mar 24, 2025
2599a83
refactor: move initrd code into separate module
ShadowCurse Mar 24, 2025
97f602f
refactor: move load_kernel into arch module
ShadowCurse Mar 25, 2025
8379fcd
refactor: move configure_system_for_boot into arch module
ShadowCurse Mar 25, 2025
6fdb2b0
refactor: remove getter for guest memory from Vmm
ShadowCurse Mar 25, 2025
2971a0f
refactor: move CpuConfiguration creation into itself
ShadowCurse Mar 25, 2025
4c83038
refactor(aarch64): remove Result type from `apply_template`
ShadowCurse Mar 25, 2025
c98f801
refactor: inline `configure_system` into `configure_system_for_boot`
ShadowCurse Mar 25, 2025
6595eeb
chore: remove unused `PartialEq` impl
ShadowCurse Mar 25, 2025
03ee026
refactor: add align_up and align_down functions
ShadowCurse Mar 26, 2025
019dc6b
refactor(aarch64): add `#[from]` to the arch error enum
ShadowCurse Mar 26, 2025
3e4d837
refactor: stop caching mpidr in struct KvmVcpu
roypat Mar 26, 2025
9fc4073
refactor: move get_manufacturer_id_from_host() to regs.rs
roypat Mar 26, 2025
e0db8f7
refactor: move free functions into impl KvmVcpu block
roypat Mar 26, 2025
e94b72b
refactor: eliminate map_err from device registration in builder.rs
roypat Mar 26, 2025
f6fa622
test(conftest): move (not copy) vm artifacts
kalyazin Mar 27, 2025
c63d1ed
vmm: Disable WAITPKG
zulinx86 Mar 27, 2025
4f1b59c
test: Add waitpkg to host-minus-guest features
zulinx86 Mar 28, 2025
b38ec33
fix(vmm/persist): do not close uffd socket
kalyazin Mar 26, 2025
d28f380
fix(test): do not double copy snapshot memory in uffd tests
roypat Mar 31, 2025
85622c6
test(build_n_from_snapshot): Delete snapshot n after iteration n+2
roypat Mar 31, 2025
05e7881
remove empty line in Cargo.toml
roypat Apr 2, 2025
6fa2064
chore: update bincode to 2.0
roypat Apr 2, 2025
1f1c5c0
build(deps): Bump the firecracker group across 1 directory with 8 upd…
dependabot[bot] Apr 2, 2025
a6138aa
refactor(test): add helper function for creating mem in vhost tests
roypat Mar 27, 2025
79b67fd
refactor: Have all memory creation method take similar arguments
roypat Jan 31, 2025
6ee792a
refactor: introduce struct VmCommon
roypat Mar 21, 2025
b6fed28
refactor: move check for not exceeding memslot limit into `struct Vm`
roypat Mar 21, 2025
5b12835
refactor: store GuestMemoryMmap inside `struct Vm`
roypat Mar 21, 2025
756b769
refactor: load kernel/initrd after create_vmm_and_vcpus()
roypat Mar 21, 2025
fddc29f
refactor: build GuestMemoryMmap objects incrementally
roypat Mar 21, 2025
538357f
refactor: move GuestMemoryState into VmState
roypat Mar 25, 2025
d3f2539
refactor: move dirty bitmap functions into struct Vm
roypat Mar 26, 2025
e026e54
refactor: hoist post-snapshot vring re-dirtying
roypat Mar 26, 2025
12fa176
refactor: move snapshot_memory_to_file into struct Vm
roypat Mar 26, 2025
768440e
refactor: #[from]-ify CreateSnapshotError
roypat Mar 28, 2025
752efcb
refactor: cleanup error propagation in snapshot_emory_to_file
roypat Mar 31, 2025
ea1124e
fix: print inner error in case of PersistError::QueueConstruction
roypat Mar 28, 2025
d26fc1c
add offset argument to `arch_regions`
roypat Jan 29, 2025
85188a9
refactor: drop uffd parameter from create_vmm_and_vcpus
roypat Mar 25, 2025
5ac1442
uffd: unconditionally enable UFFD_FEATURE_EVENT_REMOVE
roypat Mar 25, 2025
45fc21b
fix(test): do not drop Vm object before end of test
roypat Mar 31, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
40 changes: 27 additions & 13 deletions .buildkite/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,28 +6,35 @@
"""

import argparse
import ast
import json
import os
import random
import string
import subprocess
from pathlib import Path

DEFAULT_INSTANCES = {
"c5n.metal": "x86_64", # Intel Skylake
"m5n.metal": "x86_64", # Intel Cascade Lake
"m6i.metal": "x86_64", # Intel Icelake
"m6a.metal": "x86_64", # AMD Milan
"m6g.metal": "aarch64", # Graviton2
"m7g.metal": "aarch64", # Graviton3
}
DEFAULT_INSTANCES = [
"c5n.metal", # Intel Skylake
"m5n.metal", # Intel Cascade Lake
"m6i.metal", # Intel Icelake
"m6a.metal", # AMD Milan
"m7a.metal-48xl", # AMD Genoa
"m6g.metal", # Graviton2
"m7g.metal", # Graviton3
]

DEFAULT_PLATFORMS = [
("al2", "linux_5.10"),
("al2023", "linux_6.1"),
]


def get_arch_for_instance(instance):
"""Return instance architecture"""
return "x86_64" if instance[2] != "g" else "aarch64"


def overlay_dict(base: dict, update: dict):
"""Overlay a dict over a base one"""
base = base.copy()
Expand Down Expand Up @@ -133,7 +140,8 @@ def __call__(self, parser, namespace, value, option_string=None):
res = getattr(namespace, self.dest, {})
key_str, val = value.split("=", maxsplit=1)
keys = key_str.split("/")
update = {keys[-1]: val}
# Interpret it as a literal iff it starts like one
update = {keys[-1]: ast.literal_eval(val) if val[0] in "[{'" else val}
for key in list(reversed(keys))[1:]:
update = {key: update}
res = overlay_dict(res, update)
Expand All @@ -145,7 +153,7 @@ def __call__(self, parser, namespace, value, option_string=None):
"--instances",
required=False,
nargs="+",
default=DEFAULT_INSTANCES.keys(),
default=DEFAULT_INSTANCES,
)
COMMON_PARSER.add_argument(
"--platforms",
Expand All @@ -171,6 +179,12 @@ def __call__(self, parser, namespace, value, option_string=None):
default=None,
type=str,
)
COMMON_PARSER.add_argument(
"--no-kani",
help="Don't add kani step",
action="store_true",
default=False,
)


def random_str(k: int):
Expand Down Expand Up @@ -243,7 +257,7 @@ def __init__(self, with_build_step=True, **kwargs):
self.per_instance = overlay_dict(per_instance, args.step_param)
self.per_arch = self.per_instance.copy()
self.per_arch["instances"] = ["m6i.metal", "m7g.metal"]
self.per_arch["platforms"] = [("al2", "linux_5.10")]
self.per_arch["platforms"] = [("al2023", "linux_6.1")]
self.binary_dir = args.binary_dir
# Build sharing
if with_build_step:
Expand Down Expand Up @@ -288,7 +302,7 @@ def _adapt_group(self, group):
step["command"] = prepend + step["command"]
if self.shared_build is not None:
step["depends_on"] = self.build_key(
DEFAULT_INSTANCES[step["agents"]["instance"]]
get_arch_for_instance(step["agents"]["instance"])
)
return group

Expand Down Expand Up @@ -323,7 +337,7 @@ def build_group_per_arch(self, label, *args, **kwargs):
if set_key:
for step in grp["steps"]:
step["key"] = self.build_key(
DEFAULT_INSTANCES[step["agents"]["instance"]]
get_arch_for_instance(step["agents"]["instance"])
)
return self.add_step(grp, depends_on_build=depends_on_build)

Expand Down
21 changes: 15 additions & 6 deletions .buildkite/pipeline_cpu_template.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

from enum import Enum

from common import DEFAULT_INSTANCES, DEFAULT_PLATFORMS, BKPipeline, group
from common import DEFAULT_PLATFORMS, BKPipeline, group


class BkStep(str, Enum):
Expand All @@ -26,16 +26,19 @@ class BkStep(str, Enum):
"tools/devtool -y test --no-build -- -m nonci -n4 --dist worksteal integration_tests/functional/test_cpu_features_x86_64.py -k 'test_cpu_rdmsr' "
],
BkStep.LABEL: "📖 rdmsr",
"instances": ["c5n.metal", "m5n.metal", "m6a.metal", "m6i.metal"],
"platforms": DEFAULT_PLATFORMS,
"instances": [
"c5n.metal",
"m5n.metal",
"m6i.metal",
"m6a.metal",
"m7a.metal-48xl",
],
},
"fingerprint": {
BkStep.COMMAND: [
"tools/devtool -y test --no-build -- -m no_block_pr integration_tests/functional/test_cpu_template_helper.py -k test_guest_cpu_config_change",
],
BkStep.LABEL: "🖐️ fingerprint",
"instances": DEFAULT_INSTANCES.keys(),
"platforms": DEFAULT_PLATFORMS,
},
"cpuid_wrmsr": {
"snapshot": {
Expand All @@ -62,7 +65,13 @@ class BkStep(str, Enum):
"c5n.metal": ["m5n.metal", "m6i.metal"],
"m6i.metal": ["m5n.metal", "c5n.metal"],
},
"instances": ["c5n.metal", "m5n.metal", "m6i.metal", "m6a.metal"],
"instances": [
"c5n.metal",
"m5n.metal",
"m6i.metal",
"m6a.metal",
"m7a.metal-48xl",
],
},
}

Expand Down
24 changes: 16 additions & 8 deletions .buildkite/pipeline_cross.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,21 @@
per_instance = pipeline.per_instance.copy()
per_instance.pop("instances")
per_instance.pop("platforms")
instances_x86_64 = ["c5n.metal", "m5n.metal", "m6i.metal", "m6a.metal"]
instances_x86_64 = [
"c5n.metal",
"m5n.metal",
"m6i.metal",
"m6a.metal",
"m7a.metal-48xl",
]
instances_aarch64 = ["m7g.metal"]
commands = [
"./tools/devtool -y sh ./tools/create_snapshot_artifact/main.py",
"mkdir -pv snapshots/{instance}_{kv}",
"sudo chown -Rc $USER: snapshot_artifacts",
"mv -v snapshot_artifacts/* snapshots/{instance}_{kv}",
"./tools/devtool -y test --no-build -- -m nonci -n4 integration_tests/functional/test_snapshot_phase1.py",
# punch holes in mem snapshot tiles and tar them so they are preserved in S3
"find test_results/test_snapshot_phase1 -type f -name mem |xargs -P4 -t -n1 fallocate -d",
"mv -v test_results/test_snapshot_phase1 snapshot_artifacts",
"mkdir -pv snapshots",
"tar cSvf snapshots/{instance}_{kv}.tar snapshot_artifacts",
]
pipeline.build_group(
"📸 create snapshots",
Expand Down Expand Up @@ -80,10 +88,10 @@
k_val = pytest_keyword_for_instance.get(dst_instance, "")
step = {
"command": [
f"buildkite-agent artifact download snapshots/{src_instance}_{src_kv}/* .",
f"mv -v snapshots/{src_instance}_{src_kv} snapshot_artifacts",
f"buildkite-agent artifact download snapshots/{src_instance}_{src_kv}.tar .",
f"tar xSvf snapshots/{src_instance}_{src_kv}.tar",
*pipeline.devtool_test(
pytest_opts=f"-m nonci {k_val} integration_tests/functional/test_snapshot_restore_cross_kernel.py",
pytest_opts=f"-m nonci -n8 --dist worksteal {k_val} integration_tests/functional/test_snapshot_restore_cross_kernel.py",
),
],
"label": f"🎬 {src_instance} {src_kv} ➡️ {dst_instance} {dst_kv}",
Expand Down
5 changes: 1 addition & 4 deletions .buildkite/pipeline_perf.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,10 +121,7 @@
# }
# will pin steps running on instances "m6i.metal" with kernel version tagged "linux_6.1"
# to a new kernel version tagged "linux_6.1-pinned"
pins = {
# TODO: Unpin when performance instability on m6i/5.10 has gone.
"linux_5.10-pinned": {"instance": "m6i.metal", "kv": "linux_5.10"},
}
pins = {}


def apply_pins(steps):
Expand Down
10 changes: 6 additions & 4 deletions .buildkite/pipeline_pr.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,16 +48,18 @@
"./tools/devtool -y make_release",
)

if not changed_files or any(
x.suffix in [".rs", ".toml", ".lock"] for x in changed_files
if not pipeline.args.no_kani and (
not changed_files
or any(x.suffix in [".rs", ".toml", ".lock"] for x in changed_files)
or any(x.parent.name == "devctr" for x in changed_files)
):
kani_grp = pipeline.build_group(
"🔍 Kani",
"./tools/devtool -y test --no-build -- ../tests/integration_tests/test_kani.py -n auto",
# Kani step default
# Kani runs fastest on m6a.metal
instances=["m6a.metal", "m7g.metal"],
platforms=[("al2", "linux_5.10")],
platforms=[("al2023", "linux_6.1")],
timeout_in_minutes=300,
**DEFAULTS_PERF,
depends_on_build=False,
Expand All @@ -76,7 +78,7 @@
pipeline.build_group(
"⚙ Functional and security 🔒",
pipeline.devtool_test(
pytest_opts="-n 8 --dist worksteal integration_tests/{{functional,security}}",
pytest_opts="-n 16 --dist worksteal integration_tests/{{functional,security}}",
),
)

Expand Down
6 changes: 6 additions & 0 deletions .cargo/audit.toml
Original file line number Diff line number Diff line change
@@ -1 +1,7 @@
[advisories]
# The `paste` dependency is transitively included via `gdbstub`.
# While the crate is archived/unmaintained, the author considers it feature-complete
# and functionally stable. gdbstub will be update once they migrate
# to an alternative solution.
# See https://github.com/daniel5151/gdbstub/issues/168
ignore = ["RUSTSEC-2024-0436"]
22 changes: 13 additions & 9 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,20 @@ Certificate of Origin and signing off your commits, please check

## PR Checklist

- [ ] I have read and understand [CONTRIBUTING.md][3].
- [ ] I have run `tools/devtool checkstyle` to verify that the PR passes the
automated style checks.
- [ ] I have described what is done in these changes, why they are needed, and
how they are solving the problem in a clear and encompassing way.
- [ ] I have updated any relevant documentation (both in code and in the docs)
in the PR.
- [ ] I have mentioned all user-facing changes in `CHANGELOG.md`.
- [ ] If a specific issue led to this PR, this PR closes the issue.
- [ ] The description of changes is clear and encompassing.
- [ ] Any required documentation changes (code and docs) are included in this
PR.
- [ ] API changes follow the [Runbook for Firecracker API changes][2].
- [ ] User-facing changes are mentioned in `CHANGELOG.md`.
- [ ] All added/changed functionality is tested.
- [ ] New `TODO`s link to an issue.
- [ ] Commits meet
[contribution quality standards](https://github.com/firecracker-microvm/firecracker/blob/main/CONTRIBUTING.md#contribution-quality-standards).
- [ ] When making API changes, I have followed the
[Runbook for Firecracker API changes][2].
- [ ] I have tested all new and changed functionalities in unit tests and/or
integration tests.
- [ ] I have linked an issue to every new `TODO`.

______________________________________________________________________

Expand Down
4 changes: 2 additions & 2 deletions .gitlint
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ line-length=72

[ignore-body-lines]
# Ignore HTTP reference links
# Ignore lines that start with 'Co-Authored-By' or with 'Signed-off-by'
regex=(^\[.+\]: http.+)|(^Co-Authored-By)|(^Signed-off-by)
# Ignore lines that start with 'Co-Authored-By', with 'Signed-off-by' or with 'Fixes'
regex=(^\[.+\]: http.+)|(^Co-Authored-By)|(^Signed-off-by)|(^Fixes:)

[ignore-by-author-name]
# Ignore certain rules for commits of which the author name matches a regex
Expand Down
Loading
Loading