* "arm64: alternatives: use tpidr_el2 on VHE hosts" v4.9 backport missing edits to proc.S
@ 2020-01-08 1:09 Stephen Warren
2020-01-08 18:08 ` Stephen Warren
0 siblings, 1 reply; 3+ messages in thread
From: Stephen Warren @ 2020-01-08 1:09 UTC (permalink / raw)
To: James Morse
Cc: Marc Zyngier, Catalin Marinas, stable, ARM kernel mailing list,
Greg Kroah-Hartman
James,
I'm looking at commit 6d99b68933fbcf51f84fcbba49246ce1209ec193 ("arm64:
alternatives: use tpidr_el2 on VHE hosts"). When it was back-ported to
v4.9.x as eea59020a7f2993018ccde317387031c04c62036, the changes to
arch/arm64/mm/proc.S weren't included. I assume this was just an
accident, or was there some specific reason for this? Either way, I do
find that I need those changes for system suspend/resume to work in my
downstream vendor fork of v4.9 if I enable KVM support in .config. I'm
happy to send a patch for v4.9.x to add those changes back if that's the
way to go. v4.14.x and later don't have this issue.
Thanks.
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: "arm64: alternatives: use tpidr_el2 on VHE hosts" v4.9 backport missing edits to proc.S 2020-01-08 1:09 "arm64: alternatives: use tpidr_el2 on VHE hosts" v4.9 backport missing edits to proc.S Stephen Warren @ 2020-01-08 18:08 ` Stephen Warren 2020-01-08 18:22 ` Greg Kroah-Hartman 0 siblings, 1 reply; 3+ messages in thread From: Stephen Warren @ 2020-01-08 18:08 UTC (permalink / raw) To: James Morse Cc: Marc Zyngier, Catalin Marinas, stable, ARM kernel mailing list, Greg Kroah-Hartman On 1/7/20 6:09 PM, Stephen Warren wrote: > James, > > I'm looking at commit 6d99b68933fbcf51f84fcbba49246ce1209ec193 ("arm64: > alternatives: use tpidr_el2 on VHE hosts"). When it was back-ported to > v4.9.x as eea59020a7f2993018ccde317387031c04c62036, the changes to > arch/arm64/mm/proc.S weren't included. I assume this was just an > accident, or was there some specific reason for this? Either way, I do > find that I need those changes for system suspend/resume to work in my > downstream vendor fork of v4.9 if I enable KVM support in .config. I'm > happy to send a patch for v4.9.x to add those changes back if that's the > way to go. v4.14.x and later don't have this issue. Upon further investigation of git history, here's what happened: When When 6d99b68933fb was back-ported to upstream v4.9.x as eea59020a7f2, proc.S didn't save/restore tpidr_el1 at all, so that's why the edits to proc.S were dropped as part of the backport. Separately, in android-4.9, 0ec37136b90e ("UPSTREAM: arm64: move sp_el0 and tpidr_el1 into cpu_suspend_ctx") modified proc.S to save/restore tpidir_el1. When those two commits were later merged together in android-4.9, the modifications to proc.S to alternate between tpidr_el1/2 should have been added back in, but weren't. Since our downstream 4.9 fork is based on android-4.9 after that merge, it picked up this issue and needs to be patched for it. Anyone else using android-4.9 would need this fix too. However, upstream 4.9.x stable doesn't have an issue. _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel ^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: "arm64: alternatives: use tpidr_el2 on VHE hosts" v4.9 backport missing edits to proc.S 2020-01-08 18:08 ` Stephen Warren @ 2020-01-08 18:22 ` Greg Kroah-Hartman 0 siblings, 0 replies; 3+ messages in thread From: Greg Kroah-Hartman @ 2020-01-08 18:22 UTC (permalink / raw) To: Stephen Warren Cc: Marc Zyngier, Catalin Marinas, James Morse, stable, ARM kernel mailing list On Wed, Jan 08, 2020 at 11:08:20AM -0700, Stephen Warren wrote: > On 1/7/20 6:09 PM, Stephen Warren wrote: > > James, > > > > I'm looking at commit 6d99b68933fbcf51f84fcbba49246ce1209ec193 ("arm64: > > alternatives: use tpidr_el2 on VHE hosts"). When it was back-ported to > > v4.9.x as eea59020a7f2993018ccde317387031c04c62036, the changes to > > arch/arm64/mm/proc.S weren't included. I assume this was just an > > accident, or was there some specific reason for this? Either way, I do > > find that I need those changes for system suspend/resume to work in my > > downstream vendor fork of v4.9 if I enable KVM support in .config. I'm > > happy to send a patch for v4.9.x to add those changes back if that's the > > way to go. v4.14.x and later don't have this issue. > > Upon further investigation of git history, here's what happened: > > When When 6d99b68933fb was back-ported to upstream v4.9.x as eea59020a7f2, > proc.S didn't save/restore tpidr_el1 at all, so that's why the edits to > proc.S were dropped as part of the backport. > > Separately, in android-4.9, 0ec37136b90e ("UPSTREAM: arm64: move sp_el0 and > tpidr_el1 into cpu_suspend_ctx") modified proc.S to save/restore tpidir_el1. > When those two commits were later merged together in android-4.9, the > modifications to proc.S to alternate between tpidr_el1/2 should have been > added back in, but weren't. > > Since our downstream 4.9 fork is based on android-4.9 after that merge, it > picked up this issue and needs to be patched for it. Anyone else using > android-4.9 would need this fix too. However, upstream 4.9.x stable doesn't > have an issue. Thanks for figuring this out. If you could submit a 4.9 patch to AOSP for this, that would be great, or I can do it myself if you have a patch. thanks, greg k-h _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-01-08 18:22 UTC | newest] Thread overview: 3+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2020-01-08 1:09 "arm64: alternatives: use tpidr_el2 on VHE hosts" v4.9 backport missing edits to proc.S Stephen Warren 2020-01-08 18:08 ` Stephen Warren 2020-01-08 18:22 ` Greg Kroah-Hartman
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).