From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:36464) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XE9hH-0003Jf-7g for qemu-devel@nongnu.org; Mon, 04 Aug 2014 00:16:37 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XE9hB-0001zY-9F for qemu-devel@nongnu.org; Mon, 04 Aug 2014 00:16:31 -0400 Received: from mail-qa0-x231.google.com ([2607:f8b0:400d:c00::231]:47675) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XE9hB-0001zT-5Z for qemu-devel@nongnu.org; Mon, 04 Aug 2014 00:16:25 -0400 Received: by mail-qa0-f49.google.com with SMTP id dc16so6338443qab.22 for ; Sun, 03 Aug 2014 21:16:24 -0700 (PDT) Date: Mon, 4 Aug 2014 14:13:58 +1000 From: "Edgar E. Iglesias" Message-ID: <20140804041358.GX13735@toto> References: <1402994746-8328-1-git-send-email-edgar.iglesias@gmail.com> <1402994746-8328-16-git-send-email-edgar.iglesias@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Subject: Re: [Qemu-devel] [PATCH v3 15/16] target-arm: Add IRQ and FIQ routing to EL2 and 3 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell Cc: Rob Herring , Peter Crosthwaite , Fabian Aggeler , QEMU Developers , Alexander Graf , Blue Swirl , John Williams , Greg Bellows , Paolo Bonzini , Alex =?iso-8859-1?Q?Benn=E9e?= , Christoffer Dall , Richard Henderson On Fri, Aug 01, 2014 at 03:27:44PM +0100, Peter Maydell wrote: > On 17 June 2014 09:45, Edgar E. Iglesias wrote: > > From: "Edgar E. Iglesias" > > > --- 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