Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1496601 > unrolled thread

Bogus "APIC: NR_CPUS/possible_cpus limit of 4 reached" messages

Started byMarkus Trippelsdorf <markus@trippelsdorf.de>
First post2016-10-06 13:30 +0200
Last post2016-10-08 12:30 +0200
Articles 7 — 4 participants

Back to article view | Back to linux.kernel


Contents

  Bogus "APIC: NR_CPUS/possible_cpus limit of 4 reached" messages Markus Trippelsdorf <markus@trippelsdorf.de> - 2016-10-06 13:30 +0200
    Re: Bogus "APIC: NR_CPUS/possible_cpus limit of 4 reached" messages One Thousand Gnomes <gnomes@lxorguk.ukuu.org.uk> - 2016-10-06 13:50 +0200
      Re: Bogus "APIC: NR_CPUS/possible_cpus limit of 4 reached" messages Markus Trippelsdorf <markus@trippelsdorf.de> - 2016-10-06 14:00 +0200
        Re: Bogus "APIC: NR_CPUS/possible_cpus limit of 4 reached" messages Markus Trippelsdorf <markus@trippelsdorf.de> - 2016-10-07 15:30 +0200
          Re: Bogus "APIC: NR_CPUS/possible_cpus limit of 4 reached"  messages Thomas Gleixner <tglx@linutronix.de> - 2016-10-07 16:10 +0200
            Re: Bogus "APIC: NR_CPUS/possible_cpus limit of 4 reached" messages Markus Trippelsdorf <markus@trippelsdorf.de> - 2016-10-07 16:10 +0200
            [tip:x86/urgent] x86/apic: Prevent pointless warning messages tip-bot for Thomas Gleixner <tipbot@zytor.com> - 2016-10-08 12:30 +0200

#1496601 — Bogus "APIC: NR_CPUS/possible_cpus limit of 4 reached" messages

FromMarkus Trippelsdorf <markus@trippelsdorf.de>
Date2016-10-06 13:30 +0200
SubjectBogus "APIC: NR_CPUS/possible_cpus limit of 4 reached" messages
Message-ID<spf29-7Uz-5@gated-at.bofh.it>
On current trunk I get during boot:

[    0.000000] APIC: NR_CPUS/possible_cpus limit of 4 reached.  Processor 4/0x84 ignored.
[    0.000000] APIC: NR_CPUS/possible_cpus limit of 4 reached.  Processor 5/0x85 ignored.

I don't think these messages make much sense on a 4-core machine.

-- 
Markus

[toc] | [next] | [standalone]


#1496610

FromOne Thousand Gnomes <gnomes@lxorguk.ukuu.org.uk>
Date2016-10-06 13:50 +0200
Message-ID<spflv-81P-21@gated-at.bofh.it>
In reply to#1496601
On Thu, 6 Oct 2016 13:27:37 +0200
Markus Trippelsdorf <markus@trippelsdorf.de> wrote:

> On current trunk I get during boot:
> 
> [    0.000000] APIC: NR_CPUS/possible_cpus limit of 4 reached.  Processor 4/0x84 ignored.
> [    0.000000] APIC: NR_CPUS/possible_cpus limit of 4 reached.  Processor 5/0x85 ignored.
> 
> I don't think these messages make much sense on a 4-core machine.
> 

Four cores with or without hyperthreading ?

Alan

[toc] | [prev] | [next] | [standalone]


#1496611

FromMarkus Trippelsdorf <markus@trippelsdorf.de>
Date2016-10-06 14:00 +0200
Message-ID<spfvb-85m-1@gated-at.bofh.it>
In reply to#1496610
On 2016.10.06 at 12:48 +0100, One Thousand Gnomes wrote:
> On Thu, 6 Oct 2016 13:27:37 +0200
> Markus Trippelsdorf <markus@trippelsdorf.de> wrote:
> 
> > On current trunk I get during boot:
> > 
> > [    0.000000] APIC: NR_CPUS/possible_cpus limit of 4 reached.  Processor 4/0x84 ignored.
> > [    0.000000] APIC: NR_CPUS/possible_cpus limit of 4 reached.  Processor 5/0x85 ignored.
> > 
> > I don't think these messages make much sense on a 4-core machine.
> > 
> 
> Four cores with or without hyperthreading ?

Without. This is a rather old AMD machine (AMD Phenom II X4 955).

-- 
Markus

[toc] | [prev] | [next] | [standalone]


#1497154

FromMarkus Trippelsdorf <markus@trippelsdorf.de>
Date2016-10-07 15:30 +0200
Message-ID<spDnP-YF-17@gated-at.bofh.it>
In reply to#1496611
On 2016.10.06 at 13:52 +0200, Markus Trippelsdorf wrote:
> On 2016.10.06 at 12:48 +0100, One Thousand Gnomes wrote:
> > On Thu, 6 Oct 2016 13:27:37 +0200
> > Markus Trippelsdorf <markus@trippelsdorf.de> wrote:
> > 
> > > On current trunk I get during boot:
> > > 
> > > [    0.000000] APIC: NR_CPUS/possible_cpus limit of 4 reached.  Processor 4/0x84 ignored.
> > > [    0.000000] APIC: NR_CPUS/possible_cpus limit of 4 reached.  Processor 5/0x85 ignored.
> > > 
> > > I don't think these messages make much sense on a 4-core machine.
> > > 
> > 
> > Four cores with or without hyperthreading ?
> 
> Without. This is a rather old AMD machine (AMD Phenom II X4 955).

CCing more people.

-- 
Markus

[toc] | [prev] | [next] | [standalone]


#1497173 — Re: Bogus "APIC: NR_CPUS/possible_cpus limit of 4 reached" messages

FromThomas Gleixner <tglx@linutronix.de>
Date2016-10-07 16:10 +0200
SubjectRe: Bogus "APIC: NR_CPUS/possible_cpus limit of 4 reached" messages
Message-ID<spE0y-1th-5@gated-at.bofh.it>
In reply to#1497154
On Fri, 7 Oct 2016, Markus Trippelsdorf wrote:
> On 2016.10.06 at 13:52 +0200, Markus Trippelsdorf wrote:
> > On 2016.10.06 at 12:48 +0100, One Thousand Gnomes wrote:
> > > On Thu, 6 Oct 2016 13:27:37 +0200
> > > Markus Trippelsdorf <markus@trippelsdorf.de> wrote:
> > > 
> > > > On current trunk I get during boot:
> > > > 
> > > > [    0.000000] APIC: NR_CPUS/possible_cpus limit of 4 reached.  Processor 4/0x84 ignored.
> > > > [    0.000000] APIC: NR_CPUS/possible_cpus limit of 4 reached.  Processor 5/0x85 ignored.
> > > > 
> > > > I don't think these messages make much sense on a 4-core machine.
> > > > 
> > > 
> > > Four cores with or without hyperthreading ?
> > 
> > Without. This is a rather old AMD machine (AMD Phenom II X4 955).

That's due to the recent cpuid -> nodeid changes. The patch below should
fix it.

Thanks,

	tglx

diff --git a/arch/x86/kernel/apic/apic.c b/arch/x86/kernel/apic/apic.c
index f266b8a92a9e..88c657b057e2 100644
--- a/arch/x86/kernel/apic/apic.c
+++ b/arch/x86/kernel/apic/apic.c
@@ -2128,9 +2128,11 @@ int __generic_processor_info(int apicid, int version, bool enabled)
 	if (num_processors >= nr_cpu_ids) {
 		int thiscpu = max + disabled_cpus;
 
-		pr_warning(
-			"APIC: NR_CPUS/possible_cpus limit of %i reached."
-			"  Processor %d/0x%x ignored.\n", max, thiscpu, apicid);
+		if (enabled) {
+			pr_warning("APIC: NR_CPUS/possible_cpus limit of %i "
+				   "reached. Processor %d/0x%x ignored.\n",
+				   max, thiscpu, apicid);
+		}
 
 		disabled_cpus++;
 		return -EINVAL;

[toc] | [prev] | [next] | [standalone]


#1497174

FromMarkus Trippelsdorf <markus@trippelsdorf.de>
Date2016-10-07 16:10 +0200
Message-ID<spE0y-1th-9@gated-at.bofh.it>
In reply to#1497173
On 2016.10.07 at 15:55 +0200, Thomas Gleixner wrote:
> On Fri, 7 Oct 2016, Markus Trippelsdorf wrote:
> > On 2016.10.06 at 13:52 +0200, Markus Trippelsdorf wrote:
> > > On 2016.10.06 at 12:48 +0100, One Thousand Gnomes wrote:
> > > > On Thu, 6 Oct 2016 13:27:37 +0200
> > > > Markus Trippelsdorf <markus@trippelsdorf.de> wrote:
> > > > 
> > > > > On current trunk I get during boot:
> > > > > 
> > > > > [    0.000000] APIC: NR_CPUS/possible_cpus limit of 4 reached.  Processor 4/0x84 ignored.
> > > > > [    0.000000] APIC: NR_CPUS/possible_cpus limit of 4 reached.  Processor 5/0x85 ignored.
> > > > > 
> > > > > I don't think these messages make much sense on a 4-core machine.
> > > > > 
> > > > 
> > > > Four cores with or without hyperthreading ?
> > > 
> > > Without. This is a rather old AMD machine (AMD Phenom II X4 955).
> 
> That's due to the recent cpuid -> nodeid changes. The patch below should
> fix it.

Indeed it does. Thanks for the quick fix.

-- 
Markus

[toc] | [prev] | [next] | [standalone]


#1497700 — [tip:x86/urgent] x86/apic: Prevent pointless warning messages

Fromtip-bot for Thomas Gleixner <tipbot@zytor.com>
Date2016-10-08 12:30 +0200
Subject[tip:x86/urgent] x86/apic: Prevent pointless warning messages
Message-ID<spX3c-5RP-35@gated-at.bofh.it>
In reply to#1497173
Commit-ID:  df610d678893c85b82d3a68eea0d87dd4e03e615
Gitweb:     http://git.kernel.org/tip/df610d678893c85b82d3a68eea0d87dd4e03e615
Author:     Thomas Gleixner <tglx@linutronix.de>
AuthorDate: Fri, 7 Oct 2016 15:55:13 +0200
Committer:  Thomas Gleixner <tglx@linutronix.de>
CommitDate: Sat, 8 Oct 2016 12:18:36 +0200

x86/apic: Prevent pointless warning messages

Markus reported that he sees new warnings:

  APIC: NR_CPUS/possible_cpus limit of 4 reached.  Processor 4/0x84 ignored.
  APIC: NR_CPUS/possible_cpus limit of 4 reached.  Processor 5/0x85 ignored.

This comes from the recent persistant cpuid - nodeid changes. The code
which emits the warning has been called prior to these changes only for
enabled processors. Now it's called for disabled processors as well to get
the possible cpu accounting correct. So if the kernel is compiled for the
number of actual available/enabled CPUs and the BIOS reports disabled CPUs
as well then the above warnings are printed.

That's a pointless exercise as it only makes sense if there are more CPUs
enabled than the kernel supports.

Nake the warning conditional on enabled processors so we are back to the
state before these changes.

Fixes: 8f54969dc8d6 ("x86/acpi: Introduce persistent storage for cpuid <-> apicid mapping") 
Reported-and-tested-by: Markus Trippelsdorf <markus@trippelsdorf.de>
Cc: One Thousand Gnomes <gnomes@lxorguk.ukuu.org.uk>
Cc: Dou Liyang <douly.fnst@cn.fujitsu.com>
Cc: linux-acpi@vger.kernel.org
Cc: Gu Zheng <guz.fnst@cn.fujitsu.com>
Link: http://lkml.kernel.org/r/alpine.DEB.2.20.1610071549330.19804@nanos
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>

---
 arch/x86/kernel/apic/apic.c | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/arch/x86/kernel/apic/apic.c b/arch/x86/kernel/apic/apic.c
index f266b8a..88c657b 100644
--- a/arch/x86/kernel/apic/apic.c
+++ b/arch/x86/kernel/apic/apic.c
@@ -2128,9 +2128,11 @@ int __generic_processor_info(int apicid, int version, bool enabled)
 	if (num_processors >= nr_cpu_ids) {
 		int thiscpu = max + disabled_cpus;
 
-		pr_warning(
-			"APIC: NR_CPUS/possible_cpus limit of %i reached."
-			"  Processor %d/0x%x ignored.\n", max, thiscpu, apicid);
+		if (enabled) {
+			pr_warning("APIC: NR_CPUS/possible_cpus limit of %i "
+				   "reached. Processor %d/0x%x ignored.\n",
+				   max, thiscpu, apicid);
+		}
 
 		disabled_cpus++;
 		return -EINVAL;

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web