kdb
[Top] [All Lists]

Re: [kdb] Back porting of backtrace code into an older kernel

To: Dan Ben-Yaacov <danby@xxxxxxxxxxxxxx>
Subject: Re: [kdb] Back porting of backtrace code into an older kernel
From: Martin Hicks <mort@xxxxxxx>
Date: Tue, 15 Dec 2009 07:52:35 -0600
Cc: "kdb@xxxxxxxxxxx" <kdb@xxxxxxxxxxx>
In-reply-to: <844300ACDC2B4F41B224A576A9DFEA7B3B10C66870@xxxxxxxxxxxxxxxxxxxxxxxxx>
References: <844300ACDC2B4F41B224A576A9DFEA7B3B10C66870@xxxxxxxxxxxxxxxxxxxxxxxxx>
User-agent: Mutt/1.5.17 (2007-11-01)
On Tue, Dec 15, 2009 at 11:40:07AM +0200, Dan Ben-Yaacov wrote:
> Hi,
> 
> I've back ported the new KDB backtrace code into an older kernel.
> 
> My question regards both bb_spurious[] and  bb_special_cases[] - I
> have a kernel based on 2.6.18. I'm pretty sure that both somewhat
> mismatch my kernel version and I'm pretty sure it affects quality of
> produced backtrace.

Yes, it absolutely will.  If the assumptions laid out in those two
arrays are out of date then the fancy backtrace code will likely give up
and revert to the old method.

> 
> What should I look for in order of aligning both bb_spurious[] and
> bb_special_cases[] with my kernel?

In short, you'll hate your life.

You essentially need to understand the state of the registers for those
special case functions (every function implemented in asm that doesn't
use the standard C calling convention).

It will be a significant amount of work.  Reading the docs in
Documentation/kdb/bt_x86 is a good place to start.  bb_all will point
out which functions you need to fix or add to the lists...
mh

<Prev in Thread] Current Thread [Next in Thread>