linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: robherring2@gmail.com (Rob Herring)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] ARM: Fix errata 751472 handling on Cortex-A9 r1p*
Date: Wed, 14 Nov 2012 15:57:40 -0600	[thread overview]
Message-ID: <50A413D4.7000405@gmail.com> (raw)
In-Reply-To: <20121114203221.GA6801@atomide.com>

On 11/14/2012 02:32 PM, Tony Lindgren wrote:
> * Russell King - ARM Linux <linux@arm.linux.org.uk> [121114 12:24]:
>> On Wed, Nov 14, 2012 at 01:06:53PM -0600, Jon Hunter wrote:
>>>
>>> On 11/14/2012 12:53 PM, Tony Lindgren wrote:
>>>> Looks like enabling CONFIG_ARM_ERRATA_751472 causes omap4 blaze
>>>> to not boot when enabled. The ARM core on it is an earlier r1p2:
>>>>
>>>> CPU: ARMv7 Processor [411fc092] revision 2 (ARMv7), cr=10c53c7d
>>>>
>>>> Unfortunately I don't have the details of errata 751472, but I'm
>>>> guessing we need to disable it for r1p*.
>>>
>>> I checked the CA9MP errata document and this erratum impacts all
>>> r0/r1/r2 CPUs. I am wondering if the problem is because the workaround
>>> requires you to set a bit in the Diagnostic Control register and the
>>> read-modify-write sequence provided in the workaround is for secure
>>> mode. Not sure if there is a non-secure workaround available :-(
>>
>> Most likely, and there's not a lot that the kernel can sanely do about
>> that.  We have ended up deciding (through being forced to because of
>> how the security stuff works) that the stages prior to the kernel will
>> implement the work-around enables because those stages are already
>> platform specific, and the kernel will implement a "test for the
>> work-around already enabled."
>>
>> The net result is, if you enable an Errata in the kernel which your
>> earlier boot stages has not already configured, the kernel will hang.
>> Not much we can do about the hanging aspect, because the kernel takes
>> an exception which we can't trap at those early stages in the boot
>> process.
>>
>> I'm not particularly happy about that design, but that's what we've
>> ended up with through the 'design' of the security stuff forced onto
>> us.
> 
> Checking for the bit already set should work in this case, I'll post
> a patch for that shortly.

Can you actually read the state of the diagnostic register in non-secure
mode? If you can on the A9, is the same true on A8 or others?

Multi-platform kernels present a new problem in that we basically need
to enable all errata work-arounds. I've been meaning to look thru the
errata work-arounds to figure out which ones can be selected for
multi-platform kernels without side effects on unaffected parts (i.e.
set a chicken bit based on core revision). For any in runtime paths, we
may need to do runtime patching if they have performance impact.

Rob

  reply	other threads:[~2012-11-14 21:57 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-14 18:53 [PATCH] ARM: Fix errata 751472 handling on Cortex-A9 r1p* Tony Lindgren
2012-11-14 19:01 ` Russell King - ARM Linux
2012-11-14 19:19   ` Tony Lindgren
2012-11-14 19:06 ` Jon Hunter
2012-11-14 19:21   ` Tony Lindgren
2012-11-14 20:22   ` Russell King - ARM Linux
2012-11-14 20:32     ` Tony Lindgren
2012-11-14 21:57       ` Rob Herring [this message]
2012-11-14 22:21         ` Tony Lindgren
2012-11-15  0:54           ` Rob Herring
2012-11-15  2:08             ` Tony Lindgren
2012-11-15 11:01             ` Catalin Marinas
2012-11-15 12:41               ` Siarhei Siamashka
2012-11-15 13:36                 ` Russell King - ARM Linux
2012-11-15 13:52                 ` Catalin Marinas
2012-11-15 15:14                   ` Måns Rullgård
2012-11-15 14:31               ` Rob Herring
2012-11-15 14:37                 ` Catalin Marinas
2012-11-15 15:37                   ` Rob Herring
2012-11-15 16:06                     ` Catalin Marinas
2012-11-16 10:05                     ` Russell King - ARM Linux
2012-11-16 17:13                       ` Tony Lindgren
2012-11-16 18:41                         ` Russell King - ARM Linux
2012-11-16  9:59                 ` Russell King - ARM Linux
2012-11-16 18:09                   ` Catalin Marinas
2012-11-16 18:39                     ` Russell King - ARM Linux
2012-11-17 10:46                       ` Catalin Marinas
2012-11-15  9:22           ` Russell King - ARM Linux
2012-12-12  0:46         ` Jon Masters

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=50A413D4.7000405@gmail.com \
    --to=robherring2@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).