[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] Contiguous DMAble memory in Dom0 user space linux process


  • To: Konrad Rzeszutek Wilk <konrad.wilk@xxxxxxxxxx>
  • From: "Kashmira. K." <chimnee@xxxxxxxxx>
  • Date: Thu, 14 Jan 2010 18:16:02 -0800 (PST)
  • Cc: winterfi@xxxxxxxxx, xen-devel@xxxxxxxxxxxxxxxxxxx
  • Delivery-date: Thu, 14 Jan 2010 18:16:29 -0800
  • Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:Cc:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=DcGkdbPqgWFovAQ2h9hZYwj6Mic+iL66Qf4W0tMB1YyGHbyisSyoOHcnFxVK1F5SLHmAx497CamgTDo10TJP9EKKSdrONtUWLeeToRhtR6mkEQfzXpQTc09819ehCV8OtOptKe2VBilolGNcxFCEmZ8DfgemyRDuPPuxTbEydME=;
  • List-id: Xen developer discussion <xen-devel.lists.xensource.com>

Hi Konard,

Please see response inline

--- On Wed, 1/13/10, Konrad Rzeszutek Wilk <konrad.wilk@xxxxxxxxxx> wrote:

> From: Konrad Rzeszutek Wilk <konrad.wilk@xxxxxxxxxx>
> Subject: Re: [Xen-devel] Contiguous DMAble memory in Dom0 user space linux 
> process
> To: "Kashmira. K." <chimnee@xxxxxxxxx>
> Cc: xen-devel@xxxxxxxxxxxxxxxxxxx, winterfi@xxxxxxxxx
> Date: Wednesday, January 13, 2010, 1:31 PM
> On Wed, Jan 13, 2010 at 01:03:39PM
> -0800, Kashmira. K. wrote:
> > Hello Xen experts,
> > 
> > I am trying to get contiguous DMAble memory in user
> space application which is a processes running on xen
> capable Linux.
> 
> Why? Is the driver you are communicating with doing DMA of
> huge chunks of memory (bigger than 2MB?)
> 
Actually I'm not trying to communicate with a driver. The user space 
application is kind of a driver that lives outside of the kernel and 
communicates with the device directly. 
On a linux system (non xen) the bigphysarea patch was used to get large 
contiguous DMA memory in  user space. 
I am trying to do the equivalant on Xen capable linux in Dom0 so the same 
application will work. Kind of port it from 'linux' to 'Xen capable linux'.

> There surely must be another way to make your application
> do what it has
> to do than allocating such a large swath of memory.
> 
> 
> > Is it possible to use the 
> HYPERVISOR_grant_table_op hypercall passing
> GMTTABOP_map_grant_ref as command to achieve this. If so, to
> use this hypercall the grant reference is required. How do I
> get the grant reference?  Would appreciate if I can get
> an example code or pointer to one to clearly understand how
> to achieve this.
> 
> Grant reference won't get you contiguous memory. It will
> get you memory
> shared between domains.
> 
Yes I see now. I had confused the flags options GNTMAP_device_map to be DMAble 
memory.
There is a HYPERVISOR_memory_op which can exchange memory for contiguous one. 
But then this does not help me direcltly since a hypercall can only be used in 
the kernel.

Thanks
Kashmira 





> 




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


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.