diff options
| author | Paolo Bonzini <[email protected]> | 2024-07-11 22:27:53 +0000 |
|---|---|---|
| committer | Paolo Bonzini <[email protected]> | 2024-07-26 18:46:14 +0000 |
| commit | e300614f10bd2f33252c8ba40b34d6c3fbf95d72 (patch) | |
| tree | 3a16617ce6e3b1fbe135fe7bfa4b5cbebd849468 /rust/helpers/security.c | |
| parent | KVM: guest_memfd: move check for already-populated page to common code (diff) | |
| download | kernel-e300614f10bd2f33252c8ba40b34d6c3fbf95d72.tar.gz kernel-e300614f10bd2f33252c8ba40b34d6c3fbf95d72.zip | |
KVM: cleanup and add shortcuts to kvm_range_has_memory_attributes()
Use a guard to simplify early returns, and add two more easy
shortcuts. If the requested attributes are invalid, the attributes
xarray will never show them as set. And if testing a single page,
kvm_get_memory_attributes() is more efficient.
Reviewed-by: Michael Roth <[email protected]>
Signed-off-by: Paolo Bonzini <[email protected]>
Diffstat (limited to 'rust/helpers/security.c')
0 files changed, 0 insertions, 0 deletions
