From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jeremy Fitzhardinge Subject: Re: new hypercall implementation question Date: Thu, 23 Jul 2009 14:26:15 -0700 Message-ID: <4A68D577.8060200@goop.org> References: <0e076676-cb5a-44e9-9e4b-90a70a45226f@default> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <0e076676-cb5a-44e9-9e4b-90a70a45226f@default> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Dan Magenheimer Cc: "Xen-Devel (E-mail)" List-Id: xen-devel@lists.xenproject.org On 07/23/09 07:31, Dan Magenheimer wrote: > Is it safe to pass three guest virtual addresses via a hypercall > to Xen and expect Xen to safely copy data (two scalars and one > array of pagesize-bytes... not necessarily aligned on a page > boundary) back to the guest, or do I need to do something fancy > to avoid weird corner cases, e.g. to ensure restartabililty > in case of guest page fault? > > This is a privileged-only hypercall used only as part of > save/restore/live-migrate (for tmem) if that is relevant. > For x86 its OK to pass kernel vaddrs to Xen and have it interpret them with the current pagetable. There should be no pagefaults, or rather, the hypercall will fail with EFAULT. I think ia64 has problems with anything other than physical addresses being passed, and has to do all that handle stuff to convert. J