From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:48487) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TB7dw-0006ji-RE for qemu-devel@nongnu.org; Mon, 10 Sep 2012 13:19:32 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TB7dv-0003ei-Ho for qemu-devel@nongnu.org; Mon, 10 Sep 2012 13:19:28 -0400 Received: from mail-oa0-f45.google.com ([209.85.219.45]:53758) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TB7dv-0003eW-Di for qemu-devel@nongnu.org; Mon, 10 Sep 2012 13:19:27 -0400 Received: by oagn12 with SMTP id n12so602562oag.4 for ; Mon, 10 Sep 2012 10:19:26 -0700 (PDT) From: Anthony Liguori In-Reply-To: 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> <504E1035.3070909@redhat.com> Date: Mon, 10 Sep 2012 12:19:23 -0500 Message-ID: <87392pyew4.fsf@codemonkey.ws> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Subject: Re: [Qemu-devel] [PATCH 3/4] wakeup: make serial configurable List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell , Paolo Bonzini Cc: Blue Swirl , Gerd Hoffmann , qemu-devel@nongnu.org Peter Maydell writes: > On 10 September 2012 17:07, Paolo Bonzini wrote: >> Il 10/09/2012 18:02, Anthony Liguori ha scritto: >>> 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. > > This just says that -device is broken (which we kinda already knew > :-)) There are opposing forces here. libvirt wants to use -device because we don't provide a way for machine creates devices to be configurable. We can't fix this until we separate realization from initialization. After that point, libvirt could address properties on machine-created devices directly. I think the best short term solution is to have a post '-device' handler in machines that could be used to make the appropriate connections. Power et al. need this anyway for dealing with device tree creation so it seems to be inevitable. Regards, Anthony Liguori > > -- PMM