From owner-svn-src-projects@FreeBSD.ORG Sun May 4 09:56:30 2014 Return-Path: Delivered-To: svn-src-projects@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 837969A4; Sun, 4 May 2014 09:56:30 +0000 (UTC) Received: from nibbler.fubar.geek.nz (nibbler.fubar.geek.nz [199.48.134.198]) by mx1.freebsd.org (Postfix) with ESMTP id 66D1813BE; Sun, 4 May 2014 09:56:30 +0000 (UTC) Received: from bender.Home (97e07ba1.skybroadband.com [151.224.123.161]) by nibbler.fubar.geek.nz (Postfix) with ESMTPSA id 171015DEC1; Sun, 4 May 2014 09:56:27 +0000 (UTC) Date: Sun, 4 May 2014 10:56:08 +0100 From: Andrew Turner To: Bruce Evans Subject: Re: svn commit: r265268 - projects/arm64/sys/arm64/arm64 Message-ID: <20140504105608.70a60909@bender.Home> In-Reply-To: <20140504182755.K1388@besplex.bde.org> References: <201405031527.s43FRUTg019278@svn.freebsd.org> <20140504182755.K1388@besplex.bde.org> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: svn-src-projects@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-projects@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: "SVN commit messages for the src " projects" tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 04 May 2014 09:56:30 -0000 On Sun, 4 May 2014 19:25:06 +1000 (EST) Bruce Evans wrote: > On Sat, 3 May 2014, Andrew Turner wrote: > > > Log: > > Replace panic with printf in spinlock_{enter,exit} as panic makes > > use of spinlocks. > > printf has been broken to use spinlocks too. It used to be careful to > use atomic operations to avoid locking. Most console drivers are > broken too. Some serial ones avoid locking in debugger mode only. This is a stub function. I need to implement it, however I'm working on other parts of the early code and would prefer it if panic at least told me what called it even if it is broken. I'm not yet using a console driver and instead using EARLY_PRINTF with a function that relies on the early boot code mapping the UART with an identity map. This contains no locking and will produce incorrect output when too many characters are sent to it, however as this code is only run on a hardware simulator that appears to output data with no latency this has not been a problem. Andrew