[PATCH v2] ARM: save/restore diagnostic register on Cortex-A9 suspend/resume

Will Deacon will.deacon at arm.com
Wed Jul 2 05:34:44 PDT 2014


Hi Tomasz,

I asked the hardware guys to take a closer look at your issue and they've
uncovered the problem with trying to document an undocumented register.

On Tue, Jul 01, 2014 at 05:26:05PM +0100, Tomasz Figa wrote:
> On 01.07.2014 16:44, Russell King - ARM Linux wrote:
> > On Tue, Jun 24, 2014 at 07:40:27PM +0200, Tomasz Figa wrote:
> >> On 24.06.2014 18:33, Will Deacon wrote:
> >>> On A9, it should be write-ignore. Are you seeing problems on a real SoC?
> >>
> >> I'm observing a complete system hang on Exynos4412-based Trats2 board if
> >> I try to write this register in resume from system-wide sleep.

In actual fact, this register causes an undefined instruction exception if
you try to write it from a non-secure mode (although reads work fine, for
whatever that's worth). That nicely explains what you're seeing, but it
leaves us in a right old two and eight with respect to the suspend/resume
code.

Given that we don't know whether we're running secure or non-secure, I'm
not sure about the best approach to solve this. For arm64, we simply mandate
booting non-secure and require firmware to do everything that requires
secure access, but we're not in a position to attempt imposing these sorts
of restrictions for arch/arm/.

Does anybody have any ideas? We could try `handling' the undef, but it's
ugly and fragile.

Anyway, apologies for the mistake earlier on -- I assumed the documentation
I had was correct.

Will



More information about the linux-arm-kernel mailing list