firecracker
firecracker copied to clipboard
Use u32 to describe vsock related buffer sizes
Move to u32 for vsock module. We can translate from u32 to usize as needed.
Changes
- Change VsockConnection::peer_avail_credit to return u32
- Change VsockPacket::{buf_size, read_at_offset_from, write_from_offset_to} parameters & return types to u32
- Change IoVecBuffer[Mut]::{read,write}_volatile_at to u32
Closes https://github.com/firecracker-microvm/firecracker/issues/4627
Reason
Follow-up to https://github.com/firecracker-microvm/firecracker/pull/4556.
License Acceptance
By submitting this pull request, I confirm that my contribution is made under
the terms of the Apache 2.0 license. For more information on following Developer
Certificate of Origin and signing off your commits, please check
CONTRIBUTING.md.
PR Checklist
- [x] If a specific issue led to this PR, this PR closes the issue.
- [x] The description of changes is clear and encompassing.
- [x] Any required documentation changes (code and docs) are included in this PR.
- [x] API changes follow the Runbook for Firecracker API changes.
- [x] User-facing changes are mentioned in
CHANGELOG.md. - [x] All added/changed functionality is tested.
- [x] New
TODOs link to an issue. - [x] Commits meet contribution quality standards.
- [x] This functionality cannot be added in
rust-vmm.
Codecov Report
Attention: Patch coverage is 96.87500% with 2 lines in your changes missing coverage. Please review.
Project coverage is 82.08%. Comparing base (
8f0dcb1) to head (d514899). Report is 302 commits behind head on main.
| Files with missing lines | Patch % | Lines |
|---|---|---|
| src/vmm/src/devices/virtio/iovec.rs | 94.73% | 2 Missing :warning: |
Additional details and impacted files
@@ Coverage Diff @@
## main #4637 +/- ##
=======================================
Coverage 82.08% 82.08%
=======================================
Files 255 255
Lines 31257 31262 +5
=======================================
+ Hits 25656 25661 +5
Misses 5601 5601
| Flag | Coverage Δ | |
|---|---|---|
| 4.14-c5n.metal | 79.57% <96.87%> (+<0.01%) |
:arrow_up: |
| 4.14-c7g.metal | ? |
|
| 4.14-m5n.metal | 79.56% <96.87%> (+<0.01%) |
:arrow_up: |
| 4.14-m6a.metal | 78.78% <96.87%> (+<0.01%) |
:arrow_up: |
| 4.14-m6g.metal | 76.60% <96.87%> (+<0.01%) |
:arrow_up: |
| 4.14-m6i.metal | 79.55% <96.87%> (-0.01%) |
:arrow_down: |
| 4.14-m7g.metal | 76.60% <96.87%> (+<0.01%) |
:arrow_up: |
| 5.10-c5n.metal | 82.09% <96.87%> (+<0.01%) |
:arrow_up: |
| 5.10-c7g.metal | ? |
|
| 5.10-m5n.metal | 82.08% <96.87%> (+<0.01%) |
:arrow_up: |
| 5.10-m6a.metal | 81.38% <96.87%> (-0.01%) |
:arrow_down: |
| 5.10-m6g.metal | 79.38% <96.87%> (+<0.01%) |
:arrow_up: |
| 5.10-m6i.metal | 82.07% <96.87%> (-0.01%) |
:arrow_down: |
| 5.10-m7g.metal | 79.38% <96.87%> (+<0.01%) |
:arrow_up: |
| 6.1-c5n.metal | 82.08% <96.87%> (-0.01%) |
:arrow_down: |
| 6.1-c7g.metal | ? |
|
| 6.1-m5n.metal | 82.08% <96.87%> (+0.01%) |
:arrow_up: |
| 6.1-m6a.metal | 81.38% <96.87%> (+<0.01%) |
:arrow_up: |
| 6.1-m6g.metal | 79.37% <96.87%> (-0.01%) |
:arrow_down: |
| 6.1-m6i.metal | 82.07% <96.87%> (-0.01%) |
:arrow_down: |
| 6.1-m7g.metal | 79.38% <96.87%> (+<0.01%) |
:arrow_up: |
Flags with carried forward coverage won't be shown. Click here to find out more.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Subsumed by #4788