-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Enforce clippy integration test on aarch64 #1961
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
Conversation
src/arch/src/aarch64/fdt.rs
Outdated
if num_cpus > 1 { | ||
if cpu_index > 0 { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The logic here seems different than it was before. For example, if num_cpus was 2, we were appending the property for every cpu, now we won't append it for the first one.
Also, would be nice to add a comment or a pointer here why we do this check, I have troubles finding it in the aforementioned doc.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch, @lauralt ! I updated the code and also added a more explicit comment. Take a look!
28af370
to
09e5a9b
Compare
src/arch/src/aarch64/fdt.rs
Outdated
|
||
for cpu_index in 0..num_cpus { | ||
let more_than_one = vcpu_mpidr.len() > 1; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
more_tan_one
sounds a bit confusing to me. I would rename it to has_multiple_vcpus
or I would keep the old variable num_cpus = vcpu_mpidr.len();
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done! Take a look!
Signed-off-by: Diana Popa <dpopa@amazon.com>
Also, adjusted code to also run clippy on gnu code (mostly found in the seccomp logic). Signed-off-by: Diana Popa <dpopa@amazon.com>
Reason for This PR
Fixes #1007.
Description of Changes
Fixes clippy errors and enforce check in test_style.
rust-vmm
.License Acceptance
By submitting this pull request, I confirm that my contribution is made under
the terms of the Apache 2.0 license.
PR Checklist
[Author TODO: Meet these criteria.]
[Reviewer TODO: Verify that these criteria are met. Request changes if not]
git commit -s
).unsafe
code is properly documented.firecracker/swagger.yaml
.CHANGELOG.md
.