diff options
| author | Sean Christopherson <[email protected]> | 2024-08-09 19:43:30 +0000 |
|---|---|---|
| committer | Sean Christopherson <[email protected]> | 2024-09-10 03:22:08 +0000 |
| commit | 9a5bff7f5ec2383e3edac5eda561b52e267ccbb5 (patch) | |
| tree | 3d3496fd154cdf349be8eb3550a5ffdb89eac536 /drivers/platform/surface/aggregator/ssh_parser.c | |
| parent | KVM: x86/mmu: Add KVM_RMAP_MANY to replace open coded '1' and '1ul' literals (diff) | |
| download | kernel-9a5bff7f5ec2383e3edac5eda561b52e267ccbb5.tar.gz kernel-9a5bff7f5ec2383e3edac5eda561b52e267ccbb5.zip | |
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/[email protected]
Signed-off-by: Sean Christopherson <[email protected]>
Diffstat (limited to 'drivers/platform/surface/aggregator/ssh_parser.c')
0 files changed, 0 insertions, 0 deletions
