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

Re: [Xen-devel] [PATCH 07/13] xen/arm: vgic: Clean-up the sysreg emulation



On Wed, 7 Dec 2016, Julien Grall wrote:
> Couple of clean-up for the vgic sysreg emulation:
>     - Reference the public documentation rather than a non-public one
>     - Let the vgic emulation decides whether a register needs to be
>     emulated
>     - Drop unnecessary debug printk. They don't bring much information
>     and can be misleading (vGICv2 does not support thoses registers)
> 
> Signed-off-by: Julien Grall <julien.grall@xxxxxxx>

Aside from a couple of typos in the commit message that I'll fix.

Reviewed-by: Stefano Stabellini <sstabellini@xxxxxxxxxx>


>  xen/arch/arm/traps.c | 16 ++++------------
>  1 file changed, 4 insertions(+), 12 deletions(-)
> 
> diff --git a/xen/arch/arm/traps.c b/xen/arch/arm/traps.c
> index fb07ae1..1fe02cb 100644
> --- a/xen/arch/arm/traps.c
> +++ b/xen/arch/arm/traps.c
> @@ -2261,23 +2261,15 @@ static void do_sysreg(struct cpu_user_regs *regs,
>      /*
>       * HCR_EL2.FMO or HCR_EL2.IMO
>       *
> -     * ARMv8: GIC Architecture Specification (PRD03-GENC-010745 24.0)
> -     *        Section 4.6.8.
> +     * GIC Architecture Specification (IHI 0069C): Section 4.6.3
>       */
>      case HSR_SYSREG_ICC_SGI1R_EL1:
> +    case HSR_SYSREG_ICC_ASGI1R_EL1:
> +    case HSR_SYSREG_ICC_SGI0R_EL1:
> +
>          if ( !vgic_emulate(regs, hsr) )
> -        {
> -            dprintk(XENLOG_WARNING,
> -                    "failed emulation of sysreg ICC_SGI1R_EL1 access\n");
>              return inject_undef64_exception(regs, hsr.len);
> -        }
>          break;
> -    case HSR_SYSREG_ICC_SGI0R_EL1:
> -    case HSR_SYSREG_ICC_ASGI1R_EL1:
> -        /* TBD: Implement to support secure grp0/1 SGI forwarding */
> -        dprintk(XENLOG_WARNING,
> -                "Emulation of sysreg ICC_SGI0R_EL1/ASGI1R_EL1 not 
> supported\n");
> -        return inject_undef64_exception(regs, hsr.len);
>  
>      /*
>       *  ICC_SRE_EL2.Enable = 0
> -- 
> 1.9.1
> 

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

 


Rackspace

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