WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] xenfs aka /proc/xen

To: Bastian Blank <waldi@xxxxxxxxxx>, Keir Fraser <keir.fraser@xxxxxxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: Re: [Xen-devel] xenfs aka /proc/xen
From: Jeremy Fitzhardinge <jeremy@xxxxxxxx>
Date: Sat, 05 Jun 2010 17:48:21 -0700
Cc:
Delivery-date: Sat, 05 Jun 2010 17:49:14 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <20100605162947.GA31336@xxxxxxxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <20100527225440.GC25018@xxxxxxxxxxxxxxxxxxxxxxx> <C82515C2.161B1%keir.fraser@xxxxxxxxxxxxx> <20100605162947.GA31336@xxxxxxxxxxxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.9) Gecko/20100430 Fedora/3.0.4-2.fc12 Lightning/1.0b2pre Thunderbird/3.0.4
On 06/05/2010 09:29 AM, Bastian Blank wrote:
> On Fri, May 28, 2010 at 06:40:02AM +0100, Keir Fraser wrote:
>   
>> On 27/05/2010 23:54, "Bastian Blank" <waldi@xxxxxxxxxx> wrote:
>>     
>>> One of the entries (capabilities) provides information about the
>>> proviledge level to the hypervisor and belongs more likely into
>>> /sys/hypervisor. The four other are plain old devices and belongs into
>>> /dev.
>>>       
> Okay. I thought about it and would settle for the following:
> * $SYSFS/hypervisor/properties/guest_capabilites
>   It includes the same value then $XENFS/capabilities. Or should that be
>   changed as the meaning of "control_d" is not really clear (like
>   "control-domain")?
>   

The general rule for sysfs is one value per file.  It would probably be
more consistent to have a (guest_)capabilities directory, with a file
per capability (containing 1/0, or some other value if appropriate).

> * $DEV/xen/xenbus
>   Merge into builtin xenbus support or own module xenbus-user
>   

Would you expect to change the actual ABI/protocol?

> * $DEV/xen/privcmd
>   - Module xen-control or so
>   - *Needs to check for CAP_ADMIN*
> * $DEV/xen/xenstored
>   - Module xen-control or so
>   - Merges xsd_kva and xsd_port
>   - Supports:
>     - mmap, only support pagesized maps
>     - ioctl: get event channel port, get size (page size may be different)
>   

Yes, the interface of exposing the xenstore mfn to userspace has always
seemed a bit mad.  The kernel driver should do the mapping for
usermode.  Does it also need to expose the xs event channel?  Or can the
kernel just handle it internally and expose a normal blocking interface.

In fact, does it needs its own separate driver?  This is just
symmetrical with /{proc,dev}/xen/xenbus.  Can that driver be made to
handle both ends?  Or at least a driver which looks symmetric to the
guest-side xenbus?

>   - Security constraints needs check. What can a user with access to
>     this device do?
>   

Policy should be enforced by xenstored itself.  Guests are not
trustworthy in general, so there's no point in enforcing anything within
the guest kernel.

> * Core kernel may trigger loading of xen-control module by some means
>   (to be defined).
>   

All a bit awkward, since there's no obvious trigger to hang the load
event off.  Maybe key them off Xen or xenbus bringup as some kind of
adjunct pseudo device?

    J

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>