From mboxrd@z Thu Jan 1 00:00:00 1970 From: Paolo Bonzini Subject: Re: [Qemu-devel] [PATCH v5 06/16] apic: Introduce backend/frontend infrastructure for KVM reuse Date: Tue, 20 Dec 2011 14:57:39 +0100 Message-ID: <4EF09453.3030505@redhat.com> References: <4EEFB72E.7030508@codemonkey.ws> <4EEFC970.9030205@web.de> <4EEFD69F.6080700@codemonkey.ws> <4EEFD786.8030609@web.de> <4EEFD90A.1000204@codemonkey.ws> <4EF05BC4.8010905@redhat.com> <4EF09078.2030508@codemonkey.ws> <4EF092D2.6080009@redhat.com> <4EF0937D.3090207@codemonkey.ws> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: kvm@vger.kernel.org, "Michael S. Tsirkin" , Marcelo Tosatti , qemu-devel , Blue Swirl , Jan Kiszka , Avi Kivity To: Anthony Liguori Return-path: Received: from mx1.redhat.com ([209.132.183.28]:65076 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752043Ab1LTN5r (ORCPT ); Tue, 20 Dec 2011 08:57:47 -0500 In-Reply-To: <4EF0937D.3090207@codemonkey.ws> Sender: kvm-owner@vger.kernel.org List-ID: On 12/20/2011 02:54 PM, Anthony Liguori wrote: >> In QOM parlance Jan implemented this: >> >> abstract class Object >> abstract class Device >> class APIC: { backend: link } >> abstract class APICBackend >> class QEMU_APICBackend >> class KVM_APICBackend > > I don't fundamentally object to modeling it like this provided that it's > modeled (and visible) through qdev and not done through a one-off > infrastructure. There is no superclass of DeviceState, hence doing it through qdev would mean introducing a new bus type and so on. This would be a superb example of a useless bus that can disappear with QOM, but I don't see why we should take the pain to add it in the first place. :) We sure can revisit this when the subclassing and interface infrastructures of QOM are merged. Paolo