From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jan Kiszka Subject: Re: [PATCH 20/21] qemu-kvm: Move kvm_set_boot_cpu_id Date: Tue, 02 Feb 2010 15:33:37 +0100 Message-ID: <4B6837C1.7000006@siemens.com> References: <363f516310b5e3fbdb2f4461d725d7e0406a6fef.1265098708.git.jan.kiszka@siemens.com> <20100202141119.GG739@redhat.com> <4B683492.8010703@siemens.com> <20100202142830.GH739@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: Avi Kivity , Marcelo Tosatti , "kvm@vger.kernel.org" , Anthony Liguori , Alexander Graf , Glauber Costa , "qemu-devel@nongnu.org" To: Gleb Natapov Return-path: Received: from david.siemens.de ([192.35.17.14]:21640 "EHLO david.siemens.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752477Ab0BBOeA (ORCPT ); Tue, 2 Feb 2010 09:34:00 -0500 In-Reply-To: <20100202142830.GH739@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: Gleb Natapov wrote: > On Tue, Feb 02, 2010 at 03:20:02PM +0100, Jan Kiszka wrote: >> Gleb Natapov wrote: >>> On Tue, Feb 02, 2010 at 09:19:06AM +0100, Jan Kiszka wrote: >>>> Setting the boot CPU ID is arch-specific KVM stuff. So push it where it >>>> belongs to. >>>> >>> pc_init1 is also arch-specific, no? TCG should also be able to >>> have BSP apic_id != 0. >> But not kvm-specific. >> >> I don't understand your second remark. Can you help me how TCG is >> affected by kvm_set_boot_cpu_id? >> > It is not affected right now. It assumes that apic ID of BSP cpu is 0, > but this limitation does not exists on real HW. So when QEMU will be fixed > and it will be possible to configure what CPU is BSP this will be the > pace to do it. That day pc_init1 (or whatever x86 part) will set the bsp number somewhere in env or apicstate, and we will transfer that afterwards to kvm. The point is that kvm_* belongs into kvm[-all].c as far as possible. And in this case it is possible. Jan -- Siemens AG, Corporate Technology, CT T DE IT 1 Corporate Competence Center Embedded Linux From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NcJp0-0000hp-Px for qemu-devel@nongnu.org; Tue, 02 Feb 2010 09:33:42 -0500 Received: from [199.232.76.173] (port=46530 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NcJp0-0000hS-FD for qemu-devel@nongnu.org; Tue, 02 Feb 2010 09:33:42 -0500 Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1NcJoz-0000TZ-2b for qemu-devel@nongnu.org; Tue, 02 Feb 2010 09:33:42 -0500 Received: from david.siemens.de ([192.35.17.14]:21529) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1NcJoy-0000TL-KU for qemu-devel@nongnu.org; Tue, 02 Feb 2010 09:33:40 -0500 Message-ID: <4B6837C1.7000006@siemens.com> Date: Tue, 02 Feb 2010 15:33:37 +0100 From: Jan Kiszka MIME-Version: 1.0 References: <363f516310b5e3fbdb2f4461d725d7e0406a6fef.1265098708.git.jan.kiszka@siemens.com> <20100202141119.GG739@redhat.com> <4B683492.8010703@siemens.com> <20100202142830.GH739@redhat.com> In-Reply-To: <20100202142830.GH739@redhat.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: [Qemu-devel] Re: [PATCH 20/21] qemu-kvm: Move kvm_set_boot_cpu_id List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Gleb Natapov Cc: Anthony Liguori , "kvm@vger.kernel.org" , Glauber Costa , Marcelo Tosatti , Alexander Graf , "qemu-devel@nongnu.org" , Avi Kivity Gleb Natapov wrote: > On Tue, Feb 02, 2010 at 03:20:02PM +0100, Jan Kiszka wrote: >> Gleb Natapov wrote: >>> On Tue, Feb 02, 2010 at 09:19:06AM +0100, Jan Kiszka wrote: >>>> Setting the boot CPU ID is arch-specific KVM stuff. So push it where it >>>> belongs to. >>>> >>> pc_init1 is also arch-specific, no? TCG should also be able to >>> have BSP apic_id != 0. >> But not kvm-specific. >> >> I don't understand your second remark. Can you help me how TCG is >> affected by kvm_set_boot_cpu_id? >> > It is not affected right now. It assumes that apic ID of BSP cpu is 0, > but this limitation does not exists on real HW. So when QEMU will be fixed > and it will be possible to configure what CPU is BSP this will be the > pace to do it. That day pc_init1 (or whatever x86 part) will set the bsp number somewhere in env or apicstate, and we will transfer that afterwards to kvm. The point is that kvm_* belongs into kvm[-all].c as far as possible. And in this case it is possible. Jan -- Siemens AG, Corporate Technology, CT T DE IT 1 Corporate Competence Center Embedded Linux