Received: from eggs.gnu.org ([2001:4830:134:3::10]:56430) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WnT84-0005Ek-Hf for qemu-devel@nongnu.org; Thu, 22 May 2014 09:33:57 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WnT7w-0005nt-Jv for qemu-devel@nongnu.org; Thu, 22 May 2014 09:33:52 -0400 Received: from mx1.redhat.com ([209.132.183.28]:54412) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WnT7w-0005nS-9m for qemu-devel@nongnu.org; Thu, 22 May 2014 09:33:44 -0400 Date: Thu, 22 May 2014 15:33:36 +0200 From: Igor Mammedov Message-ID: <20140522153336.5218c5f7@nial.usersys.redhat.com> In-Reply-To: <05953EE18EEC9148BE892F38DF8F8E8E5ED412@G08CNEXMBPEKD03.g08.fujitsu.local> References: <05953EE18EEC9148BE892F38DF8F8E8E5ED412@G08CNEXMBPEKD03.g08.fujitsu.local> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [RFC 0/3] cpu: add device_add foo-x86_64-cpu support List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "chen.fan.fnst@cn.fujitsu.com" Cc: "qemu-devel@nongnu.org" , Eduardo Habkost , Andreas =?ISO-8859-1?B?RuRyYmVy?= On Thu, 22 May 2014 02:33:45 +0000 "chen.fan.fnst@cn.fujitsu.com" wrote: > Hi, > I think if we want to use 'device/device_add' to implement CPU, > we must do some check before qemu_init_vcpu(). how can we to do that? What check exactly would you like to perform? For target-i38 you can look for kvm_check_features_against_host() in x86_cpu_realizefn() doing check before qemu_init_vcpu(). >=20 > Thanks, > Chen >=20 > On Tue, 2014-05-13 at 18:08 +0800, Chen Fan wrote:=20 > > this patches tried to make cpu hotplug with device_add,=20 > > and made -device foo-x86_64-cpu available=EF=BC=8Calso we can > > set apic-id property with command line, if without setting > > apic-id property, we added first unoccupied apic id as the > > default new apic id. and hotplug cpu with device_add, we > > must make check of APIC ID after cpu object initialization > > that was different from 'cpu_add' command which check 'ids' > > at the beginning. > >=20 > > Chen Fan (3): > > using CPUMASK bitmaps to calculate cpu index > > cpu: introduce CpuTopoInfo structure for argument simplification > > cpu: add device_add foo-x86_64-cpu support > >=20 > > exec.c | 9 +++-- > > include/qom/cpu.h | 11 ++++++ > > include/sysemu/sysemu.h | 7 ---- > > qdev-monitor.c | 11 ++++++ > > target-i386/cpu.c | 91 +++++++++++++++++++++++++++++++++++++++++= +++++++- > > target-i386/topology.h | 51 ++++++++++++++++++--------- > > 6 files changed, 151 insertions(+), 29 deletions(-) > >=20 >=20