Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 31 May 2011 09:18:39 -0400
From:      John Baldwin <jhb@freebsd.org>
To:        Nathan Whitehorn <nwhitehorn@freebsd.org>
Cc:        svn-src-projects@freebsd.org, src-committers@freebsd.org
Subject:   Re: svn commit: r222356 - projects/pseries/kern
Message-ID:  <201105310918.39239.jhb@freebsd.org>
In-Reply-To: <4DE3FCA0.2000400@freebsd.org>
References:  <201105271427.p4RERSUb039281@svn.freebsd.org> <201105271202.04421.jhb@freebsd.org> <4DE3FCA0.2000400@freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Monday, May 30, 2011 4:22:56 pm Nathan Whitehorn wrote:
> On 05/27/11 11:02, John Baldwin wrote:
> > On Friday, May 27, 2011 10:27:28 am Nathan Whitehorn wrote:
> >> Author: nwhitehorn
> >> Date: Fri May 27 14:27:28 2011
> >> New Revision: 222356
> >> URL: http://svn.freebsd.org/changeset/base/222356
> >>
> >> Log:
> >>    On multi-core, multi-threaded PPC systems, it is important that the threads
> >>    be brought up in the order they are enumerated in the device tree (in
> >>    particular, that thread 0 on each core be brought up first). The SLIST
> >>    through which we loop to start the CPUs has all of its entries added with
> >>    SLIST_INSERT_HEAD(), which means it is in reverse order of enumeration
> >>    and so AP startup would always fail in such situation (causing a machine
> >>    check or RTAS failure).
> >>
> >>    The best fix is probably to change this from a LIST to a TAILQ, but fix
> >>    this by looping through to add new cpus to the end of the list.
> > Just make it a STAILQ.  That has a STAILQ_INSERT_TAIL() method and doesn't
> > change the ABI of 'struct pcpu'.  It just adds an extra pointer to the head.
> 
> I did that, and it works well. A patch against HEAD can be found at
> http://people.freebsd.org/~nwhitehorn/pcpu_tailq.diff. Let me know if it 
> looks OK (or if there are any objections to committing it).

Looks good to me, go for it.

-- 
John Baldwin



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201105310918.39239.jhb>