Re: [ 045/262] ARM: 7501/1: decompressor: reset ttbcr for VMSAARMv7 cores

From: Ben Hutchings
Date: Sat Sep 29 2012 - 08:26:04 EST


On Fri, 2012-09-28 at 11:49 -0700, Greg Kroah-Hartman wrote:
> From: Greg KH <gregkh@xxxxxxxxxxxxxxxxxxx>
>
> 3.5-stable review patch. If anyone has any objections, please let me know.
>
> ------------------
>
> From: Will Deacon <will.deacon@xxxxxxx>
>
> commit dbece45894d3ab1baac15a96dc4e1e8e23f64a93 upstream.
>
> When enabling the MMU for ARMv7 CPUs, the decompressor does not touch
> the ttbcr register, assuming that it will be zeroed (N == 0, EAE == 0).
> Given that only EAE is defined as 0 for non-secure copies of the
> register (and a bootloader such as kexec may leave it set to 1 anyway),
> we should ensure that we reset the register ourselves before turning on
> the MMU.
>
> This patch zeroes TTBCR.EAE and TTBCR.N prior to enabling the MMU for
> ARMv7 cores in the decompressor, configuring us exclusively for 32-bit
> translation tables via TTBR0.
>
> Acked-by: Nicolas Pitre <nico@xxxxxxxxxx>
> Signed-off-by: Matthew Leach <matthew.leach@xxxxxxx>
> Signed-off-by: Will Deacon <will.deacon@xxxxxxx>
> Signed-off-by: Russell King <rmk+kernel@xxxxxxxxxxxxxxxx>
> Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
[...]

Is this also needed for earlier kernel versions? If so, can you provide
a backported version?

Ben.

--
Ben Hutchings
Usenet is essentially a HUGE group of people passing notes in class.
- Rachel Kadel, `A Quick Guide to Newsgroup Etiquette'

Attachment: signature.asc
Description: This is a digitally signed message part