From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [Qemu-devel] [PATCH 28/35] kvm: x86: Introduce kvmclock device to save/restore its state Date: Tue, 25 Jan 2011 12:27:53 +0200 Message-ID: <4D3EA5A9.1010408@redhat.com> References: <4D2B6CB5.9050602@codemonkey.ws> <4D2B74D8.4080309@web.de> <4D2B8662.9060909@web.de> <4D2C60FB.7030009@linux.vnet.ibm.com> <4D2D80ED.8030405@redhat.com> <4D2D82EE.20002@siemens.com> <4D35A39A.8000801@siemens.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Anthony Liguori , Markus Armbruster , Marcelo Tosatti , Glauber Costa , kvm@vger.kernel.org, qemu-devel@nongnu.org To: Jan Kiszka Return-path: Received: from mx1.redhat.com ([209.132.183.28]:65269 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751547Ab1AYK2C (ORCPT ); Tue, 25 Jan 2011 05:28:02 -0500 In-Reply-To: <4D35A39A.8000801@siemens.com> Sender: kvm-owner@vger.kernel.org List-ID: On 01/18/2011 04:28 PM, Jan Kiszka wrote: > > > > So we can either "infect" the whole device tree with kvm (or maybe a > > more generic accelerator structure that also deals with Xen) or we need > > to pull the reference inside the device's init function from some global > > service (kvm_get_state). > > Note that this topic is still waiting for good suggestions, specifically > from those who believe in kvm_state references :). This is not only > blocking kvmstate merge but will affect KVM irqchips as well. I'm one of them, but I don't have anything better to suggest than adding "kvm_state" attribute to qdev, which seems mighty artificial. So I'm in favour of eliminating it now. > It boils down to how we reasonably pass a kvm_state reference from > machine init code to a sysbus device. I'm probably biased, but I don't > see any way that does not work against the idea of confining access to > kvm_state or breaks device instantiation from the command line or a > config file. I'm biased in the other direction, but I agree. -- error compiling committee.c: too many arguments to function