xen/arm: Add support for read-only foreign mappings
authorJulien Grall <julien.grall@arm.com>
Fri, 21 Dec 2018 16:26:45 +0000 (16:26 +0000)
committerStefano Stabellini <sstabellini@kernel.org>
Fri, 21 Dec 2018 17:43:01 +0000 (09:43 -0800)
commite820583468513b799aafc1010977e71db27f8992
treeede6752aafb347667bd52530d24970144123f331
parent833c9c5e6c3b97e2e918e9af8d17d152188ff151
xen/arm: Add support for read-only foreign mappings

Currently, foreign mappings can only be read-write. A follow-up patch will
extend foreign mapping for Xen backend memory (via XEN_DOMID), some of
that memory should only be read accessible for the mapping domain.

Introduce a new p2m_type to cater read-only foreign mappings. For now,
the decision between the two foreign mapping type is based on the type
of the guest page mapped.

Signed-off-by: Julien Grall <julien.grall@arm.com>
Reviewed-by: Andrii Anisov <andrii_anisov@epam.com>
Acked-by: Stefano Stabellini <sstabellini@kernel.org>
xen/arch/arm/mm.c
xen/arch/arm/p2m.c
xen/include/asm-arm/p2m.h