On Tue, Feb 12, 2008 at 04:28:46PM +0100, Ingo Molnar wrote:
> 
> * Andi Kleen <[EMAIL PROTECTED]> wrote:
> 
> > > do spinning for now: we dont _ever_ want to break a correctly 
> > > working system with kgdb.
> > 
> > Stopping all CPUs for indefinite time very much seems like "breaking a 
> > correctly working system" to me. [...]
> 
> well, this is a small detail, but still you are wrong, and on a 
> correctly working system this will not occur. (if yes, tell me how)
> 
> KGDB does a very straightforward "all CPUs enter controlled state" 
> transition when the session begins, and at the end an "all CPUs 
> continue" transition.

Yes and the session has no fixed time limit.

> 
> I'm not sure what you mean exactly under "stopping all CPUs for 
> indefinite amount of time" (your statement is sufficiently vague to be 

Stopping with interrupts off. Nothing scheduled anymore. 

An easy definition for the condition is anything that requires 
touch_{nmi,softlockup}_watchdog [which kgdb definitely does, 
although in a quite convoluted way]

> yes, we could "time out" and force a KGDB session even if some CPUs do 
> not respond. But it's obviously not a completely safe system state, 
> because other CPUs might be changing things under the feet of the 
> debugger. So the safest first-level approach is to not enter the 

While that is a slight risk that problem is already there anyways.
Lots of agents in the system could do that. Do you plan to stop
all DMA too for example if you're so worried about this? 
Or how about SMM code changing something? 

Anyways the slight risk of the other CPUs eventually recovering
would seem a acceptable trade off versus not being able to use
the debugger to debug the system with hanging CPUs. 

A possible compromise between my and your position on this would 
be also having an option for this, with default to off
(although I would expect that would be a inconvenient default for
many people)

-Andi (who retires from this thread now, I already spent too much on this)

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to