From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jeremy Fitzhardinge Subject: Re: Is exposing shared_info to user-land secure? Date: Fri, 01 Aug 2008 13:35:23 -0700 Message-ID: <4893738B.9060702@goop.org> References: Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Keir Fraser Cc: "dan.magenheimer@oracle.com" , "Xen-Devel (E-mail)" List-Id: xen-devel@lists.xenproject.org Keir Fraser wrote: > I think it might be okay. One issue is that how to let the user-space > process know what vcpu it is running on, so it can use the correct timestamp > info in a way that is safe against preemption. Bear in mind that the user > address space may be shared by multiple concurrent threads on different > VCPUs! If you assume consistent-tsc across all CPUs then the task is easier, > but I don't think we'll want to bake that assumption into guest kernels and > their interface to user processes. > x86-64 already exports the current cpu and nodeid in the limit of a gdt entry, so you can fetch it from userspace with lsl. J