[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v3 15/16] target-arm: Add IRQ and FIQ routing to
From: |
Edgar E. Iglesias |
Subject: |
Re: [Qemu-devel] [PATCH v3 15/16] target-arm: Add IRQ and FIQ routing to EL2 and 3 |
Date: |
Mon, 4 Aug 2014 14:13:58 +1000 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
On Fri, Aug 01, 2014 at 03:27:44PM +0100, Peter Maydell wrote:
> On 17 June 2014 09:45, Edgar E. Iglesias <address@hidden> wrote:
> > From: "Edgar E. Iglesias" <address@hidden>
>
> > --- a/target-arm/helper.c
> > +++ b/target-arm/helper.c
> > @@ -3312,6 +3312,19 @@ unsigned int arm_excp_target_el(CPUState *cs,
> > unsigned int excp_idx)
> > target_el = 2;
> > }
> > break;
> > + case EXCP_FIQ:
> > + case EXCP_IRQ: {
>
> A trivial style nit, but I prefer the { to go on its own line when
> opening a new scope for a case statement like this.
I've changed this to your prefered style, thanks.
>
> > + const uint64_t hcr_mask = excp_idx == EXCP_FIQ ? HCR_FMO :
> > HCR_IMO;
> > + const uint32_t scr_mask = excp_idx == EXCP_FIQ ? SCR_FIQ :
> > SCR_IRQ;
> > +
> > + if (!secure && (env->cp15.hcr_el2 & hcr_mask)) {
> > + target_el = 2;
> > + }
> > + if (env->cp15.scr_el3 & scr_mask) {
> > + target_el = 3;
> > + }
> > + break;
> > + }
> > }
> > return target_el;
> > }
>
> thanks
> -- PMM