On Fri, Aug 03, 2001 at 02:15:54PM -0700, John D. Davis wrote:
> Does anyone know off hand, the earlies point that I can use printk? I
> added some printk statements to driver/char/console.c and the resulting
> kernel hangs with only the logo showing and no text. Is prom_printf
> something that I should use instead. I put some printk statements in
> tty_io.c and kernel/printk.c and those compiled kernels work.
>
> thanks,
> john davis
>
Like other folks from this list have pointed out, you can use
it as early as the first C line. The output is stored in a memory
buffer and later displayed on your screen when your serial console
is registered.
When porting to a new machine, I often use dev-only patch (i.e.,
not meant to be checked in) to enable seeing printk immediately, *if*
it is a standard UART port. See the attache patch below.
I don't recommand use or implement prom_printf.
Jun
early-printk.patch
Description: Text document
|