From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932119AbWGRKKD (ORCPT ); Tue, 18 Jul 2006 06:10:03 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S932128AbWGRKKD (ORCPT ); Tue, 18 Jul 2006 06:10:03 -0400 Received: from [216.208.38.107] ([216.208.38.107]:42112 "EHLO OTTLS.pngxnet.com") by vger.kernel.org with ESMTP id S932119AbWGRKKB (ORCPT ); Tue, 18 Jul 2006 06:10:01 -0400 Subject: Re: [RFC PATCH 15/33] move segment checks to subarch From: Arjan van de Ven To: Chris Wright Cc: linux-kernel@vger.kernel.org, virtualization@lists.osdl.org, xen-devel@lists.xensource.com, Jeremy Fitzhardinge , Andi Kleen , Andrew Morton , Rusty Russell , Zachary Amsden , Ian Pratt , Christian Limpach In-Reply-To: <20060718091952.263186000@sous-sol.org> References: <20060718091807.467468000@sous-sol.org> <20060718091952.263186000@sous-sol.org> Content-Type: text/plain Organization: Intel International BV Date: Tue, 18 Jul 2006 12:09:04 +0200 Message-Id: <1153217344.3038.31.camel@laptopd505.fenrus.org> Mime-Version: 1.0 X-Mailer: Evolution 2.2.3 (2.2.3-2.fc4) Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 2006-07-18 at 00:00 -0700, Chris Wright wrote: > plain text document attachment (i386-segments) > We allow for the fact that the guest kernel may not run in ring 0. > This requires some abstraction in a few places when setting %cs or > checking privilege level (user vs kernel). > - regs.xcs = __KERNEL_CS; > + regs.xcs = get_kernel_cs(); Hi, wouldn't this patch be simpler if __KERNEL_CS just became the macro that currently is get_kernel_cs() for the XEN case? then code like this doesn't need changing at all... Greetings, Arjan van de Ven