Skip to content

Commit

Permalink
KVM: selftests: Replace hardcoded Linux OS id with HYPERV_LINUX_OS_ID
Browse files Browse the repository at this point in the history
Use HYPERV_LINUX_OS_ID macro instead of hardcoded 0x8100 << 48

Signed-off-by: Vipin Sharma <vipinsh@google.com>
Reviewed-by: Vitaly Kuznetsov <vkuznets@redhat.com>
Link: https://lore.kernel.org/r/20221212183720.4062037-12-vipinsh@google.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
  • Loading branch information
shvipin authored and sean-jc committed Feb 1, 2023
1 parent c4a4662 commit f650920
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tools/testing/selftests/kvm/x86_64/hyperv_clock.c
Expand Up @@ -104,7 +104,7 @@ static void guest_main(struct ms_hyperv_tsc_page *tsc_page, vm_paddr_t tsc_page_

/* Set Guest OS id to enable Hyper-V emulation */
GUEST_SYNC(1);
wrmsr(HV_X64_MSR_GUEST_OS_ID, (u64)0x8100 << 48);
wrmsr(HV_X64_MSR_GUEST_OS_ID, HYPERV_LINUX_OS_ID);
GUEST_SYNC(2);

check_tsc_msr_rdtsc();
Expand Down

0 comments on commit f650920

Please sign in to comment.