Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 14 Dec 2004 21:46:44 -0500
From:      John Baldwin <jhb@FreeBSD.org>
To:        Nate Lawson <nate@root.org>
Cc:        cvs-all@FreeBSD.org
Subject:   Re: cvs commit: src/sys/i386/i386 vm_machdep.c
Message-ID:  <200412142146.44653.jhb@FreeBSD.org>
In-Reply-To: <41BF6F44.2090407@root.org>
References:  <200411300618.iAU6IkQX065609@repoman.freebsd.org> <200412141719.10701.jhb@FreeBSD.org> <41BF6F44.2090407@root.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tuesday 14 December 2004 05:55 pm, Nate Lawson wrote:
> John Baldwin wrote:
> > On Tuesday 14 December 2004 03:11 pm, Nate Lawson wrote:
> >>John Baldwin wrote:
> >>>On Tuesday 30 November 2004 01:18 am, Nate Lawson wrote:
> >>>>njl         2004-11-30 06:18:46 UTC
> >>>>
> >>>> FreeBSD src repository
> >>>>
> >>>> Modified files:
> >>>>   sys/i386/i386        vm_machdep.c
> >>>> Log:
> >>>> MFamd64:  Remove the cpu_reset_proxy cruft now that we run boot() on
> >>>> cpu 0.  Also, restructure cpu_reset to be cleaner (no functional
> >>>>change.)
> >>>
> >>>FYI, this breaks the 'reset' command from ddb if you panic on a cpu
> >>> other than the BSP.  boot() isn't the only function that calls
> >>> cpu_reset(), so perhaps this should be reverted (same for amd64)
> >>
> >>No, I think we should move forward instead of backward.  Entering the
> >>debugger should happen on the BSP and possibly other cpus need to be
> >>stopped by panic().
> >
> > Erm, well, that's not always easy since sometimes when you panic you
> > can't talk to the other CPUs for whatever reason.  Putting back the proxy
> > reset doesn't hurt for now but does restore functionality in at least
> > some cases. I'd rather have that then certain hard panics not get into
> > ddb because we couldn't get onto the BSP to run ddb.
>
> Perhaps you could give me some pointers on what is counted on to be
> working when panic() is called?  I can't come up with a situation where
> the proxy code couldn't be used upon entry to ddb.  If there were any
> cases like this, the proxy code wouldn't work for cpu_reset() either.
> Also, in such a case, it's hard to see how ddb could be usable since it
> tries to stop other processors, which requires similar code to the proxy.
>
> Or in other words, if you have enough capability to call panic() or
> break to ddb, then you have enough resources to do an IPI and get onto
> the BSP.

You can assume nothing once you do a panic().  I'd just like reset to have a 
chance of working and don't want to add anything extra to the path to get 
into ddb.  If I had to choose, I'd rather people be able to get into ddb but 
not reboot remotely so that they can do debugging than to have reset always 
work.  However, it doesn't hurt to add the extra proxy stuff back in to 
maximize the number of cases that work.  Basically, I don't want to risk 
losing the ability for people to get into ddb when a panic happens because of 
IPI problems, but if someone does get into ddb, it would be nice if reset at 
least had some chance of working when called from an AP.

-- 
John Baldwin <jhb@FreeBSD.org>  <><  http://www.FreeBSD.org/~jhb/
"Power Users Use the Power to Serve"  =  http://www.FreeBSD.org



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