linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2] x86/hyperv: Set pv_info.name to "Hyper-V"
@ 2019-10-15 10:35 Andrea Parri
  2019-10-15 10:56 ` Wei Liu
                   ` (3 more replies)
  0 siblings, 4 replies; 7+ messages in thread
From: Andrea Parri @ 2019-10-15 10:35 UTC (permalink / raw)
  To: linux-kernel, linux-hyperv, x86
  Cc: K . Y . Srinivasan, Haiyang Zhang, Stephen Hemminger,
	Sasha Levin, Thomas Gleixner, Ingo Molnar, Borislav Petkov,
	H . Peter Anvin, Michael Kelley, Vitaly Kuznetsov, Dexuan Cui,
	Wei Liu, Andrea Parri

Michael reported that the x86/hyperv initialization code printed the
following dmesg when running in a VM on Hyper-V:

  [    0.000738] Booting paravirtualized kernel on bare hardware

Let the x86/hyperv initialization code set pv_info.name to "Hyper-V";
with this addition, the dmesg read:

  [    0.000172] Booting paravirtualized kernel on Hyper-V

Reported-by: Michael Kelley <mikelley@microsoft.com>
Signed-off-by: Andrea Parri <parri.andrea@gmail.com>
---
Changes since v1 ([1]):
  - move the setting of pv_info.name to ms_hyperv_init_platform() (Wei Liu)

[1] https://lkml.kernel.org/r/20191015092937.11244-1-parri.andrea@gmail.com

 arch/x86/kernel/cpu/mshyperv.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/x86/kernel/cpu/mshyperv.c b/arch/x86/kernel/cpu/mshyperv.c
index 267daad8c0360..e7f0776e2a811 100644
--- a/arch/x86/kernel/cpu/mshyperv.c
+++ b/arch/x86/kernel/cpu/mshyperv.c
@@ -216,6 +216,8 @@ static void __init ms_hyperv_init_platform(void)
 	int hv_host_info_ecx;
 	int hv_host_info_edx;
 
+	pv_info.name = "Hyper-V";
+
 	/*
 	 * Extract the features and hints
 	 */
-- 
2.23.0


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH v2] x86/hyperv: Set pv_info.name to "Hyper-V"
  2019-10-15 10:35 [PATCH v2] x86/hyperv: Set pv_info.name to "Hyper-V" Andrea Parri
@ 2019-10-15 10:56 ` Wei Liu
  2019-10-15 13:06 ` Michael Kelley
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 7+ messages in thread
From: Wei Liu @ 2019-10-15 10:56 UTC (permalink / raw)
  To: Andrea Parri
  Cc: Linux Kernel List, Linux on Hyper-V List, x86,
	K . Y . Srinivasan, Haiyang Zhang, Stephen Hemminger,
	Sasha Levin, Thomas Gleixner, Ingo Molnar, Borislav Petkov,
	H . Peter Anvin, Michael Kelley, Vitaly Kuznetsov, Dexuan Cui,
	Wei Liu

On Tue, 15 Oct 2019 at 11:35, Andrea Parri <parri.andrea@gmail.com> wrote:
>
> Michael reported that the x86/hyperv initialization code printed the
> following dmesg when running in a VM on Hyper-V:
>
>   [    0.000738] Booting paravirtualized kernel on bare hardware
>
> Let the x86/hyperv initialization code set pv_info.name to "Hyper-V";
> with this addition, the dmesg read:
>
>   [    0.000172] Booting paravirtualized kernel on Hyper-V
>
> Reported-by: Michael Kelley <mikelley@microsoft.com>
> Signed-off-by: Andrea Parri <parri.andrea@gmail.com>

Reviewed-by: Wei Liu <wei.liu@kernel.org>

^ permalink raw reply	[flat|nested] 7+ messages in thread

* RE: [PATCH v2] x86/hyperv: Set pv_info.name to "Hyper-V"
  2019-10-15 10:35 [PATCH v2] x86/hyperv: Set pv_info.name to "Hyper-V" Andrea Parri
  2019-10-15 10:56 ` Wei Liu
@ 2019-10-15 13:06 ` Michael Kelley
  2019-10-28 16:27   ` Sasha Levin
  2019-10-15 13:21 ` [tip: x86/urgent] " tip-bot2 for Andrea Parri
  2019-10-18 11:41 ` tip-bot2 for Andrea Parri
  3 siblings, 1 reply; 7+ messages in thread
From: Michael Kelley @ 2019-10-15 13:06 UTC (permalink / raw)
  To: Andrea Parri, linux-kernel, linux-hyperv, x86
  Cc: KY Srinivasan, Haiyang Zhang, Stephen Hemminger, Sasha Levin,
	Thomas Gleixner, Ingo Molnar, Borislav Petkov, H . Peter Anvin,
	vkuznets, Dexuan Cui, Wei Liu

From: Andrea Parri <parri.andrea@gmail.com> Sent: Tuesday, October 15, 2019 3:35 AM
> 
> Michael reported that the x86/hyperv initialization code printed the
> following dmesg when running in a VM on Hyper-V:
> 
>   [    0.000738] Booting paravirtualized kernel on bare hardware
> 
> Let the x86/hyperv initialization code set pv_info.name to "Hyper-V";
> with this addition, the dmesg read:
> 
>   [    0.000172] Booting paravirtualized kernel on Hyper-V
> 
> Reported-by: Michael Kelley <mikelley@microsoft.com>
> Signed-off-by: Andrea Parri <parri.andrea@gmail.com>

Reviewed-by: Michael Kelley <mikelley@microsoft.com>

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [tip: x86/urgent] x86/hyperv: Set pv_info.name to "Hyper-V"
  2019-10-15 10:35 [PATCH v2] x86/hyperv: Set pv_info.name to "Hyper-V" Andrea Parri
  2019-10-15 10:56 ` Wei Liu
  2019-10-15 13:06 ` Michael Kelley
@ 2019-10-15 13:21 ` tip-bot2 for Andrea Parri
  2019-10-18 11:41 ` tip-bot2 for Andrea Parri
  3 siblings, 0 replies; 7+ messages in thread
From: tip-bot2 for Andrea Parri @ 2019-10-15 13:21 UTC (permalink / raw)
  To: linux-tip-commits
  Cc: Michael Kelley, Andrea Parri, Thomas Gleixner, Wei Liu,
	Ingo Molnar, Borislav Petkov, linux-kernel

The following commit has been merged into the x86/urgent branch of tip:

Commit-ID:     628270ef628af6712ee99771b583feb667a7f1bc
Gitweb:        https://git.kernel.org/tip/628270ef628af6712ee99771b583feb667a7f1bc
Author:        Andrea Parri <parri.andrea@gmail.com>
AuthorDate:    Tue, 15 Oct 2019 12:35:02 +02:00
Committer:     Thomas Gleixner <tglx@linutronix.de>
CommitterDate: Tue, 15 Oct 2019 15:18:17 +02:00

x86/hyperv: Set pv_info.name to "Hyper-V"

Michael reported that the x86/hyperv initialization code prints the
following dmesg when running in a VM on Hyper-V:

  [    0.000738] Booting paravirtualized kernel on bare hardware

Let the x86/hyperv initialization code set pv_info.name to "Hyper-V" so
dmesg reports correctly:

  [    0.000172] Booting paravirtualized kernel on Hyper-V

Reported-by: Michael Kelley <mikelley@microsoft.com>
Signed-off-by: Andrea Parri <parri.andrea@gmail.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Wei Liu <wei.liu@kernel.org>
Reviewed-by: Michael Kelley <mikelley@microsoft.com>
Link: https://lkml.kernel.org/r/20191015103502.13156-1-parri.andrea@gmail.com

---
 arch/x86/kernel/cpu/mshyperv.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/x86/kernel/cpu/mshyperv.c b/arch/x86/kernel/cpu/mshyperv.c
index 267daad..e7f0776 100644
--- a/arch/x86/kernel/cpu/mshyperv.c
+++ b/arch/x86/kernel/cpu/mshyperv.c
@@ -216,6 +216,8 @@ static void __init ms_hyperv_init_platform(void)
 	int hv_host_info_ecx;
 	int hv_host_info_edx;
 
+	pv_info.name = "Hyper-V";
+
 	/*
 	 * Extract the features and hints
 	 */

^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [tip: x86/urgent] x86/hyperv: Set pv_info.name to "Hyper-V"
  2019-10-15 10:35 [PATCH v2] x86/hyperv: Set pv_info.name to "Hyper-V" Andrea Parri
                   ` (2 preceding siblings ...)
  2019-10-15 13:21 ` [tip: x86/urgent] " tip-bot2 for Andrea Parri
@ 2019-10-18 11:41 ` tip-bot2 for Andrea Parri
  3 siblings, 0 replies; 7+ messages in thread
From: tip-bot2 for Andrea Parri @ 2019-10-18 11:41 UTC (permalink / raw)
  To: linux-tip-commits
  Cc: Michael Kelley, Andrea Parri, Thomas Gleixner, Wei Liu,
	YueHaibing, Ingo Molnar, Borislav Petkov, linux-kernel

The following commit has been merged into the x86/urgent branch of tip:

Commit-ID:     f7c0f50f1857c1cf013466fcea4dc98d116bf456
Gitweb:        https://git.kernel.org/tip/f7c0f50f1857c1cf013466fcea4dc98d116bf456
Author:        Andrea Parri <parri.andrea@gmail.com>
AuthorDate:    Tue, 15 Oct 2019 12:35:02 +02:00
Committer:     Thomas Gleixner <tglx@linutronix.de>
CommitterDate: Fri, 18 Oct 2019 13:33:38 +02:00

x86/hyperv: Set pv_info.name to "Hyper-V"

Michael reported that the x86/hyperv initialization code prints the
following dmesg when running in a VM on Hyper-V:

  [    0.000738] Booting paravirtualized kernel on bare hardware

Let the x86/hyperv initialization code set pv_info.name to "Hyper-V" so
dmesg reports correctly:

  [    0.000172] Booting paravirtualized kernel on Hyper-V

[ tglx: Folded build fix provided by Yue ]

Reported-by: Michael Kelley <mikelley@microsoft.com>
Signed-off-by: Andrea Parri <parri.andrea@gmail.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Wei Liu <wei.liu@kernel.org>
Reviewed-by: Michael Kelley <mikelley@microsoft.com>
Cc: YueHaibing <yuehaibing@huawei.com>
Link: https://lkml.kernel.org/r/20191015103502.13156-1-parri.andrea@gmail.com


---
 arch/x86/kernel/cpu/mshyperv.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/arch/x86/kernel/cpu/mshyperv.c b/arch/x86/kernel/cpu/mshyperv.c
index 267daad..c656d92 100644
--- a/arch/x86/kernel/cpu/mshyperv.c
+++ b/arch/x86/kernel/cpu/mshyperv.c
@@ -216,6 +216,10 @@ static void __init ms_hyperv_init_platform(void)
 	int hv_host_info_ecx;
 	int hv_host_info_edx;
 
+#ifdef CONFIG_PARAVIRT
+	pv_info.name = "Hyper-V";
+#endif
+
 	/*
 	 * Extract the features and hints
 	 */

^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH v2] x86/hyperv: Set pv_info.name to "Hyper-V"
  2019-10-15 13:06 ` Michael Kelley
@ 2019-10-28 16:27   ` Sasha Levin
  2019-10-28 17:13     ` Michael Kelley
  0 siblings, 1 reply; 7+ messages in thread
From: Sasha Levin @ 2019-10-28 16:27 UTC (permalink / raw)
  To: Michael Kelley
  Cc: Andrea Parri, linux-kernel, linux-hyperv, x86, KY Srinivasan,
	Haiyang Zhang, Stephen Hemminger, Thomas Gleixner, Ingo Molnar,
	Borislav Petkov, H . Peter Anvin, vkuznets, Dexuan Cui, Wei Liu

On Tue, Oct 15, 2019 at 01:06:33PM +0000, Michael Kelley wrote:
>From: Andrea Parri <parri.andrea@gmail.com> Sent: Tuesday, October 15, 2019 3:35 AM
>>
>> Michael reported that the x86/hyperv initialization code printed the
>> following dmesg when running in a VM on Hyper-V:
>>
>>   [    0.000738] Booting paravirtualized kernel on bare hardware
>>
>> Let the x86/hyperv initialization code set pv_info.name to "Hyper-V";
>> with this addition, the dmesg read:
>>
>>   [    0.000172] Booting paravirtualized kernel on Hyper-V
>>
>> Reported-by: Michael Kelley <mikelley@microsoft.com>
>> Signed-off-by: Andrea Parri <parri.andrea@gmail.com>
>
>Reviewed-by: Michael Kelley <mikelley@microsoft.com>

Thomas, will you be taking this? Would you rather have me deal with the
hyperv bits under arch/x86/?

-- 
Thanks,
Sasha

^ permalink raw reply	[flat|nested] 7+ messages in thread

* RE: [PATCH v2] x86/hyperv: Set pv_info.name to "Hyper-V"
  2019-10-28 16:27   ` Sasha Levin
@ 2019-10-28 17:13     ` Michael Kelley
  0 siblings, 0 replies; 7+ messages in thread
From: Michael Kelley @ 2019-10-28 17:13 UTC (permalink / raw)
  To: Sasha Levin
  Cc: Andrea Parri, linux-kernel, linux-hyperv, x86, KY Srinivasan,
	Haiyang Zhang, Stephen Hemminger, Thomas Gleixner, Ingo Molnar,
	Borislav Petkov, H . Peter Anvin, vkuznets, Dexuan Cui, Wei Liu

From: Sasha Levin <sashal@kernel.org> Sent: Monday, October 28, 2019 9:28 AM
> On Tue, Oct 15, 2019 at 01:06:33PM +0000, Michael Kelley wrote:
> >From: Andrea Parri <parri.andrea@gmail.com> Sent: Tuesday, October 15, 2019 3:35 AM
> >>
> >> Michael reported that the x86/hyperv initialization code printed the
> >> following dmesg when running in a VM on Hyper-V:
> >>
> >>   [    0.000738] Booting paravirtualized kernel on bare hardware
> >>
> >> Let the x86/hyperv initialization code set pv_info.name to "Hyper-V";
> >> with this addition, the dmesg read:
> >>
> >>   [    0.000172] Booting paravirtualized kernel on Hyper-V
> >>
> >> Reported-by: Michael Kelley <mikelley@microsoft.com>
> >> Signed-off-by: Andrea Parri <parri.andrea@gmail.com>
> >
> >Reviewed-by: Michael Kelley <mikelley@microsoft.com>
> 
> Thomas, will you be taking this? Would you rather have me deal with the
> hyperv bits under arch/x86/?
> 

Thomas has already pulled this one.  It's in Linus' tree.

Michael

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2019-10-28 17:13 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-15 10:35 [PATCH v2] x86/hyperv: Set pv_info.name to "Hyper-V" Andrea Parri
2019-10-15 10:56 ` Wei Liu
2019-10-15 13:06 ` Michael Kelley
2019-10-28 16:27   ` Sasha Levin
2019-10-28 17:13     ` Michael Kelley
2019-10-15 13:21 ` [tip: x86/urgent] " tip-bot2 for Andrea Parri
2019-10-18 11:41 ` tip-bot2 for Andrea Parri

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).