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] use xs_watch from userspace and use epoll instead of sel

To: Ian Campbell <Ian.Campbell@xxxxxxxxxxxxx>
Subject: Re: [Xen-devel] use xs_watch from userspace and use epoll instead of select
From: Vasiliy G Tolstov <v.tolstov@xxxxxxxxx>
Date: Mon, 06 Jun 2011 15:18:44 +0400
Cc: "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Mon, 06 Jun 2011 04:19:41 -0700
Dkim-signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=selfip.ru; s=dk; h=Content-Transfer-Encoding:Mime-Version:Message-ID:Date:Content-Type:References:In-Reply-To:Cc:To:Reply-To:From:Subject; bh=e9LSlidi9av0vDufMW5AjMDQcxwjlPqzBu65oKZc4qs=; b=oeBkUdi0wlic1ymgBG+hnrHAgG+iXOqqMw6LfQ+U4hYnnkL6qlnZCaD5vRsynHeM29k15EdZMiPhJgvCChbtlHJWos6rxOc0kSHEVSkKErEr87fzeirO2P3sKt/54QjP;
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <1307358029.775.437.camel@xxxxxxxxxxxxxxxxxxxxxx>
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>
Organization: Selfip.Ru
References: <1307102689.15777.3.camel@vase> <1307103239.775.382.camel@xxxxxxxxxxxxxxxxxxxxxx> <1307103479.15777.5.camel@vase> <1307117238.15777.7.camel@vase> <1307349708.775.419.camel@xxxxxxxxxxxxxxxxxxxxxx> <1307350709.28250.2.camel@vase> <1307353709.775.431.camel@xxxxxxxxxxxxxxxxxxxxxx> <1307354712.28250.7.camel@vase> <1307358029.775.437.camel@xxxxxxxxxxxxxxxxxxxxxx>
Reply-to: v.tolstov@xxxxxxxxx
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
On Mon, 2011-06-06 at 12:00 +0100, Ian Campbell wrote:
> On Mon, 2011-06-06 at 11:05 +0100, Vasiliy G Tolstov wrote:
> > On Mon, 2011-06-06 at 10:48 +0100, Ian Campbell wrote:
> 
> > > What are you actually trying to build?
> 
> > I'm try to build daemon, that can recieve command via xenstore (xs_watch
> > for specific path), via /dev/hvcN (serial char interface), now i'm try
> > to use gntmem mechanism to do this too. If one method not available or
> > not work or some errors accured - i'm try next. 
> > /dev/hvcN Not good sometimes, becouse in some domU i have gentty on this
> > port.
> > xenstore - has limit in size of message...
> 
> Interesting.
> 
> > In kernel side xen thing more easy to understand. Use it under userspace
> > need deep googling =).
> 
> I'm afraid so.
> 
> Remember that the underlying grant table hypercall's and mechanisms are
> the same in both kernel and userspace and the APIs provided reflect that
> -- userspace is not all that different.
> 
> In userspace you might need (actually I think it's probably required)
> to use the gntalloc driver (added to pvops by Daniel de Graff around
> 2.6.39 I think) to get memory suitable for granting out.
> 
> > Ok if i use grant pages mechanism - do i have notify for new message
> > after it arrives? If i use xs from domU i need libxc under it insted of
> > libxenstore ?
> 
> Yes you need to notify, libxc provides an interface to event channels as
> well as grant tables.
> 
> You will probably need both libxc and libxenstore. You use xenstore to
> negotiated the event channel and shared page with your peer and libxc to
> create, map, signal them etc.
> 
> Ian.
> 
> 

Thanks for suggestions. I'm try investigate e-mail list with gntdev
patches and write example code..
-- 
Vasiliy G Tolstov <v.tolstov@xxxxxxxxx>
Selfip.Ru


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