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

Re: [Xen-devel] DomU - DomU grant table



On Wed, Aug 21, 2013 at 9:10 PM, Maslekar, Omkar
<omkar.maslekar@xxxxxxxxx> wrote:
> Hi,
>
> (first domU1 code with Domain id =4)
>
> share_mem = (share_mem_desp *) __get_free_page(GFP_KERNEL);
> share_mem->gref = gnttab_grant_foreign_access(2, virt_to_mfn(share_mem), 0);
>
> Output gref= 110
>
> second domU (domain id = 2)
>
> share_vmarea = alloc_vm_area(PAGE_SIZE);
> gnttab_set_map_op( &map_op, (unsigned long)share_vmarea->addr, 
> GNTMAP_host_map, 110, 4 );
> HYPERVISOR_grant_table_op( GNTTABOP_map_grant_ref, &map_op, 1 );
>

Presumably you're using PV here. Please refer to
xenbus_client.c:xenbus_map_ring_valloc_pv for example.

Wei.

> I tried changes flags GNTMAP_host_map with Application and PTE, Can you tell 
> me what else can go wrong here.
>
> Thanks,
>
>
>
>
> -----Original Message-----
> From: Wei Liu [mailto:liuw@xxxxxxxxx]
> Sent: Tuesday, August 20, 2013 9:47 AM
> To: Maslekar, Omkar
> Cc: Wei Liu; xen-devel@xxxxxxxxxxxxx
> Subject: Re: [Xen-devel] DomU - DomU grant table
>
> On Tue, Aug 20, 2013 at 5:16 PM, Maslekar, Omkar <omkar.maslekar@xxxxxxxxx> 
> wrote:
>> Hi Liu,
>>
>> From DomU to Dom0 with passing gref works very well and memory shared 
>> verified by string contents.
>> However from dom0 to domU ( and similarly between two DomU) if I run same 
>> code( passing correct ID and gref) I am getting kernel panic error.
>
> I'm afraid you need to be more specific here. If you setup gref correctly I 
> don't see why it wouldn't work.
>
>> I am not setting up channel, I want simple string passing between two DomU.
>>
>
> What I mean is to pass the correct configuration to both side.
>
> Wei.
>
>> I followed
>> http://old-list-archives.xen.org/archives/html/xen-devel/2011-06/msg02
>> 037.html
>>
>> Thanks,
>> Omkar
>>
>> -----Original Message-----
>> From: Wei Liu [mailto:wei.liu2@xxxxxxxxxx]
>> Sent: Tuesday, August 20, 2013 1:07 AM
>> To: Maslekar, Omkar
>> Cc: xen-devel@xxxxxxxxxxxxx; wei.liu2@xxxxxxxxxx
>> Subject: Re: [Xen-devel] DomU - DomU grant table
>>
>> On Mon, Aug 19, 2013 at 05:36:09PM +0000, Maslekar, Omkar wrote:
>>> Hi,
>>> What changes are needed to run grant table code which access page between 
>>> two domU.
>>>
>>> I have working code between domU to dom0.
>>>
>>
>> We have driver domain which is DomU serving as backend for another DomU. In 
>> short grant table just works between DomUs.
>>
>> You're likely only required to setup the channel (via xenstore with the help 
>> from toolstack) and everything should hopefully just work.
>>
>> Wei.
>>
>>> Thanks,
>>
>>> _______________________________________________
>>> Xen-devel mailing list
>>> Xen-devel@xxxxxxxxxxxxx
>>> http://lists.xen.org/xen-devel
>>
>>
>> _______________________________________________
>> Xen-devel mailing list
>> Xen-devel@xxxxxxxxxxxxx
>> http://lists.xen.org/xen-devel

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

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