From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KYGEy-0000cv-KT for qemu-devel@nongnu.org; Wed, 27 Aug 2008 04:18:56 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KYGEx-0000ce-4T for qemu-devel@nongnu.org; Wed, 27 Aug 2008 04:18:56 -0400 Received: from [199.232.76.173] (port=48107 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KYGEw-0000cb-UG for qemu-devel@nongnu.org; Wed, 27 Aug 2008 04:18:54 -0400 Received: from il.qumranet.com ([212.179.150.194]:10036) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1KYGEw-00053S-Bb for qemu-devel@nongnu.org; Wed, 27 Aug 2008 04:18:54 -0400 Message-ID: <48B50DEC.3080700@qumranet.com> Date: Wed, 27 Aug 2008 11:18:52 +0300 From: Avi Kivity MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH v2 1/6] Use IO port for qemu<->guest BIOS communication. References: <20080825095800.18703.30602.stgit@gleb-debian.qumranet.com.qumranet.com> <20080825095805.18703.63202.stgit@gleb-debian.qumranet.com.qumranet.com> <48B2C0A1.7040309@codemonkey.ws> <20080825144026.GQ6192@minantech.com> <48B2F373.1020606@codemonkey.ws> <20080826082453.GV6192@minantech.com> <48B459EE.7010101@qumranet.com> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Blue Swirl wrote: >> >> Put the lock in memory. Or even simpler, have the boot cpu extract the >> parameters and place them in memory, and then wake up other cpus. >> > > Where in the memory? Anywhere you like. Of course that doesn't work if you need the information to get memory to work. > What about reset, when all CPUs are online? And > CPUs would need to know if they are the boot CPU or not without > disturbing our IO port. > On x86, reset has once cpu running and the rest in a holding pattern. If your arch has all cpus running on reset, and you can't determine which is cpu 0, you can construct a lock device using mmio which doesn't require any atomic ops. -- error compiling committee.c: too many arguments to function