|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH v5 17/22] arm/gic: Add a new callback to deny Dom0 access to GIC regions
On Fri, 4 Mar 2016, Shannon Zhao wrote:
> From: Shannon Zhao <shannon.zhao@xxxxxxxxxx>
>
> Add a new member in gic_hw_operations which is used to deny Dom0 access
> to GIC regions.
>
> Signed-off-by: Shannon Zhao <shannon.zhao@xxxxxxxxxx>
> ---
> xen/arch/arm/gic-v2.c | 31 +++++++++++++++++++++++++++++++
> xen/arch/arm/gic-v3.c | 44 ++++++++++++++++++++++++++++++++++++++++++++
> xen/arch/arm/gic.c | 5 +++++
> xen/include/asm-arm/gic.h | 3 +++
> 4 files changed, 83 insertions(+)
>
> diff --git a/xen/arch/arm/gic-v3.c b/xen/arch/arm/gic-v3.c
> index d9fce4b..67797f2 100644
> --- a/xen/arch/arm/gic-v3.c
> +++ b/xen/arch/arm/gic-v3.c
> @@ -27,6 +27,7 @@
> #include <xen/cpu.h>
> #include <xen/mm.h>
> #include <xen/irq.h>
> +#include <xen/iocap.h>
> #include <xen/sched.h>
> #include <xen/errno.h>
> #include <xen/delay.h>
> @@ -1278,6 +1279,44 @@ static u32 gicv3_make_hwdom_madt(const struct domain
> *d, u32 offset)
> return table_len;
> }
>
> +static int gicv3_iomem_deny_access(const struct domain *d)
> +{
> + int rc, i;
> + unsigned long gfn, nr;
> +
> + gfn = dbase >> PAGE_SHIFT;
> + rc = iomem_deny_access(d, gfn, gfn + 1);
The size of the gicv3 distributor is 64k.
The rest looks good.
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |