From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:58527) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TB6WL-0004KD-0M for qemu-devel@nongnu.org; Mon, 10 Sep 2012 12:07:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TB6WE-00050v-6N for qemu-devel@nongnu.org; Mon, 10 Sep 2012 12:07:32 -0400 Received: from mx1.redhat.com ([209.132.183.28]:59564) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TB6WD-00050d-Ur for qemu-devel@nongnu.org; Mon, 10 Sep 2012 12:07:26 -0400 Message-ID: <504E1035.3070909@redhat.com> Date: Mon, 10 Sep 2012 18:07:17 +0200 From: Paolo Bonzini MIME-Version: 1.0 References: <1346917367-24691-1-git-send-email-kraxel@redhat.com> <1346917367-24691-4-git-send-email-kraxel@redhat.com> <50487F59.701@redhat.com> <504B1F34.7000101@redhat.com> <87txv5zx1h.fsf@codemonkey.ws> In-Reply-To: <87txv5zx1h.fsf@codemonkey.ws> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 3/4] wakeup: make serial configurable List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Anthony Liguori Cc: Blue Swirl , Peter Maydell , Gerd Hoffmann , qemu-devel@nongnu.org Il 10/09/2012 18:02, Anthony Liguori ha scritto: > I think the wiring is wrong here. Why would a device assert the wakeup > reason? > > I assume on bare metal, the device asserts a single line and then > something devices how to treat the output from a given device. > > IOW, shouldn't it be something more like, SerialState exports a qemu_irq > and then the machine code decides whether to route that irq to a call to > qemu_system_wakeup(). Then depending on whether this is coming from > serial[1], determines which reason is used. But the only way to do it, that works for -device, is to look at the SerialState's iobase. So it would still be a hack, only in ACPI rather than isa-serial.c. Paolo