From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:36280) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZTg2x-0005jX-6u for qemu-devel@nongnu.org; Sun, 23 Aug 2015 20:55:35 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZTg2s-00014l-7x for qemu-devel@nongnu.org; Sun, 23 Aug 2015 20:55:35 -0400 Received: from mx1.redhat.com ([209.132.183.28]:53944) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZTg2r-00010p-Lj for qemu-devel@nongnu.org; Sun, 23 Aug 2015 20:55:29 -0400 References: <27af0665bdcccc032cf477190cad35dd754fc4fb.1439877857.git.zhugh.fnst@cn.fujitsu.com> <20150821225459.GB5816@thinpad.lan.raisama.net> From: Paolo Bonzini Message-ID: <55DA6B7B.2090408@redhat.com> Date: Sun, 23 Aug 2015 17:55:23 -0700 MIME-Version: 1.0 In-Reply-To: <20150821225459.GB5816@thinpad.lan.raisama.net> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [RESEND PATCH v9 1/4] apic: map APIC's MMIO region at each CPU's address space List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Eduardo Habkost , Zhu Guihua Cc: chen.fan.fnst@cn.fujitsu.com, imammedo@redhat.com, izumi.taku@jp.fujitsu.com, qemu-devel@nongnu.org, afaerber@suse.de On 21/08/2015 15:54, Eduardo Habkost wrote: > > + if (tcg_enabled()) { > > + memory_region_add_subregion_overlap(cpu->cpu_as_root, > > + apic->apicbase & > > + MSR_IA32_APICBASE_BASE, > > + &apic->io_memory, > > + 0x1000); > > Why exactly is this necessary? If this is necessary, why don't we need > to do this for non-TCG accelerators? At least KVM and qtest do not support per-CPU address spaces. I'm not sure about Xen, it looks like it could but it would be slower. Paolo