Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 27 Jul 2004 08:06:51 -0700
From:      Marcel Moolenaar <marcel@xcllnt.net>
To:        "M.M. Yang" <youngdream8039@hotmail.com>
Cc:        freebsd-ia64@freebsd.org
Subject:   Re: "printf" doesn't work in ia64_init()?
Message-ID:  <20040727150651.GA2285@dhcp50.pn.xcllnt.net>
In-Reply-To: <BAY19-F26TZWrGWHVrl00086681@hotmail.com>
References:  <BAY19-F26TZWrGWHVrl00086681@hotmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Jul 27, 2004 at 08:38:00AM +0000, M.M. Yang wrote:
> Hi all,
>   I'm reading the function ia64_init()<sys/ia64/ia64/machdep.c>, and try 
> to use "printf" to output some information. But if I put "printf" before 
> "msgbufinit()", I won't see any word I expect by using dmesg.

That's correct.

>   In the same function after "cninit()", it comments: 
> 	/*
> 	 * Initialize the console before we print anything out.
> 	 */
> 	cninit();
> 
> 	/* OUTPUT NOW ALLOWED */
> 
> So I have thought "printf" should work after cninit(). But now it seems to 
> work only after msgbufinit(). 

printf() does work right after cninit(). The output just doesn't get
saved in the message buffer. Hence, dmesg(8) doesn't show it, but it
certainly gets printed to the system console. Look at the console...

-- 
 Marcel Moolenaar	  USPA: A-39004		 marcel@xcllnt.net



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040727150651.GA2285>