xen/arm: p2m: Allow to flush cache on any RAM region

Currently, we only allow to flush cache on regions mapped as p2m_ram_{rw,ro}.

There are no real problem in cache flushing any RAM regions such as grants
and foreign mapping. Therefore, relax the check to allow flushing the
cache on any RAM region.

Signed-off-by: Julien Grall <julien.grall@arm.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
This commit is contained in:
Julien Grall committed 2018-12-12 16:07:37 +00:00
1 parent 5ec1bdf0c7
commit cd85147287
1 file changed
+1 -1
+1 -1
View File
@@ -1539,7 +1539,7 @@ int p2m_cache_flush_range(struct domain *d, gfn_t start, gfn_t end)
next_gfn = gfn_next_boundary(start, order);
/* Skip hole and non-RAM page */
if ( mfn_eq(mfn, INVALID_MFN) || !p2m_is_ram(t) )
if ( mfn_eq(mfn, INVALID_MFN) || !p2m_is_any_ram(t) )
continue;
/* XXX: Implement preemption */
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.