From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rusty Russell Subject: Re: %fs PDA & KVM Date: Mon, 12 Mar 2007 09:19:18 +1100 Message-ID: <1173651559.32234.201.camel@localhost.localdomain> References: <20070311122441.GA10774@elte.hu> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: kvm-devel To: Ingo Molnar Return-path: In-Reply-To: <20070311122441.GA10774-X9Un+BFzKDI@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org Errors-To: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org List-Id: kvm.vger.kernel.org On Sun, 2007-03-11 at 13:24 +0100, Ingo Molnar wrote: > hm, i just noticed that in vmx_vcpu_run() KVM restores %fs quite late. > > This is a bit awkward under v2.6.21 x86 because there we use %fs for the > KERNEL_PDA area. Things like 'current' rely on it. So maybe we should > just do this unconditionally in assembly: > > movl $(__KERNEL_PDA), %edx; > movl %edx, %fs Note that at some stage as Andi merges the pda->percpu conversion, this will need to be replaced by __KERNEL_PERCPU. Trivial change. Cheers, Rusty. ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys-and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV