All of lore.kernel.org
 help / color / mirror / Atom feed
* RE: KDB in the mainstream 2.4.x kernels?
@ 2003-09-02 20:40 Tolentino, Matthew E
  0 siblings, 0 replies; 19+ messages in thread
From: Tolentino, Matthew E @ 2003-09-02 20:40 UTC (permalink / raw)
  To: Pavel Machek, Alan Cox
  Cc: Andi Kleen, Greg Stark, Martin Pool, Linux Kernel Mailing List


> > > > instructions as a forth program that frobbed registers 
> appropriately. The
> > > > kernel would have a small forth interpretor to run it. 
> Then switching
> > > > resolutions could happen safely in the kernel.
> > > 
> > > Did the proposal come with working code?
> > 
> > I've seen workable non forth versions of the proposal yes. It isnt 
> > actually that hard to do for most video cards 
> 
> We could make them use code for ACPI interpretter, that's already in
> and has advantage that graphics people might eventually ship it in
> card roms....

The reason I was asking before was because I've been working on a kernel implementation of the EBC (EFI Byte Code) interpreter so that one could employ the use of the UGA (Universal Graphics Adapter) at OS runtime instead of having to rely on VGA (BIOS or hardware) support.  UGA is essentially an EFI driver (aka option ROM) that is intended to be used in pre-OS boot space as well as during OS runtime.  When built as an EBC image the driver can be interpreted and thus used on any platform. 

The UGA protocols defined in the EFI spec enable the capability to perform the mode switching mentioned above.  I hate to keep pointing at ia64, but Tiger systems currently ship with a minimal UGA driver for the embedded ATI controller (this can be seen with the EFI command drivers) and x86 systems with EFI firmware will as well (in addition to traditional VGA support). 

Although this doesn't resolve the immediate issue, this might provide the support needed in the future... 

matt

^ permalink raw reply	[flat|nested] 19+ messages in thread
* RE: KDB in the mainstream 2.4.x kernels?
@ 2003-08-28 17:08 Tolentino, Matthew E
  2003-08-28 20:24 ` Alan Cox
  0 siblings, 1 reply; 19+ messages in thread
From: Tolentino, Matthew E @ 2003-08-28 17:08 UTC (permalink / raw)
  To: Alan Cox, Andi Kleen; +Cc: Greg Stark, Martin Pool, Linux Kernel Mailing List

> On Llu, 2003-08-25 at 17:23, Andi Kleen wrote:
> > > instructions as a forth program that frobbed registers 
> appropriately. The
> > > kernel would have a small forth interpretor to run it. 
> Then switching
> > > resolutions could happen safely in the kernel.
> > 
> > Did the proposal come with working code?
> 
> I've seen workable non forth versions of the proposal yes. It isnt 
> actually that hard to do for most video cards 

Interesting.  So did the interpreted forth (or other) program then interact with the VGA BIOS or was it more generic? 

matt

^ permalink raw reply	[flat|nested] 19+ messages in thread
* KDB in the mainstream 2.4.x kernels?
@ 2003-07-18 20:06 linas
  0 siblings, 0 replies; 19+ messages in thread
From: linas @ 2003-07-18 20:06 UTC (permalink / raw)
  To: linux-kernel


                                                                                
Hi,
                                                                                
Will there be a day that I can expect to find KDB in the 2.4.x kernel?
I know that a traditional answer has been 'never', but I would like the
various influencers and decision makers to reconsider ...
                                                                                
I agree with Linus Torvalds that debuggers are 100% useless when you
are working on code that you know intimately.  I know, I've written a
lot of code, I'm proud of it, and I sneer at people who use words like
'development environment'.   Crap, if you can't figure out why your
code crashed, you shouldn't be a programmer.  But these days, I am not
debugging my code. I'm debugging code that I've never seen before.
And for that, I use KDB.
                                                                                
Right now, I work in a job where the *only* thing that I do is to analyze
and sometimes (when I'm lucky) fix kernel crashes.   Its all I do.
I don't write any new code, don't do any porting at all.  I also don't
debug any 2.5/2.6 'unstable' kernels, nor do I handle any new/unstable
device drivers.  I focus entirely on the 2.4.x kernels, and, with a
small team here, there are more than enough kernel bugs to keep us all
completely busy.  The crashes are generated by a test team of 8 people
with dozens of machines.   Ostensibly their mission is to test new
hardware, but in fact, almost all the crashes that they find are kernel
bugs.  The *only* thing that the test team does is to run stress tests.
Basic stuff. Kernel stress. File create/delete/copy. Reiser, jfs, ext3,
swap, OOM, scsi. Network, nfs, samba.   Some tests take hours to crash
the kernel, some take days.   But the kernel crashes. Its always crashing.
Corruption, races, missing locks, typos, bad hardware, you name it.
When I get it, it has a KDB prompt in front of it.  KDB is great.
I can figure out where it crashed, I can look at the assembly, I can
examine memory locations. I can chase pointers by hand.  And I can
do it all symbolically, with the symbol names in front of me.  Now,
KDB rarely points right at the bug, but it is invaluable for figuring
out where to start looking.  Sometimes I even find the bug, often
I don't.  But anyway, this is all academic, because its at work, in
a controlled environment, where I have the time and resources I need.
                                                                                
But the real reason I write this note is that I want to have the same
capability at home.  It suddenly occurred to me that the servers I run
at home sometimes (rarely) crash with the same symptoms as those at work.
Sure, I can probably blame buggy PC hardware.  But .. I dunno.  I've been
consistently ignoring these crashes cause its just too much of a hassle
to try to debug them.  Its not worth the effort.   But hey ... if I had
KDB at home... maybe it would be worth looking into the hangs. I could
see getting motivated to look into some of these.  At least get some
idea of where the machine got hung.  Maybe no fix, but at least
somewhere to lay the blame.
                                                                                
Yes, of course I could just apply the KDB patches myself, but frankly
its a hassle.  I already play the patch game and I hate it. Every new
kernel, I have to try to remember where to find patch x, how to apply
it, fix up this and that... its just plain painful.
                                                                                
I know that this is not a forceful argument.  But crashes are a fact of
life, whatever the reason may be.  And the crashes almost always happen
in a piece of code I have *never* laid eyes on before, so its unrealistic
to try to puzzle it out with the small dollop of info from magic-sysreq.
Debuggers can be useless, or worse than useless, when you are a developer
on a piece of code you know well.  But when plunging into foreign territory,
all the tools and firepower that you can muster are worth every bit.
This is why KDB belongs in the mainstream kernel distros.
                                                                                
--linas
                                                                                


^ permalink raw reply	[flat|nested] 19+ messages in thread

end of thread, other threads:[~2003-09-02 20:40 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <aJIn.3mj.15@gated-at.bofh.it>
2003-07-18 20:43 ` KDB in the mainstream 2.4.x kernels? Andi Kleen
2003-07-19  0:31   ` linas
2003-07-19  0:57     ` Andi Kleen
2003-07-20 12:55   ` Keith Owens
2003-07-20 13:31     ` David S. Miller
2003-07-20 22:27       ` Keith Owens
2003-07-21 15:06     ` Andi Kleen
2003-07-29 19:44   ` Robin Holt
2003-08-13  4:40   ` Martin Pool
2003-08-13 11:04     ` Andi Kleen
2003-08-25 12:16       ` Greg Stark
2003-08-25 16:23         ` Andi Kleen
2003-08-26 13:39           ` Greg Stark
2003-08-27 13:49           ` Alan Cox
2003-08-30 10:35             ` Pavel Machek
2003-09-02 20:40 Tolentino, Matthew E
  -- strict thread matches above, loose matches on Subject: below --
2003-08-28 17:08 Tolentino, Matthew E
2003-08-28 20:24 ` Alan Cox
2003-07-18 20:06 linas

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.