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

Re: [Xen-devel] [PATCH] xen: arm: invalidate caches after map_domain_page done





On 01/08/14 12:37, Andrii Tseglytskyi wrote:
The page you are trying to map belongs to a guest, right? When the guest
writes data in this page. Does it map with cacheable attribute or not? I
suspect no.

Hard to say. This page is allocated using usual kernel API such as
kmalloc(). Then its pfn is stored in MMU 1-st level translation
pagetable.

If it's allocated from kmalloc then the page is allocated with cacheable attribute.

Before storing - kernel driver flush corresponding cache ranges.

Clean and invalidate the cache, right?

> After
this - remoteproc_iommu framework translates pfns to mfns.
So - I would expect that after map_domain_page() function call all
data will be valid.

Actually with your explanation me too. :)

I'm run out of idea. Maybe Ian or Stefano have any clue.


I think your current problem is the cache contains stall data. In this case
you have to only invalidate the cache.


May work. But it looks like new helper should be introduced in this
case. I see that only clean_and_invalidate_xen_dcache_va_range API is
present, no standalone API for invalidating only.

You can add a new helper. I suspect it will be necessary sooner or later in other places.

Regards,

--
Julien Grall

_______________________________________________
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®.