lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20210219181825.GA84857@C02TD0UTHF1T.local>
Date:   Fri, 19 Feb 2021 18:18:34 +0000
From:   Mark Rutland <mark.rutland@....com>
To:     Joey Gouly <joey.gouly@....com>
Cc:     linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
        catalin.marinas@....com, marcan@...can.st, james.morse@....com,
        maz@...nel.org, tglx@...utronix.de, will@...nel.org, nd@....com
Subject: Re: [PATCH 8/8] arm64: irq: allow FIQs to be handled

On Fri, Feb 19, 2021 at 03:37:25PM +0000, Joey Gouly wrote:
> Hi Mark,
> 
> On Fri, Feb 19, 2021 at 11:39:04AM +0000, Mark Rutland wrote:
> > On contemporary platforms we don't use FIQ, and treat any stray FIQ as a
> > fatal event. However, some platforms have an interrupt controller wired
> > to FIQ, and need to handle FIQ as part of regular operation.
> > 
> 
> [...]
> 
> > diff --git a/arch/arm64/kernel/entry.S b/arch/arm64/kernel/entry.S
> > index 0474cca9f1a9..a8290bd87a49 100644
> > --- a/arch/arm64/kernel/entry.S
> > +++ b/arch/arm64/kernel/entry.S
> > @@ -586,23 +586,23 @@ SYM_CODE_START(vectors)
> >  
> >  	kernel_ventry	1, sync				// Synchronous EL1h
> >  	kernel_ventry	1, irq				// IRQ EL1h
> > -	kernel_ventry	1, fiq_invalid			// FIQ EL1h
> > +	kernel_ventry	1, fiq				// FIQ EL1h
> >  	kernel_ventry	1, error			// Error EL1h
> >  
> >  	kernel_ventry	0, sync				// Synchronous 64-bit EL0
> >  	kernel_ventry	0, irq				// IRQ 64-bit EL0
> > -	kernel_ventry	0, fiq_invalid			// FIQ 64-bit EL0
> > +	kernel_ventry	0, fiq				// FIQ 64-bit EL0
> >  	kernel_ventry	0, error			// Error 64-bit EL0
> >  
> >  #ifdef CONFIG_COMPAT
> >  	kernel_ventry	0, sync_compat, 32		// Synchronous 32-bit EL0
> >  	kernel_ventry	0, irq_compat, 32		// IRQ 32-bit EL0
> > -	kernel_ventry	0, fiq_invalid_compat, 32	// FIQ 32-bit EL0
> > +	kernel_ventry	0, fiq_compat, 32		// FIQ 32-bit EL0
> >  	kernel_ventry	0, error_compat, 32		// Error 32-bit EL0
> >  #else
> >  	kernel_ventry	0, sync_invalid, 32		// Synchronous 32-bit EL0
> >  	kernel_ventry	0, irq_invalid, 32		// IRQ 32-bit EL0
> > -	kernel_ventry	0, fiq_invalid, 32		// FIQ 32-bit EL0
> > +	kernel_ventry	0, fiq, 32			// FIQ 32-bit EL0
> >  	kernel_ventry	0, error_invalid, 32		// Error 32-bit EL0
> >  #endif
> >  SYM_CODE_END(vectors)
> 
> I believe you can now remove functions `el0_fiq_invalid` and `el0_fiq_invalid_compat`.
> `el1_fiq_invalid` is still used by Synchronous EL1t, so can't be removed.

Good spot; el0_fiq_invalid_compat can go. For the !CONFIG_COMPAT it was
wrong to move away from fiq_invalid as that vector should never
legimitately fire, so I'll revert back to fiq_invalid for that case and
match the rest of the !CONFIG_COMPAT AArch32 EL0 handlers.

Thanks,
Mark.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ