From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754394AbcBDKHP (ORCPT ); Thu, 4 Feb 2016 05:07:15 -0500 Received: from smtp02.citrix.com ([66.165.176.63]:41406 "EHLO SMTP02.CITRIX.COM" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751185AbcBDKHM (ORCPT ); Thu, 4 Feb 2016 05:07:12 -0500 X-IronPort-AV: E=Sophos;i="5.22,395,1449532800"; d="scan'208";a="336031324" Subject: Re: [Xen-devel] [PATCH v2 07/11] xen/hvmlite: Initialize context for secondary VCPUs To: Boris Ostrovsky , David Vrabel , References: <1454341137-14110-1-git-send-email-boris.ostrovsky@oracle.com> <1454341137-14110-8-git-send-email-boris.ostrovsky@oracle.com> <56B0D786.7000002@citrix.com> <56B0E046.6050900@oracle.com> CC: , , , From: David Vrabel Message-ID: <56B322CE.6050701@citrix.com> Date: Thu, 4 Feb 2016 10:07:10 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Icedove/38.5.0 MIME-Version: 1.0 In-Reply-To: <56B0E046.6050900@oracle.com> Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 7bit X-DLP: MIA2 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 02/02/16 16:58, Boris Ostrovsky wrote: > On 02/02/2016 11:21 AM, David Vrabel wrote: >> This needs some more description in the commit message. >> >>> --- a/arch/x86/xen/smp.c >>> +++ b/arch/x86/xen/smp.c >> [...] >>> + hctxt->cpu_regs.x86_32.cs_base = 0; >>> + hctxt->cpu_regs.x86_32.cs_limit = ~0u; >>> + hctxt->cpu_regs.x86_32.cs_ar = 0xc9b; >>> + hctxt->cpu_regs.x86_32.ds_base = 0; >>> + hctxt->cpu_regs.x86_32.ds_limit = ~0u; >>> + hctxt->cpu_regs.x86_32.ds_ar = 0xc93; >>> + hctxt->cpu_regs.x86_32.es_base = 0; >>> + hctxt->cpu_regs.x86_32.es_limit = ~0u; >>> + hctxt->cpu_regs.x86_32.es_ar = 0xc93; >>> + hctxt->cpu_regs.x86_32.ss_base = 0; >>> + hctxt->cpu_regs.x86_32.ss_limit = ~0u; >>> + hctxt->cpu_regs.x86_32.ss_ar = 0xc93; >>> + hctxt->cpu_regs.x86_32.tr_base = 0; >>> + hctxt->cpu_regs.x86_32.tr_limit = 0xff; >>> + hctxt->cpu_regs.x86_32.tr_ar = 0x8b; >> Lots of hard-coded values here. Should this be #defined somewhere? > > We also don't need to set bases to zero since hctxt is kzalloc'd. I'll > remove that and add a comment. > > As for macros --- I couldn't find the bits defined symbolically anywhere > and since this is the only place this is used the macros would be local > here. Ok. David