From owner-freebsd-current Sat Oct 13 9:43:46 2001 Delivered-To: freebsd-current@freebsd.org Received: from flood.ping.uio.no (flood.ping.uio.no [129.240.78.31]) by hub.freebsd.org (Postfix) with ESMTP id 98BAD37B447 for ; Sat, 13 Oct 2001 09:39:41 -0700 (PDT) Received: by flood.ping.uio.no (Postfix, from userid 2602) id 51A5514C3E; Sat, 13 Oct 2001 18:39:40 +0200 (CEST) X-URL: http://www.ofug.org/~des/ X-Disclaimer: The views expressed in this message do not necessarily coincide with those of any organisation or company with which I am or have been affiliated. To: Sheldon Hearn Cc: Doug Barton , freebsd-current@FreeBSD.ORG Subject: Re: Strike three, you're out References: <23451.1002990940@axl.seasidesoftware.co.za> From: Dag-Erling Smorgrav Date: 13 Oct 2001 18:39:39 +0200 In-Reply-To: <23451.1002990940@axl.seasidesoftware.co.za> Message-ID: Lines: 14 User-Agent: Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Sheldon Hearn writes: > Perhaps the analogous solution is to be more careful about the use of > printf() in the kernel? Perhaps a similar approach as is used in > userland signal handlers should be taken, where a flag is set and later > the printf() is performed conditional on the state of the flag? I think the correct approach would be for printf() to store the printed text in a circular buffer if it detected that printing it would cause a locking violation, and for some other part of the kernel to check and empty the circular buffer regularly, in a safe context. DES -- Dag-Erling Smorgrav - des@ofug.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message