Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 22 Sep 2004 17:36:25 +0900
From:      Pyun YongHyeon <>
Subject:   Re: PR sparc64/71729
Message-ID:  <>
In-Reply-To: <>
References:  <!~!> <>

Next in thread | Previous in thread | Raw E-Mail | Index | Archive | Help
On Mon, Sep 20, 2004 at 07:40:06PM +0900, To wrote:
 > On Fri, Sep 17, 2004 at 09:29:41AM -0400, Doug Haigh wrote:
 >  > 
 >  > I am not sure if the PR got updated, but I wanted to let you know that the
 >  > printf in a kernel thread only fails if you are on a SMP machine. It appears
 >  > that if you printf on a CPU other than CPU #0, it will panic the kernel.
 >  >  
 > After reading your mail, I made a small test program which creates
 > a kernel thread and ran it on AXe(UP) and U2(SMP).
 > Under AXe it worked as expected but it paniced on U2.
 > So it seems that there is some issues in OF console.
 > Backtrace for the panic is somthing like:

While looking into the ofw_console(4) code I noticed there is
possible races there. So I patched the code and ran it. However
it didn't fix the problem. Since we can't simply use a mutex in
ofw_cons_putc(), there should be other way to workaround this.
Have no idea yet.

If you really really want to see your messages from a kernel
thread you can do one of the following(tested on U2):

1. remove invocation of timeout(9) in ofw_console.c. With this
   modification, you can't enter characters with keyboard.

2. use sc + creator + uart + puc instead of ofw_console(4)
   On my U2, keyboard input didn't work.

If you want to see my partial patch as a starting point please let
me know.

Pyun YongHyeon
Pyun YongHyeon <>;

Want to link to this message? Use this URL: <>