From mboxrd@z Thu Jan 1 00:00:00 1970 From: Kip Macy Subject: Re: do_set_gdt Date: Sat, 28 Feb 2004 11:09:50 -0800 (PST) Sender: xen-devel-admin@lists.sourceforge.net Message-ID: <20040228110550.C6526@demos.bsdclusters.com> References: Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Return-path: In-Reply-To: Errors-To: xen-devel-admin@lists.sourceforge.net List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , List-Archive: To: Keir Fraser Cc: Christian Limpach , xen-devel@lists.sourceforge.net List-Id: xen-devel@lists.xenproject.org > > You'll also want to make sure that you don't put other stuff in the last > > page which hold the GDT table and align the GDT table to a page boundary: > > lgdt allows the gdt to be anywhere while for Xen you have to put it at the > > beginning of a page, can't really use the rest of the last page for much > > else and have to keep the pages around. > > Yes, this is all correct. On first glance I thought this was a bug (I > thought the code was deciding whether a particular GDT entry could be > updated by the guest). > Yes, but you have to pass in at least a page which == 512 entries. So if I'm only using the first 8 entries, there is no reason Xen can't use 256-296. Passing in LAST_RESERVED_ENTRY + 1, seems a little contrived when it is only the first 8 that I care about. A better approach would be to insist that entries 256-296 are set to 0 in the case where the user sets nentries >= FIRST_RESERVED_ENTRY. -Kip ------------------------------------------------------- SF.Net is sponsored by: Speed Start Your Linux Apps Now. Build and deploy apps & Web services for Linux with a free DVD software kit from IBM. Click Now! http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click