Subject: hv: set guest os id
From: <ohering@suse.de>
Patch-mainline: Never, this change carry until upstream provides better method
References: bnc#814005, bsc#1189965
Give the host more detailed info about the running guest.
Provide the guest OS id.
A better change is pending.
Acked-by: Olaf Hering <ohering@suse.de>
---
arch/x86/hyperv/hv_init.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
--- a/arch/x86/hyperv/hv_init.c
+++ b/arch/x86/hyperv/hv_init.c
@@ -420,7 +420,7 @@ void __init hyperv_init(void)
* 1. Register the guest ID
* 2. Enable the hypercall and register the hypercall page
*/
- guest_id = generate_guest_id(0, LINUX_VERSION_CODE, 0);
+ guest_id = generate_guest_id(0x10 /* SUSE */, LINUX_VERSION_CODE, 0 /* -d of a.b.c-d */);
wrmsrl(HV_X64_MSR_GUEST_OS_ID, guest_id);
/* Hyper-V requires to write guest os id via ghcb in SNP IVM. */