-
Notifications
You must be signed in to change notification settings - Fork 2.1k
fix(test): Handle CPU feature diff between host and guest correctly #4900
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #4900 +/- ##
=======================================
Coverage 84.10% 84.10%
=======================================
Files 251 251
Lines 28080 28080
=======================================
Hits 23616 23616
Misses 4464 4464
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
f05347d
to
46ce60d
Compare
pb8o
reviewed
Nov 7, 2024
tests/integration_tests/functional/test_cpu_features_aarch64.py
Outdated
Show resolved
Hide resolved
a54a2cc
to
b276fc1
Compare
Linux kernel should hide "ssbs" since Neoverse-N1 and Neoverse-V1 have an errata whereby an MSR to the SSBS special-purpose register does not affect subsequent speculative instructions, permitting speculative store bypassing for a window of time. Although Amazon Linux host kernels (v5.10 and v6.1) backported it, the guest kernels (v5.10 and v6.1) and the ubuntu host kernel (currently v6.8) lack the change. Fixes: 2babc80 ("test(aarch64): add host vs guest cpu feature test") Signed-off-by: Takahiro Itazuri <[email protected]>
Linux kernel v6.4+ passes through the "l1d_flush" CPUID bit to guests. While the ubuntu host kernel (v6.8) has the change, the latest Amazon Linux 2 and Amazon Linux 2023 doesn't. Fixes: 4e014a1 ("test(x86_64): add host vs guest cpu feature test") Signed-off-by: Takahiro Itazuri <[email protected]>
Linux kernel v6.6+ drops the synthetic feature flag. While the ubuntu host kernel (v6.8) has the change, the Amazon Linux kernels (v5.10 and v6.1) and the guest kernels (v5.10 and v6.1) don't. Fixes: 4e014a1 ("test(x86_64): add host vs guest cpu feature test") Signed-off-by: Takahiro Itazuri <[email protected]>
b276fc1
to
6659b64
Compare
ShadowCurse
approved these changes
Nov 7, 2024
pb8o
approved these changes
Nov 7, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Reason
PR #4884 introduced a test that ensures CPU feature diff between host and guest hasn't been changed.
However, the expected diff can vary depending on a combination of host kernel version and guest kernel version.
The current our setting is as follows:
Changes
Note that I implemented it in a general way as possible because we might want to support more host and guest kernels in the future.
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
[ ] If a specific issue led to this PR, this PR closes the issue.[ ] Any required documentation changes (code and docs) are included in thisPR.
[ ] API changes follow the Runbook for Firecracker API changes.[ ] User-facing changes are mentioned inCHANGELOG.md
.TODO
s link to an issue.contribution quality standards.
rust-vmm
.