From owner-freebsd-hackers@FreeBSD.ORG Wed Oct 6 23:43:25 2004 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 476E916A4CE for ; Wed, 6 Oct 2004 23:43:25 +0000 (GMT) Received: from blackwater.lemis.com (wantadilla.lemis.com [192.109.197.135]) by mx1.FreeBSD.org (Postfix) with ESMTP id C09BC43D4C for ; Wed, 6 Oct 2004 23:43:23 +0000 (GMT) (envelope-from grog@lemis.com) Received: by blackwater.lemis.com (Postfix, from userid 1004) id 966028565F; Thu, 7 Oct 2004 08:39:54 +0930 (CST) Date: Thu, 7 Oct 2004 08:39:54 +0930 From: Greg 'groggy' Lehey To: Roman Kurakin Message-ID: <20041006230954.GO1350@wantadilla.lemis.com> References: <41645625.3020209@cronyx.ru> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="MM5RgFPKyuP3gDcV" Content-Disposition: inline In-Reply-To: <41645625.3020209@cronyx.ru> User-Agent: Mutt/1.4.2.1i Organization: The FreeBSD Project Phone: +61-8-8388-8286 Fax: +61-8-8388-8725 Mobile: +61-418-838-708 WWW-Home-Page: http://www.FreeBSD.org/ X-PGP-Fingerprint: 9A1B 8202 BCCE B846 F92F 09AC 22E6 F290 507A 4223 cc: hackers@FreeBSD.org Subject: Re: Printing from kernel X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 06 Oct 2004 23:43:25 -0000 --MM5RgFPKyuP3gDcV Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Thursday, 7 October 2004 at 0:31:33 +0400, Roman Kurakin wrote: > Hi, > > I have some problems with printing from kernel. > At first I think that my problems was cause I use printf, > but changed all of them to log cause it safe to use from > interrupt handlers. The situation become better but I still > observe system lockup in case I output some debug information > from my driver. About the only thing I can think is that you're doing this in some area where it's unsafe to print, probably holding a lock that's needed in the print routines. > Also I have some problems with system console via com > port. Instead of messages from kernel I see the first letter > of the month name. > > Could anybody comment my observation? Without more detail, it's impossible to help. > Does anybody saw anything like this? No. printf() is widely used in the kernel. > Oh, I forget to say I observe that with both Current > and Releng5, SMP. Also I can't trigger NMI so I can't see the > point of lockup. Take a look at your code and check what locks you're holding. Also, if this is only for debugging, you should be using the kernel debugger. Greg -- See complete headers for address and phone numbers. --MM5RgFPKyuP3gDcV Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.6 (FreeBSD) iD8DBQFBZHtCIubykFB6QiMRAgrXAJ40ABfpO+8zaPfgAUU+o/FfsJLlOACgofdD U5eauZVejXjRf612kQW/zQU= =xUSo -----END PGP SIGNATURE----- --MM5RgFPKyuP3gDcV--