All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tony Lindgren <tony@atomide.com>
To: Russell King - ARM Linux <linux@arm.linux.org.uk>
Cc: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com>,
	Pavel Machek <pavel@ucw.cz>,
	"linux-omap@vger.kernel.org" <linux-omap@vger.kernel.org>,
	Sebastian Reichel <sre@kernel.org>,
	"linux-arm-kernel@lists.infradead.org"
	<linux-arm-kernel@lists.infradead.org>,
	Matthijs van Duin <matthijsvanduin@gmail.com>
Subject: Re: ARM errata 430973 on multi platform kernels
Date: Wed, 8 Apr 2015 16:15:52 -0700	[thread overview]
Message-ID: <20150408231552.GO18048@atomide.com> (raw)
In-Reply-To: <20150408230839.GP4027@n2100.arm.linux.org.uk>

* Russell King - ARM Linux <linux@arm.linux.org.uk> [150408 16:09]:
> On Tue, Apr 07, 2015 at 08:44:05AM -0700, Tony Lindgren wrote:
> > And then on top of that patch, we can fix the sefaulting issues with the
> > following, what do you guys think?
> 
> Has this change been tested on OMAP secure parts?

Boots just fine for me on n900, but let's wait for comments
from Sebastian.

Regards,

Tony
 
> > 8< --------------------
> > From: Tony Lindgren <tony@atomide.com>
> > Date: Tue, 7 Apr 2015 07:52:39 -0700
> > Subject: [PATCH] ARM: mm: Fix Cortex-A8 erratum 430973 segfaults for bootloaders and multiarch
> > 
> > Looks like apps can be made to segfault easily on armhf distros
> > just by running cpuburn-a8 in the background, then starting apt
> > get update unless erratum 430973 workaround is enabled. This happens
> > on r3p2 also, which has 430973 fixed in hardware.
> > 
> > Turns out the reason for this is some bootloaders incorrectly
> > setting the auxilary register IBE bit, which probably causes us
> > to hit erratum 687067 on Cortex-A8 later than r1p2.
> > 
> > Now that Cortex-A8 has it's own cpu_ca8_switch_mm, we can fix these
> > issues:
> > 
> > 1. If the bootloader incorrectly sets the IBE bit in the auxilary
> >    control register for Cortex-A8 revisions with 430973 fixed
> >    in hardware, we need to call flush BTAC/BTB to avoid segfaults
> >    probably caused by erratum 687067. So let's flush BTAC/BTB
> >    unconditionally for Cortex-A8. It won't do anything unless the
> >    IBE bit is set.
> > 
> > 2. We can and should now keep 430973 enabled for multiarch builds
> >    as it no longer causes issues with Cortex-A9 as we have a separate
> >    cpu_ca8_switch_mm.
> > 
> > Note that SoCs probably should also add checks and print warnings
> > for the misconfigured IBE bit depending on the Cortex-A8 revision
> > so the bootloaders can be fixed Cortex-A8 revisions later than
> > r1p2 to not set the IBE bit.
> > 
> > Signed-off-by: Tony Lindgren <tony@atomide.com>
> > 
> > --- a/arch/arm/mm/proc-v7-2level.S
> > +++ b/arch/arm/mm/proc-v7-2level.S
> > @@ -36,14 +36,16 @@
> >   *
> >   *	It is assumed that:
> >   *	- we are not using split page tables
> > + *
> > + *	Note that we always need to flush BTAC/BTB if IBE is set
> > + *	even on Cortex-A8 revisions not affected by 430973.
> > + *	If IBE is not set, the flush BTAC/BTB won't do anything.
> >   */
> >  ENTRY(cpu_ca8_switch_mm)
> >  #ifdef CONFIG_MMU
> >  	mov	r2, #0
> > -#ifdef CONFIG_ARM_ERRATA_430973
> >  	mcr	p15, 0, r2, c7, c5, 6		@ flush BTAC/BTB
> >  #endif
> > -#endif
> >  ENTRY(cpu_v7_switch_mm)
> >  #ifdef CONFIG_MMU
> >  	mmid	r1, r1				@ get mm->context.id
> > --- a/arch/arm/mm/proc-v7.S
> > +++ b/arch/arm/mm/proc-v7.S
> > @@ -352,7 +352,7 @@ __v7_setup:
> >  	ldr	r10, =0x00000c08		@ Cortex-A8 primary part number
> >  	teq	r0, r10
> >  	bne	2f
> > -#if defined(CONFIG_ARM_ERRATA_430973) && !defined(CONFIG_ARCH_MULTIPLATFORM)
> > +#if defined(CONFIG_ARM_ERRATA_430973)
> >  
> >  	teq	r5, #0x00100000			@ only present in r1p*
> >  	mrceq	p15, 0, r10, c1, c0, 1		@ read aux control register
> 
> -- 
> FTTC broadband for 0.8mile line: currently at 10.5Mbps down 400kbps up
> according to speedtest.net.
> --
> To unsubscribe from this list: send the line "unsubscribe linux-omap" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

WARNING: multiple messages have this Message-ID (diff)
From: tony@atomide.com (Tony Lindgren)
To: linux-arm-kernel@lists.infradead.org
Subject: ARM errata 430973 on multi platform kernels
Date: Wed, 8 Apr 2015 16:15:52 -0700	[thread overview]
Message-ID: <20150408231552.GO18048@atomide.com> (raw)
In-Reply-To: <20150408230839.GP4027@n2100.arm.linux.org.uk>

* Russell King - ARM Linux <linux@arm.linux.org.uk> [150408 16:09]:
> On Tue, Apr 07, 2015 at 08:44:05AM -0700, Tony Lindgren wrote:
> > And then on top of that patch, we can fix the sefaulting issues with the
> > following, what do you guys think?
> 
> Has this change been tested on OMAP secure parts?

Boots just fine for me on n900, but let's wait for comments
from Sebastian.

Regards,

Tony
 
> > 8< --------------------
> > From: Tony Lindgren <tony@atomide.com>
> > Date: Tue, 7 Apr 2015 07:52:39 -0700
> > Subject: [PATCH] ARM: mm: Fix Cortex-A8 erratum 430973 segfaults for bootloaders and multiarch
> > 
> > Looks like apps can be made to segfault easily on armhf distros
> > just by running cpuburn-a8 in the background, then starting apt
> > get update unless erratum 430973 workaround is enabled. This happens
> > on r3p2 also, which has 430973 fixed in hardware.
> > 
> > Turns out the reason for this is some bootloaders incorrectly
> > setting the auxilary register IBE bit, which probably causes us
> > to hit erratum 687067 on Cortex-A8 later than r1p2.
> > 
> > Now that Cortex-A8 has it's own cpu_ca8_switch_mm, we can fix these
> > issues:
> > 
> > 1. If the bootloader incorrectly sets the IBE bit in the auxilary
> >    control register for Cortex-A8 revisions with 430973 fixed
> >    in hardware, we need to call flush BTAC/BTB to avoid segfaults
> >    probably caused by erratum 687067. So let's flush BTAC/BTB
> >    unconditionally for Cortex-A8. It won't do anything unless the
> >    IBE bit is set.
> > 
> > 2. We can and should now keep 430973 enabled for multiarch builds
> >    as it no longer causes issues with Cortex-A9 as we have a separate
> >    cpu_ca8_switch_mm.
> > 
> > Note that SoCs probably should also add checks and print warnings
> > for the misconfigured IBE bit depending on the Cortex-A8 revision
> > so the bootloaders can be fixed Cortex-A8 revisions later than
> > r1p2 to not set the IBE bit.
> > 
> > Signed-off-by: Tony Lindgren <tony@atomide.com>
> > 
> > --- a/arch/arm/mm/proc-v7-2level.S
> > +++ b/arch/arm/mm/proc-v7-2level.S
> > @@ -36,14 +36,16 @@
> >   *
> >   *	It is assumed that:
> >   *	- we are not using split page tables
> > + *
> > + *	Note that we always need to flush BTAC/BTB if IBE is set
> > + *	even on Cortex-A8 revisions not affected by 430973.
> > + *	If IBE is not set, the flush BTAC/BTB won't do anything.
> >   */
> >  ENTRY(cpu_ca8_switch_mm)
> >  #ifdef CONFIG_MMU
> >  	mov	r2, #0
> > -#ifdef CONFIG_ARM_ERRATA_430973
> >  	mcr	p15, 0, r2, c7, c5, 6		@ flush BTAC/BTB
> >  #endif
> > -#endif
> >  ENTRY(cpu_v7_switch_mm)
> >  #ifdef CONFIG_MMU
> >  	mmid	r1, r1				@ get mm->context.id
> > --- a/arch/arm/mm/proc-v7.S
> > +++ b/arch/arm/mm/proc-v7.S
> > @@ -352,7 +352,7 @@ __v7_setup:
> >  	ldr	r10, =0x00000c08		@ Cortex-A8 primary part number
> >  	teq	r0, r10
> >  	bne	2f
> > -#if defined(CONFIG_ARM_ERRATA_430973) && !defined(CONFIG_ARCH_MULTIPLATFORM)
> > +#if defined(CONFIG_ARM_ERRATA_430973)
> >  
> >  	teq	r5, #0x00100000			@ only present in r1p*
> >  	mrceq	p15, 0, r10, c1, c0, 1		@ read aux control register
> 
> -- 
> FTTC broadband for 0.8mile line: currently at 10.5Mbps down 400kbps up
> according to speedtest.net.
> --
> To unsubscribe from this list: send the line "unsubscribe linux-omap" in
> the body of a message to majordomo at vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

  reply	other threads:[~2015-04-08 23:19 UTC|newest]

Thread overview: 123+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-01 19:07 [PATCH RESEND] ARM: dts: OMAP3-N900: Add microphone bias voltages Jarkko Nikula
2015-03-30 16:30 ` Jarkko Nikula
     [not found]   ` <55197A12.1050009-FVTvWyuFUl3QT0dZR+AlfA@public.gmane.org>
2015-03-30 16:42     ` Tony Lindgren
2015-03-30 17:45       ` Jarkko Nikula
     [not found]         ` <55198BA4.5010207-FVTvWyuFUl3QT0dZR+AlfA@public.gmane.org>
2015-03-30 17:50           ` Tony Lindgren
2015-03-31 12:32             ` Sebastian Reichel
2015-04-01 19:47               ` Tony Lindgren
2015-04-03 16:35                 ` ARM errata 430973 on multi platform kernels (was: OMAP3-N900: Add microphone bias voltages) Sebastian Reichel
2015-04-03 18:39                   ` Tony Lindgren
2015-04-03 18:39                     ` Tony Lindgren
2015-04-03 19:21                     ` Robert Nelson
2015-04-03 19:21                       ` Robert Nelson
2015-04-05 13:00                       ` Sebastian Reichel
2015-04-05 13:00                         ` Sebastian Reichel
2015-04-05 13:26                         ` Pali Rohár
2015-04-05 13:26                           ` Pali Rohár
2015-04-05 13:45                           ` Sebastian Reichel
2015-04-05 13:45                             ` Sebastian Reichel
2015-04-05 13:52                             ` Pali Rohár
2015-04-05 13:52                               ` Pali Rohár
2015-04-06 17:38                               ` Sebastian Reichel
2015-04-06 17:38                                 ` Sebastian Reichel
2015-04-03 20:42                   ` Pavel Machek
2015-04-03 20:42                     ` Pavel Machek
2015-04-03 22:08                   ` ARM errata 430973 on multi platform kernels Ivaylo Dimitrov
2015-04-03 22:08                     ` Ivaylo Dimitrov
2015-04-03 22:15                     ` Tony Lindgren
2015-04-03 22:15                       ` Tony Lindgren
2015-04-03 22:47                       ` Ivaylo Dimitrov
2015-04-03 22:47                         ` Ivaylo Dimitrov
2015-04-03 22:52                         ` Tony Lindgren
2015-04-03 22:52                           ` Tony Lindgren
2015-04-05  4:13                           ` Matthijs van Duin
2015-04-05  4:13                             ` Matthijs van Duin
2015-04-05  7:23                             ` Ivaylo Dimitrov
2015-04-05  7:23                               ` Ivaylo Dimitrov
2015-04-05 16:50                               ` Matthijs van Duin
2015-04-05 16:50                                 ` Matthijs van Duin
2015-04-05 16:52                                 ` Matthijs van Duin
2015-04-05 16:52                                   ` Matthijs van Duin
2015-04-05 21:08                                 ` Ivaylo Dimitrov
2015-04-05 21:08                                   ` Ivaylo Dimitrov
2015-04-05 23:52                                   ` Matthijs van Duin
2015-04-05 23:52                                     ` Matthijs van Duin
2015-04-06 15:19                                     ` Tony Lindgren
2015-04-06 15:19                                       ` Tony Lindgren
2015-04-06 15:40                                       ` Tony Lindgren
2015-04-06 15:40                                         ` Tony Lindgren
2015-04-06 17:14                                         ` Ivaylo Dimitrov
2015-04-06 17:14                                           ` Ivaylo Dimitrov
2015-04-06 17:42                                           ` Tony Lindgren
2015-04-06 17:42                                             ` Tony Lindgren
2015-04-06 18:14                                             ` Matthijs van Duin
2015-04-06 18:14                                               ` Matthijs van Duin
2015-04-07  2:23                                               ` Tony Lindgren
2015-04-07  2:23                                                 ` Tony Lindgren
2015-04-07  3:12                                                 ` Sebastian Reichel
2015-04-07  3:12                                                   ` Sebastian Reichel
2015-04-07  3:49                                                   ` Matthijs van Duin
2015-04-07  3:49                                                     ` Matthijs van Duin
2015-04-07 14:48                                                     ` Tony Lindgren
2015-04-07 14:48                                                       ` Tony Lindgren
2015-04-09 22:37                                                 ` Grazvydas Ignotas
2015-04-09 22:37                                                   ` Grazvydas Ignotas
2015-04-09 22:44                                                   ` Tony Lindgren
2015-04-09 22:44                                                     ` Tony Lindgren
2015-04-09 23:44                                                     ` Nishanth Menon
2015-04-09 23:44                                                       ` Nishanth Menon
2015-04-10 22:05                                                     ` Grazvydas Ignotas
2015-04-10 22:05                                                       ` Grazvydas Ignotas
2015-04-10 23:08                                                       ` Tony Lindgren
2015-04-10 23:08                                                         ` Tony Lindgren
2015-04-16 16:53                                                   ` Matthijs van Duin
2015-04-16 16:53                                                     ` Matthijs van Duin
2015-04-07 13:58                                               ` Russell King - ARM Linux
2015-04-07 13:58                                                 ` Russell King - ARM Linux
2015-04-07 13:57                                             ` Russell King - ARM Linux
2015-04-07 13:57                                               ` Russell King - ARM Linux
2015-04-07 15:22                                               ` Tony Lindgren
2015-04-07 15:22                                                 ` Tony Lindgren
2015-04-07 15:44                                                 ` Tony Lindgren
2015-04-07 15:44                                                   ` Tony Lindgren
2015-04-08 23:08                                                   ` Russell King - ARM Linux
2015-04-08 23:08                                                     ` Russell King - ARM Linux
2015-04-08 23:15                                                     ` Tony Lindgren [this message]
2015-04-08 23:15                                                       ` Tony Lindgren
2015-04-08 23:06                                                 ` Russell King - ARM Linux
2015-04-08 23:06                                                   ` Russell King - ARM Linux
2015-04-09 13:48                                                   ` Russell King - ARM Linux
2015-04-09 13:48                                                     ` Russell King - ARM Linux
2015-04-09 15:09                                                     ` Tony Lindgren
2015-04-09 15:09                                                       ` Tony Lindgren
2015-04-09 15:30                                                       ` Russell King - ARM Linux
2015-04-09 15:30                                                         ` Russell King - ARM Linux
2015-04-15 16:31                                                     ` Sebastian Reichel
2015-04-15 16:31                                                       ` Sebastian Reichel
2015-04-16 16:08                                                       ` Tony Lindgren
2015-04-16 16:08                                                         ` Tony Lindgren
2015-04-17 18:41                                                         ` Sebastian Reichel
2015-04-17 18:41                                                           ` Sebastian Reichel
2015-04-20 23:40                                                           ` Tony Lindgren
2015-04-20 23:40                                                             ` Tony Lindgren
2015-04-23 10:25                                                             ` Russell King - ARM Linux
2015-04-23 10:25                                                               ` Russell King - ARM Linux
2015-04-23 14:17                                                               ` Tony Lindgren
2015-04-23 14:17                                                                 ` Tony Lindgren
2015-04-28 18:13                                                                 ` Russell King - ARM Linux
2015-04-28 18:13                                                                   ` Russell King - ARM Linux
2015-04-29 14:40                                                                   ` Tony Lindgren
2015-04-29 14:40                                                                     ` Tony Lindgren
2015-05-04 14:24                                                                     ` Tony Lindgren
2015-05-04 14:24                                                                       ` Tony Lindgren
2015-04-24  8:54                                                               ` Matthijs van Duin
2015-04-24  8:54                                                                 ` Matthijs van Duin
2015-04-28 18:11                                                                 ` Russell King - ARM Linux
2015-04-28 18:11                                                                   ` Russell King - ARM Linux
2015-05-02  6:51                                                                   ` Matthijs van Duin
2015-05-02  6:51                                                                     ` Matthijs van Duin
2015-04-05 13:39                             ` Sebastian Reichel
2015-04-05 13:39                               ` Sebastian Reichel
2015-04-06 15:24                               ` Tony Lindgren
2015-04-06 15:24                                 ` Tony Lindgren
2015-05-04 16:07               ` [PATCH RESEND] ARM: dts: OMAP3-N900: Add microphone bias voltages Tony Lindgren

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150408231552.GO18048@atomide.com \
    --to=tony@atomide.com \
    --cc=ivo.g.dimitrov.75@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=linux@arm.linux.org.uk \
    --cc=matthijsvanduin@gmail.com \
    --cc=pavel@ucw.cz \
    --cc=sre@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.