aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorK. Y. Srinivasan <kys@microsoft.com>2012-12-01 09:46:58 -0500
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-01-17 14:41:49 -0500
commit5fbebb2d2095e5c7d289d5f4ffecc2f2661c584a (patch)
tree6160cdab66b0b401d15fceffab8129b79ad198cb
parentc2b8e5202cf7670f918d0f7439ed2123cd58e1b7 (diff)
Drivers: hv: Capture the host build information
Capture the host build information so it can be presented along with the negotiated vmbus version information. Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/hv/hv.c9
-rw-r--r--drivers/hv/hyperv_vmbus.h7
2 files changed, 16 insertions, 0 deletions
diff --git a/drivers/hv/hv.c b/drivers/hv/hv.c
index 03e6a1eb1145..0cd2da3b22f5 100644
--- a/drivers/hv/hv.c
+++ b/drivers/hv/hv.c
@@ -40,6 +40,11 @@ struct hv_context hv_context = {
40/* 40/*
41 * query_hypervisor_info - Get version info of the windows hypervisor 41 * query_hypervisor_info - Get version info of the windows hypervisor
42 */ 42 */
43unsigned int host_info_eax;
44unsigned int host_info_ebx;
45unsigned int host_info_ecx;
46unsigned int host_info_edx;
47
43static int query_hypervisor_info(void) 48static int query_hypervisor_info(void)
44{ 49{
45 unsigned int eax; 50 unsigned int eax;
@@ -76,6 +81,10 @@ static int query_hypervisor_info(void)
76 ecx, 81 ecx,
77 edx >> 24, 82 edx >> 24,
78 edx & 0xFFFFFF); 83 edx & 0xFFFFFF);
84 host_info_eax = eax;
85 host_info_ebx = ebx;
86 host_info_ecx = ecx;
87 host_info_edx = edx;
79 } 88 }
80 return max_leaf; 89 return max_leaf;
81} 90}
diff --git a/drivers/hv/hyperv_vmbus.h b/drivers/hv/hyperv_vmbus.h
index ac111f223821..12f2f9e989f7 100644
--- a/drivers/hv/hyperv_vmbus.h
+++ b/drivers/hv/hyperv_vmbus.h
@@ -531,6 +531,13 @@ extern void hv_synic_init(void *irqarg);
531 531
532extern void hv_synic_cleanup(void *arg); 532extern void hv_synic_cleanup(void *arg);
533 533
534/*
535 * Host version information.
536 */
537extern unsigned int host_info_eax;
538extern unsigned int host_info_ebx;
539extern unsigned int host_info_ecx;
540extern unsigned int host_info_edx;
534 541
535/* Interface */ 542/* Interface */
536 543