[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20220427184716.1949239-1-kaleshsingh@google.com>
Date: Wed, 27 Apr 2022 11:46:55 -0700
From: Kalesh Singh <kaleshsingh@...gle.com>
To: unlisted-recipients:; (no To-header on input)
Cc: mark.rutland@....com, will@...nel.org, maz@...nel.org,
qperret@...gle.com, tabba@...gle.com, surenb@...gle.com,
kernel-team@...roid.com, Kalesh Singh <kaleshsingh@...gle.com>,
James Morse <james.morse@....com>,
Alexandru Elisei <alexandru.elisei@....com>,
Suzuki K Poulose <suzuki.poulose@....com>,
Catalin Marinas <catalin.marinas@....com>,
Mark Brown <broonie@...nel.org>,
Masami Hiramatsu <mhiramat@...nel.org>,
Peter Collingbourne <pcc@...gle.com>,
Alexei Starovoitov <ast@...nel.org>,
"Madhavan T. Venkataraman" <madvenka@...ux.microsoft.com>,
Andrew Jones <drjones@...hat.com>,
Keir Fraser <keirf@...gle.com>,
Zenghui Yu <yuzenghui@...wei.com>,
Kefeng Wang <wangkefeng.wang@...wei.com>,
linux-arm-kernel@...ts.infradead.org, kvmarm@...ts.cs.columbia.edu,
linux-kernel@...r.kernel.org
Subject: [PATCH 0/4] KVM nVHE Hypervisor stack unwinder
Hi all,
This series is based on arm64 for-next/core and is also dependent
on the series at [1].
A previous version of hypervisor stack unwinding was included
in the series at [2].
This new version of the unwinder splits the unwinding and dumping
of the stack between the hypervisor and host:
- The hyperviosr unwinds its stack and dumps the address entries
into a page shared with the host.
- The host then symnolizes and prints the hyp stacktrace from
the shared page.
The new approach doesn't depend on CONFIG_NVHE_EL2_DEBUG,
and allows dumping hyp stacktraces in prodcution environments
(!CONFIG_NVHE_EL2_DEBUG).
arm64/kernel/stacktrace.c is compiled twice: stacktrace.o for the
host kernel and stacktrace.nvhe.o for the hypervisor: This allows
reusing most of the host unwinding logic in the nVHE hypervisor.
[1] https://lore.kernel.org/r/20220420214317.3303360-1-kaleshsingh@google.com/
[2] https://lore.kernel.org/r/20220314200148.2695206-1-kaleshsingh@google.com/
Thanks,
Kalesh
Kalesh Singh (4):
KVM: arm64: Compile stacktrace.nvhe.o
KVM: arm64: Add hypervisor overflow stack
KVM: arm64: Allocate shared stacktrace pages
KVM: arm64: Unwind and dump nVHE hypervisor stacktrace
arch/arm64/include/asm/kvm_asm.h | 1 +
arch/arm64/include/asm/stacktrace.h | 58 +++++++++--
arch/arm64/kernel/stacktrace.c | 151 +++++++++++++++++++++++-----
arch/arm64/kvm/arm.c | 34 +++++++
arch/arm64/kvm/handle_exit.c | 4 +
arch/arm64/kvm/hyp/nvhe/Makefile | 3 +-
arch/arm64/kvm/hyp/nvhe/host.S | 9 +-
arch/arm64/kvm/hyp/nvhe/setup.c | 11 ++
arch/arm64/kvm/hyp/nvhe/switch.c | 4 +
9 files changed, 231 insertions(+), 44 deletions(-)
--
2.36.0.rc2.479.g8af0fa9b8e-goog
Powered by blists - more mailing lists