Bug 204685 - panic: mp_setmaxid: one CPU but mp_maxid is not zero
Summary: panic: mp_setmaxid: one CPU but mp_maxid is not zero
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: CURRENT
Hardware: sparc64 Any
: --- Affects Some People
Assignee: freebsd-bugs mailing list
URL:
Keywords:
: 204684 (view as bug list)
Depends on:
Blocks:
 
Reported: 2015-11-19 17:05 UTC by Edward Tomasz Napierala
Modified: 2015-12-27 14:39 UTC (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Edward Tomasz Napierala freebsd_committer 2015-11-19 17:05:13 UTC
Trying to boot 11-CURRENT on Sun Blade 2000 (which for some reason reports as SUNW,Sun-Blade-1000), 2 x UltraSPARC-III+, results in the following panic:

panic: mp_setmaxid: one CPU but mp_maxid is not zero

FreeBSD 10.1-RELASE works with no problems.
Comment 1 Edward Tomasz Napierala freebsd_committer 2015-11-19 17:12:41 UTC
*** Bug 204684 has been marked as a duplicate of this bug. ***
Comment 2 Edward Tomasz Napierala freebsd_committer 2015-11-19 17:13:14 UTC
Works fine on 10-STABLE too.
Comment 3 Mark Linimon freebsd_committer freebsd_triage 2015-11-20 02:04:30 UTC
Same on a v245.

Per marius I am going to attempt to revert sys/kern/subr_smp.c via:

https://svnweb.freebsd.org/base/head/sys/kern/subr_smp.c?r1=285771&r2=290547&pathrev=290547
Comment 4 Edward Tomasz Napierala freebsd_committer 2015-11-20 13:31:25 UTC
The patch seems to fix the problem.
Comment 5 commit-hook freebsd_committer 2015-11-21 02:50:13 UTC
A commit references this bug:

Author: marius
Date: Sat Nov 21 02:49:33 UTC 2015
New revision: 291121
URL: https://svnweb.freebsd.org/changeset/base/291121

Log:
  Merge from r290547:
  Since r289279 bufinit() uses mp_ncpus so adapt to what x86 does and
  set this variable already in cpu_mp_setmaxid().
  While at it, rename cpu_cpuid_prop() to cpu_portid_prop() as well as
  the MD cpuid variable to portid to avoid confusion with the MI use
  of "cpuid" and make some variable static/global in order to reduce
  stack usage.

  PR:		204685

Changes:
  head/sys/sparc64/include/md_var.h
  head/sys/sparc64/sparc64/machdep.c
  head/sys/sparc64/sparc64/mp_machdep.c
Comment 6 commit-hook freebsd_committer 2015-12-27 14:39:56 UTC
A commit references this bug:

Author: marius
Date: Sun Dec 27 14:39:48 UTC 2015
New revision: 292771
URL: https://svnweb.freebsd.org/changeset/base/292771

Log:
  MFC: r291121

  Merge from r290547:
  Since r289279 bufinit() uses mp_ncpus so adapt to what x86 does and
  set this variable already in cpu_mp_setmaxid().
  While at it, rename cpu_cpuid_prop() to cpu_portid_prop() as well as
  the MD cpuid variable to portid to avoid confusion with the MI use
  of "cpuid" and make some variable static/global in order to reduce
  stack usage.

  PR:		204685

Changes:
_U  stable/10/
  stable/10/sys/sparc64/include/md_var.h
  stable/10/sys/sparc64/sparc64/machdep.c
  stable/10/sys/sparc64/sparc64/mp_machdep.c