All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH repost] x86/boot: Add a message about ignored early NMIs
@ 2024-01-12 11:13 NOMURA JUNICHI(野村 淳一)
  2024-01-12 12:06 ` kirill.shutemov
  0 siblings, 1 reply; 9+ messages in thread
From: NOMURA JUNICHI(野村 淳一) @ 2024-01-12 11:13 UTC (permalink / raw)
  To: mingo, tglx, bp, dave.hansen, x86
  Cc: hpa, kirill.shutemov, ardb, david, nikunj, thomas.lendacky,
	debarbos, jlelli, lgoncalv, dzickus, linux-kernel

Commit 78a509fba9c9 ("x86/boot: Ignore NMIs during very early boot") added
empty handler in early boot stage to avoid boot failure by spurious NMIs.

Add a diagnostic message in case we need to know whether early NMIs have
occurred and/or what happened to them.

Signed-off-by: Jun'ichi Nomura <junichi.nomura@nec.com>
Suggested-by: Borislav Petkov <bp@alien8.de>
Suggested-by: H. Peter Anvin <hpa@zytor.com>
Link: https://lore.kernel.org/lkml/20231130103339.GCZWhlA196uRklTMNF@fat_crate.local/

diff --git a/arch/x86/boot/compressed/ident_map_64.c b/arch/x86/boot/compressed/ident_map_64.c
--- a/arch/x86/boot/compressed/ident_map_64.c
+++ b/arch/x86/boot/compressed/ident_map_64.c
@@ -387,7 +387,10 @@ void do_boot_page_fault(struct pt_regs *regs, unsigned long error_code)
 	kernel_add_identity_map(address, end);
 }
 
+extern int spurious_nmi_count;
+
 void do_boot_nmi_trap(struct pt_regs *regs, unsigned long error_code)
 {
 	/* Empty handler to ignore NMI during early boot */
+	spurious_nmi_count++;
 }
diff --git a/arch/x86/boot/compressed/misc.c b/arch/x86/boot/compressed/misc.c
--- a/arch/x86/boot/compressed/misc.c
+++ b/arch/x86/boot/compressed/misc.c
@@ -357,6 +357,8 @@ unsigned long decompress_kernel(unsigned char *outbuf, unsigned long virt_addr,
 	return entry;
 }
 
+int spurious_nmi_count;
+
 /*
  * The compressed kernel image (ZO), has been moved so that its position
  * is against the end of the buffer used to hold the uncompressed kernel
@@ -493,6 +495,12 @@ asmlinkage __visible void *extract_kernel(void *rmode, unsigned char *output)
 	/* Disable exception handling before booting the kernel */
 	cleanup_exception_handling();
 
+	if (spurious_nmi_count) {
+		error_putstr("Spurious early NMI ignored. Number of NMIs: 0x");
+		error_puthex(spurious_nmi_count);
+		error_putstr("\n");
+	}
+
 	return output + entry_offset;
 }
 

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

* Re: [PATCH repost] x86/boot: Add a message about ignored early NMIs
  2024-01-12 11:13 [PATCH repost] x86/boot: Add a message about ignored early NMIs NOMURA JUNICHI(野村 淳一)
@ 2024-01-12 12:06 ` kirill.shutemov
  2024-01-15  8:57   ` [PATCH v2] " NOMURA JUNICHI(野村 淳一)
  0 siblings, 1 reply; 9+ messages in thread
From: kirill.shutemov @ 2024-01-12 12:06 UTC (permalink / raw)
  To: NOMURA JUNICHI(野村 淳一)
  Cc: mingo, tglx, bp, dave.hansen, x86, hpa, ardb, david, nikunj,
	thomas.lendacky, debarbos, jlelli, lgoncalv, dzickus,
	linux-kernel

On Fri, Jan 12, 2024 at 11:13:53AM +0000, NOMURA JUNICHI(野村 淳一) wrote:
> Commit 78a509fba9c9 ("x86/boot: Ignore NMIs during very early boot") added
> empty handler in early boot stage to avoid boot failure by spurious NMIs.
> 
> Add a diagnostic message in case we need to know whether early NMIs have
> occurred and/or what happened to them.
> 
> Signed-off-by: Jun'ichi Nomura <junichi.nomura@nec.com>
> Suggested-by: Borislav Petkov <bp@alien8.de>
> Suggested-by: H. Peter Anvin <hpa@zytor.com>
> Link: https://lore.kernel.org/lkml/20231130103339.GCZWhlA196uRklTMNF@fat_crate.local/
> 
> diff --git a/arch/x86/boot/compressed/ident_map_64.c b/arch/x86/boot/compressed/ident_map_64.c
> --- a/arch/x86/boot/compressed/ident_map_64.c
> +++ b/arch/x86/boot/compressed/ident_map_64.c
> @@ -387,7 +387,10 @@ void do_boot_page_fault(struct pt_regs *regs, unsigned long error_code)
>  	kernel_add_identity_map(address, end);
>  }
>  
> +extern int spurious_nmi_count;
> +

It has to be in a header file.

>  void do_boot_nmi_trap(struct pt_regs *regs, unsigned long error_code)
>  {
>  	/* Empty handler to ignore NMI during early boot */
> +	spurious_nmi_count++;
>  }
> diff --git a/arch/x86/boot/compressed/misc.c b/arch/x86/boot/compressed/misc.c
> --- a/arch/x86/boot/compressed/misc.c
> +++ b/arch/x86/boot/compressed/misc.c
> @@ -357,6 +357,8 @@ unsigned long decompress_kernel(unsigned char *outbuf, unsigned long virt_addr,
>  	return entry;
>  }
>  
> +int spurious_nmi_count;
> +

It is not a right place to define a variable. Do it next to rest of
variables at the beginning of the file.
>  /*
>   * The compressed kernel image (ZO), has been moved so that its position
>   * is against the end of the buffer used to hold the uncompressed kernel
> @@ -493,6 +495,12 @@ asmlinkage __visible void *extract_kernel(void *rmode, unsigned char *output)
>  	/* Disable exception handling before booting the kernel */
>  	cleanup_exception_handling();
>  
> +	if (spurious_nmi_count) {
> +		error_putstr("Spurious early NMI ignored. Number of NMIs: 0x");
> +		error_puthex(spurious_nmi_count);
> +		error_putstr("\n");
> +	}
> +
>  	return output + entry_offset;
>  }
>  

-- 
  Kiryl Shutsemau / Kirill A. Shutemov

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

* [PATCH v2] x86/boot: Add a message about ignored early NMIs
  2024-01-12 12:06 ` kirill.shutemov
@ 2024-01-15  8:57   ` NOMURA JUNICHI(野村 淳一)
  2024-01-15 10:14     ` kirill.shutemov
  2024-01-23 11:26     ` Borislav Petkov
  0 siblings, 2 replies; 9+ messages in thread
From: NOMURA JUNICHI(野村 淳一) @ 2024-01-15  8:57 UTC (permalink / raw)
  To: kirill.shutemov, mingo, tglx, bp, dave.hansen, x86
  Cc: hpa, ardb, david, nikunj, thomas.lendacky, debarbos, jlelli,
	lgoncalv, dzickus, linux-kernel

Commit 78a509fba9c9 ("x86/boot: Ignore NMIs during very early boot") added
empty handler in early boot stage to avoid boot failure by spurious NMIs.

Add a diagnostic message in case we need to know whether early NMIs have
occurred and/or what happened to them.

Signed-off-by: Jun'ichi Nomura <junichi.nomura@nec.com>
Suggested-by: Borislav Petkov <bp@alien8.de>
Suggested-by: H. Peter Anvin <hpa@zytor.com>
Link: https://lore.kernel.org/lkml/20231130103339.GCZWhlA196uRklTMNF@fat_crate.local/
--
v2
  * Moved variable declaration and definition to the right place
    based on comments from Kirill.
    No functional changes.

diff --git a/arch/x86/boot/compressed/ident_map_64.c b/arch/x86/boot/compressed/ident_map_64.c
--- a/arch/x86/boot/compressed/ident_map_64.c
+++ b/arch/x86/boot/compressed/ident_map_64.c
@@ -390,4 +390,5 @@ void do_boot_page_fault(struct pt_regs *regs, unsigned long error_code)
 void do_boot_nmi_trap(struct pt_regs *regs, unsigned long error_code)
 {
 	/* Empty handler to ignore NMI during early boot */
+	spurious_nmi_count++;
 }
diff --git a/arch/x86/boot/compressed/misc.c b/arch/x86/boot/compressed/misc.c
--- a/arch/x86/boot/compressed/misc.c
+++ b/arch/x86/boot/compressed/misc.c
@@ -52,6 +52,7 @@ struct port_io_ops pio_ops;
 
 memptr free_mem_ptr;
 memptr free_mem_end_ptr;
+int spurious_nmi_count;
 
 static char *vidmem;
 static int vidport;
@@ -493,6 +494,12 @@ asmlinkage __visible void *extract_kernel(void *rmode, unsigned char *output)
 	/* Disable exception handling before booting the kernel */
 	cleanup_exception_handling();
 
+	if (spurious_nmi_count) {
+		error_putstr("Spurious early NMI ignored. Number of NMIs: 0x");
+		error_puthex(spurious_nmi_count);
+		error_putstr("\n");
+	}
+
 	return output + entry_offset;
 }
 
diff --git a/arch/x86/boot/compressed/misc.h b/arch/x86/boot/compressed/misc.h
--- a/arch/x86/boot/compressed/misc.h
+++ b/arch/x86/boot/compressed/misc.h
@@ -59,6 +59,7 @@ extern char _head[], _end[];
 /* misc.c */
 extern memptr free_mem_ptr;
 extern memptr free_mem_end_ptr;
+extern int spurious_nmi_count;
 void *malloc(int size);
 void free(void *where);
 void __putstr(const char *s);

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

* Re: [PATCH v2] x86/boot: Add a message about ignored early NMIs
  2024-01-15  8:57   ` [PATCH v2] " NOMURA JUNICHI(野村 淳一)
@ 2024-01-15 10:14     ` kirill.shutemov
  2024-01-23 11:26     ` Borislav Petkov
  1 sibling, 0 replies; 9+ messages in thread
From: kirill.shutemov @ 2024-01-15 10:14 UTC (permalink / raw)
  To: NOMURA JUNICHI(野村 淳一)
  Cc: mingo, tglx, bp, dave.hansen, x86, hpa, ardb, david, nikunj,
	thomas.lendacky, debarbos, jlelli, lgoncalv, dzickus,
	linux-kernel

On Mon, Jan 15, 2024 at 08:57:45AM +0000, NOMURA JUNICHI(野村 淳一) wrote:
> Commit 78a509fba9c9 ("x86/boot: Ignore NMIs during very early boot") added
> empty handler in early boot stage to avoid boot failure by spurious NMIs.
> 
> Add a diagnostic message in case we need to know whether early NMIs have
> occurred and/or what happened to them.
> 
> Signed-off-by: Jun'ichi Nomura <junichi.nomura@nec.com>
> Suggested-by: Borislav Petkov <bp@alien8.de>
> Suggested-by: H. Peter Anvin <hpa@zytor.com>

Acked-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>

-- 
  Kiryl Shutsemau / Kirill A. Shutemov

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

* Re: [PATCH v2] x86/boot: Add a message about ignored early NMIs
  2024-01-15  8:57   ` [PATCH v2] " NOMURA JUNICHI(野村 淳一)
  2024-01-15 10:14     ` kirill.shutemov
@ 2024-01-23 11:26     ` Borislav Petkov
  2024-01-24 11:44       ` NOMURA JUNICHI(野村 淳一)
  1 sibling, 1 reply; 9+ messages in thread
From: Borislav Petkov @ 2024-01-23 11:26 UTC (permalink / raw)
  To: NOMURA JUNICHI(野村 淳一)
  Cc: kirill.shutemov, mingo, tglx, dave.hansen, x86, hpa, ardb, david,
	nikunj, thomas.lendacky, debarbos, jlelli, lgoncalv, dzickus,
	linux-kernel

On Mon, Jan 15, 2024 at 08:57:45AM +0000, NOMURA JUNICHI(野村 淳一) wrote:
> +	if (spurious_nmi_count) {
> +		error_putstr("Spurious early NMI ignored. Number of NMIs: 0x");
> +		error_puthex(spurious_nmi_count);
> +		error_putstr("\n");

Uff, that's just silly:

Spurious early NMIs ignored: 0x0000000000000017

Would you like to add a error_putnum() or so in a prepatch which would
make this output

Spurious early NMIs ignored: 23.

?

So that it is human readable and doesn't make me wonder what that hex
value is supposed to mean?

Thx.

Btw, please use this version when sending next time:

---
From: =?UTF-8?q?NOMURA=20JUNICHI=28=E9=87=8E=E6=9D=91=20=E6=B7=B3=E4=B8=80?=
 =?UTF-8?q?=29?= <junichi.nomura@nec.com>
Date: Mon, 15 Jan 2024 08:57:45 +0000
Subject: [PATCH] x86/boot: Add a message about ignored early NMIs

Commit

  78a509fba9c9 ("x86/boot: Ignore NMIs during very early boot")

added an empty handler in early boot stage to avoid boot failure due to
spurious NMIs.

Add a diagnostic message to show when early NMIs have occurred and/or
what happened to them.

  [ bp: Touchups. ]

Suggested-by: Borislav Petkov <bp@alien8.de>
Suggested-by: H. Peter Anvin <hpa@zytor.com>
Signed-off-by: Jun'ichi Nomura <junichi.nomura@nec.com>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Acked-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
Link: https://lore.kernel.org/lkml/20231130103339.GCZWhlA196uRklTMNF@fat_crate.local
---
 arch/x86/boot/compressed/ident_map_64.c | 2 +-
 arch/x86/boot/compressed/misc.c         | 7 +++++++
 arch/x86/boot/compressed/misc.h         | 1 +
 3 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/arch/x86/boot/compressed/ident_map_64.c b/arch/x86/boot/compressed/ident_map_64.c
index ff09ca6dbb87..909f2a35b60c 100644
--- a/arch/x86/boot/compressed/ident_map_64.c
+++ b/arch/x86/boot/compressed/ident_map_64.c
@@ -389,5 +389,5 @@ void do_boot_page_fault(struct pt_regs *regs, unsigned long error_code)
 
 void do_boot_nmi_trap(struct pt_regs *regs, unsigned long error_code)
 {
-	/* Empty handler to ignore NMI during early boot */
+	spurious_nmi_count++;
 }
diff --git a/arch/x86/boot/compressed/misc.c b/arch/x86/boot/compressed/misc.c
index b99e08e6815b..e7f4eb24a9a4 100644
--- a/arch/x86/boot/compressed/misc.c
+++ b/arch/x86/boot/compressed/misc.c
@@ -52,6 +52,7 @@ struct port_io_ops pio_ops;
 
 memptr free_mem_ptr;
 memptr free_mem_end_ptr;
+int spurious_nmi_count;
 
 static char *vidmem;
 static int vidport;
@@ -493,6 +494,12 @@ asmlinkage __visible void *extract_kernel(void *rmode, unsigned char *output)
 	/* Disable exception handling before booting the kernel */
 	cleanup_exception_handling();
 
+	if (spurious_nmi_count) {
+		error_putstr("Spurious early NMIs ignored: 0x");
+		error_puthex(spurious_nmi_count);
+		error_putstr("\n");
+	}
+
 	return output + entry_offset;
 }
 
diff --git a/arch/x86/boot/compressed/misc.h b/arch/x86/boot/compressed/misc.h
index bc2f0f17fb90..b858d6aa648c 100644
--- a/arch/x86/boot/compressed/misc.h
+++ b/arch/x86/boot/compressed/misc.h
@@ -59,6 +59,7 @@ extern char _head[], _end[];
 /* misc.c */
 extern memptr free_mem_ptr;
 extern memptr free_mem_end_ptr;
+extern int spurious_nmi_count;
 void *malloc(int size);
 void free(void *where);
 void __putstr(const char *s);
-- 
2.43.0



-- 
Regards/Gruss,
    Boris.

https://people.kernel.org/tglx/notes-about-netiquette

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

* RE: [PATCH v2] x86/boot: Add a message about ignored early NMIs
  2024-01-23 11:26     ` Borislav Petkov
@ 2024-01-24 11:44       ` NOMURA JUNICHI(野村 淳一)
  2024-01-25  2:00         ` H. Peter Anvin
  0 siblings, 1 reply; 9+ messages in thread
From: NOMURA JUNICHI(野村 淳一) @ 2024-01-24 11:44 UTC (permalink / raw)
  To: Borislav Petkov
  Cc: kirill.shutemov, mingo, tglx, dave.hansen, x86, hpa, ardb, david,
	nikunj, thomas.lendacky, debarbos, jlelli, lgoncalv, dzickus,
	linux-kernel

[-- Attachment #1: Type: text/plain, Size: 930 bytes --]

> From: Borislav Petkov <bp@alien8.de>
> On Mon, Jan 15, 2024 at 08:57:45AM +0000, NOMURA JUNICHI(野村 淳一) wrote:
> > +	if (spurious_nmi_count) {
> > +		error_putstr("Spurious early NMI ignored. Number of NMIs: 0x");
> > +		error_puthex(spurious_nmi_count);
> > +		error_putstr("\n");
> 
> Uff, that's just silly:
> 
> Spurious early NMIs ignored: 0x0000000000000017
> 
> Would you like to add a error_putnum() or so in a prepatch which would
> make this output
> 
> Spurious early NMIs ignored: 23.
> 
> ?
> 
> So that it is human readable and doesn't make me wonder what that hex
> value is supposed to mean?

Yes, it would be nicer to print that way.  I used the existing error_puthex() just
to keep the patch minimal.  I will try to add error_putnum().

> Btw, please use this version when sending next time:

Thank you.

--
Jun'ichi Nomura, NEC Corporation / NEC Solution Innovators, Ltd.

[-- Attachment #2: smime.p7s --]
[-- Type: application/pkcs7-signature, Size: 5779 bytes --]

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

* Re: [PATCH v2] x86/boot: Add a message about ignored early NMIs
  2024-01-24 11:44       ` NOMURA JUNICHI(野村 淳一)
@ 2024-01-25  2:00         ` H. Peter Anvin
  2024-01-26  2:15           ` NOMURA JUNICHI(野村 淳一)
  0 siblings, 1 reply; 9+ messages in thread
From: H. Peter Anvin @ 2024-01-25  2:00 UTC (permalink / raw)
  To: NOMURA JUNICHI(野村 淳一), Borislav Petkov
  Cc: kirill.shutemov, mingo, tglx, dave.hansen, x86, ardb, david,
	nikunj, thomas.lendacky, debarbos, jlelli, lgoncalv, dzickus,
	linux-kernel

[-- Attachment #1: Type: text/plain, Size: 955 bytes --]



On 1/24/24 03:44, NOMURA JUNICHI(野村 淳一) wrote:
>> From: Borislav Petkov <bp@alien8.de>
>> On Mon, Jan 15, 2024 at 08:57:45AM +0000, NOMURA JUNICHI(野村 淳一) wrote:
>>> +	if (spurious_nmi_count) {
>>> +		error_putstr("Spurious early NMI ignored. Number of NMIs: 0x");
>>> +		error_puthex(spurious_nmi_count);
>>> +		error_putstr("\n");
>>
>> Uff, that's just silly:
>>
>> Spurious early NMIs ignored: 0x0000000000000017
>>
>> Would you like to add a error_putnum() or so in a prepatch which would
>> make this output
>>
>> Spurious early NMIs ignored: 23.
>>
>> ?
>>
>> So that it is human readable and doesn't make me wonder what that hex
>> value is supposed to mean?
> 
> Yes, it would be nicer to print that way.  I used the existing error_puthex() just
> to keep the patch minimal.  I will try to add error_putnum().
> 
>> Btw, please use this version when sending next time:
> 

Here is a *completely* untested patch for you...

	-hpa

[-- Attachment #2: putnum.diff --]
[-- Type: text/x-patch, Size: 1660 bytes --]

diff --git a/arch/x86/boot/compressed/misc.c b/arch/x86/boot/compressed/misc.c
index b99e08e6815b..bf2aac4f195e 100644
--- a/arch/x86/boot/compressed/misc.c
+++ b/arch/x86/boot/compressed/misc.c
@@ -164,21 +164,34 @@ void __putstr(const char *s)
 	outb(0xff & (pos >> 1), vidport+1);
 }
 
-void __puthex(unsigned long value)
+static noinline void __putnum(unsigned long value, unsigned int base,
+			      int mindig)
 {
-	char alpha[2] = "0";
-	int bits;
+	char buf[8*sizeof(value)+1];
+	char *p;
 
-	for (bits = sizeof(value) * 8 - 4; bits >= 0; bits -= 4) {
-		unsigned long digit = (value >> bits) & 0xf;
+	p = buf + sizeof(buf);
+	*--p = '\0';
 
-		if (digit < 0xA)
-			alpha[0] = '0' + digit;
-		else
-			alpha[0] = 'a' + (digit - 0xA);
+	while (mindig-- > 0 || value) {
+		unsigned char digit = value % base;
+		digit += (digit >= 10) ? ('a'-10) : '0';
+		*--p = digit;
 
-		__putstr(alpha);
+		value /= base;
 	}
+
+	__putstr(p);
+}
+
+void __puthex(unsigned long value)
+{
+	__putnum(value, 16, sizeof(value)*2);
+}
+
+void __putdec(unsigned long value)
+{
+	__putnum(value, 10, 1);
 }
 
 #ifdef CONFIG_X86_NEED_RELOCS
diff --git a/arch/x86/boot/compressed/misc.h b/arch/x86/boot/compressed/misc.h
index bc2f0f17fb90..6502bc69d1b8 100644
--- a/arch/x86/boot/compressed/misc.h
+++ b/arch/x86/boot/compressed/misc.h
@@ -63,8 +63,10 @@ void *malloc(int size);
 void free(void *where);
 void __putstr(const char *s);
 void __puthex(unsigned long value);
+void __putdec(unsigned long value);
 #define error_putstr(__x)  __putstr(__x)
 #define error_puthex(__x)  __puthex(__x)
+#define error_putdec(__x)  __putdec(__x)
 
 #ifdef CONFIG_X86_VERBOSE_BOOTUP
 

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

* RE: [PATCH v2] x86/boot: Add a message about ignored early NMIs
  2024-01-25  2:00         ` H. Peter Anvin
@ 2024-01-26  2:15           ` NOMURA JUNICHI(野村 淳一)
  2024-02-01 17:22             ` H. Peter Anvin
  0 siblings, 1 reply; 9+ messages in thread
From: NOMURA JUNICHI(野村 淳一) @ 2024-01-26  2:15 UTC (permalink / raw)
  To: H. Peter Anvin, Borislav Petkov
  Cc: kirill.shutemov, mingo, tglx, dave.hansen, x86, ardb, david,
	nikunj, thomas.lendacky, debarbos, jlelli, lgoncalv, dzickus,
	linux-kernel

[-- Attachment #1: Type: text/plain, Size: 1312 bytes --]

> From: H. Peter Anvin <hpa@zytor.com>
> On 1/24/24 03:44, NOMURA JUNICHI(野村 淳一) wrote:
> >> From: Borislav Petkov <bp@alien8.de>
> >> On Mon, Jan 15, 2024 at 08:57:45AM +0000, NOMURA JUNICHI(野村 淳一) wrote:
> >>> +	if (spurious_nmi_count) {
> >>> +		error_putstr("Spurious early NMI ignored. Number of NMIs: 0x");
> >>> +		error_puthex(spurious_nmi_count);
> >>> +		error_putstr("\n");
> >>
> >> Uff, that's just silly:
> >>
> >> Spurious early NMIs ignored: 0x0000000000000017
> >>
> >> Would you like to add a error_putnum() or so in a prepatch which would
> >> make this output
> >>
> >> Spurious early NMIs ignored: 23.
> >>
> >> ?
> >>
> >> So that it is human readable and doesn't make me wonder what that hex
> >> value is supposed to mean?
> >
> > Yes, it would be nicer to print that way.  I used the existing error_puthex() just
> > to keep the patch minimal.  I will try to add error_putnum().
> >
> >> Btw, please use this version when sending next time:
> 
> Here is a *completely* untested patch for you...

Ah, I was preparing decimal only version but yours is much better.
I tested and it just works.

I would like to use yours as a prepatch.  May I have your signed-off-by?

--
Jun'ichi Nomura, NEC Corporation / NEC Solution Innovators, Ltd.

[-- Attachment #2: smime.p7s --]
[-- Type: application/pkcs7-signature, Size: 5779 bytes --]

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

* RE: [PATCH v2] x86/boot: Add a message about ignored early NMIs
  2024-01-26  2:15           ` NOMURA JUNICHI(野村 淳一)
@ 2024-02-01 17:22             ` H. Peter Anvin
  0 siblings, 0 replies; 9+ messages in thread
From: H. Peter Anvin @ 2024-02-01 17:22 UTC (permalink / raw)
  To: NOMURA JUNICHI(野村 淳一),
	Borislav Petkov
  Cc: kirill.shutemov, mingo, tglx, dave.hansen, x86, ardb, david,
	nikunj, thomas.lendacky, debarbos, jlelli, lgoncalv, dzickus,
	linux-kernel

On January 25, 2024 6:15:15 PM PST, "NOMURA JUNICHI(野村 淳一)" <junichi.nomura@nec.com> wrote:
>> From: H. Peter Anvin <hpa@zytor.com>
>> On 1/24/24 03:44, NOMURA JUNICHI(野村 淳一) wrote:
>> >> From: Borislav Petkov <bp@alien8.de>
>> >> On Mon, Jan 15, 2024 at 08:57:45AM +0000, NOMURA JUNICHI(野村 淳一) wrote:
>> >>> +	if (spurious_nmi_count) {
>> >>> +		error_putstr("Spurious early NMI ignored. Number of NMIs: 0x");
>> >>> +		error_puthex(spurious_nmi_count);
>> >>> +		error_putstr("\n");
>> >>
>> >> Uff, that's just silly:
>> >>
>> >> Spurious early NMIs ignored: 0x0000000000000017
>> >>
>> >> Would you like to add a error_putnum() or so in a prepatch which would
>> >> make this output
>> >>
>> >> Spurious early NMIs ignored: 23.
>> >>
>> >> ?
>> >>
>> >> So that it is human readable and doesn't make me wonder what that hex
>> >> value is supposed to mean?
>> >
>> > Yes, it would be nicer to print that way.  I used the existing error_puthex() just
>> > to keep the patch minimal.  I will try to add error_putnum().
>> >
>> >> Btw, please use this version when sending next time:
>> 
>> Here is a *completely* untested patch for you...
>
>Ah, I was preparing decimal only version but yours is much better.
>I tested and it just works.
>
>I would like to use yours as a prepatch.  May I have your signed-off-by?
>
>--
>Jun'ichi Nomura, NEC Corporation / NEC Solution Innovators, Ltd.

Signed-off-by: H. Peter Anvin (Intel) <hpa@zytor.com>

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

end of thread, other threads:[~2024-02-01 17:22 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-01-12 11:13 [PATCH repost] x86/boot: Add a message about ignored early NMIs NOMURA JUNICHI(野村 淳一)
2024-01-12 12:06 ` kirill.shutemov
2024-01-15  8:57   ` [PATCH v2] " NOMURA JUNICHI(野村 淳一)
2024-01-15 10:14     ` kirill.shutemov
2024-01-23 11:26     ` Borislav Petkov
2024-01-24 11:44       ` NOMURA JUNICHI(野村 淳一)
2024-01-25  2:00         ` H. Peter Anvin
2024-01-26  2:15           ` NOMURA JUNICHI(野村 淳一)
2024-02-01 17:22             ` H. Peter Anvin

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.