summaryrefslogtreecommitdiff
path: root/arch/powerpc/platforms/powernv/Kconfig
diff options
context:
space:
mode:
authorRashmica Gupta <rashmica.g@gmail.com>2017-06-01 08:34:38 +0300
committerMichael Ellerman <mpe@ellerman.id.au>2017-08-24 15:14:38 +0300
commit9d5171a8f248b1b0e69329bf141e17645c0324a0 (patch)
treed7b7336097434b19190e69dc1bf5cbef317c133b /arch/powerpc/platforms/powernv/Kconfig
parent2dea1d9c38e481051fa0e62807e518c5768e62dd (diff)
downloadlinux-9d5171a8f248b1b0e69329bf141e17645c0324a0.tar.xz
powerpc/powernv: Enable removal of memory for in memory tracing
The hardware trace macro feature requires access to a chunk of real memory. This patch provides a debugfs interface to do this. By writing an integer containing the size of memory to be unplugged into /sys/kernel/debug/powerpc/memtrace/enable, the code will attempt to remove that much memory from the end of each NUMA node. This patch also adds additional debugsfs files for each node that allows the tracer to interact with the removed memory, as well as a trace file that allows userspace to read the generated trace. Note that this patch does not invoke the hardware trace macro, it only allows memory to be removed during runtime for the trace macro to utilise. Signed-off-by: Rashmica Gupta <rashmica.g@gmail.com> [mpe: Minor formatting etc fixups] Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'arch/powerpc/platforms/powernv/Kconfig')
-rw-r--r--arch/powerpc/platforms/powernv/Kconfig8
1 files changed, 8 insertions, 0 deletions
diff --git a/arch/powerpc/platforms/powernv/Kconfig b/arch/powerpc/platforms/powernv/Kconfig
index 6a6f4ef46b9e..d7bacb20529c 100644
--- a/arch/powerpc/platforms/powernv/Kconfig
+++ b/arch/powerpc/platforms/powernv/Kconfig
@@ -30,3 +30,11 @@ config OPAL_PRD
help
This enables the opal-prd driver, a facility to run processor
recovery diagnostics on OpenPower machines
+
+config PPC_MEMTRACE
+ bool "Enable removal of RAM from kernel mappings for tracing"
+ depends on PPC_POWERNV && MEMORY_HOTREMOVE
+ default n
+ help
+ Enabling this option allows for the removal of memory (RAM)
+ from the kernel mappings to be used for hardware tracing.