diff options
author | Sean Christopherson <seanjc@google.com> | 2024-08-09 22:43:30 +0300 |
---|---|---|
committer | Sean Christopherson <seanjc@google.com> | 2024-09-10 06:22:08 +0300 |
commit | 9a5bff7f5ec2383e3edac5eda561b52e267ccbb5 (patch) | |
tree | 3d3496fd154cdf349be8eb3550a5ffdb89eac536 /rust/helpers/signal.c | |
parent | 7645829145a91a3e13fdc322492500dae46ca17c (diff) | |
download | linux-9a5bff7f5ec2383e3edac5eda561b52e267ccbb5.tar.xz |
KVM: x86/mmu: Use KVM_PAGES_PER_HPAGE() instead of an open coded equivalent
Use KVM_PAGES_PER_HPAGE() instead of open coding equivalent logic that is
anything but obvious.
No functional change intended, and verified by compiling with the below
assertions:
BUILD_BUG_ON((1UL << KVM_HPAGE_GFN_SHIFT(PG_LEVEL_4K)) !=
KVM_PAGES_PER_HPAGE(PG_LEVEL_4K));
BUILD_BUG_ON((1UL << KVM_HPAGE_GFN_SHIFT(PG_LEVEL_2M)) !=
KVM_PAGES_PER_HPAGE(PG_LEVEL_2M));
BUILD_BUG_ON((1UL << KVM_HPAGE_GFN_SHIFT(PG_LEVEL_1G)) !=
KVM_PAGES_PER_HPAGE(PG_LEVEL_1G));
Link: https://lore.kernel.org/r/20240809194335.1726916-19-seanjc@google.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
Diffstat (limited to 'rust/helpers/signal.c')
0 files changed, 0 insertions, 0 deletions