Fwd: Re: WCHAN wrong for i386-kernel

From: Gerhard Kurz
Date: Sun Apr 01 2007 - 15:29:30 EST




------- Forwarded message -------
From: "Ingo Molnar" <mingo@xxxxxxx>
To: "Gerhard Kurz" <gerhard.kurz@xxxxxx>
Cc:
Subject: Re: WCHAN wrong for i386-kernel
Date: Sun, 01 Apr 2007 20:30:49 +0200


* Gerhard Kurz <gerhard.kurz@xxxxxx> wrote:

Hi,

There is a minor bug in kernels for i386 (i found it in 2.6.14.2, but
looking at the source code of 2.6.20, it should be there also).

Symptom: For a task that sleeps e.g. in sys_nanosleep, the wchan value
from get_wchan (in arch/i386/kernel/process.c) is wrong.

Reason: To get the correct wchan value, all __sched functions must
have a framepointer. Currently only the functions in kernel/sched.c
are compiled with -fno-omit-frame-pointer. (see kernel/Makefile)

But sys_nanosleep calls schedule_timeout_interruptible (in
kernel/timer.c), which doesn't have a framepointer.

ah, indeed - nice find!

could you please report this to lkml too? It should be fixed, and by
sending it to lkml we make it sure that someone picks it up eventually,
if i dont get around fixing it in time.

Ingo


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