summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python
diff options
context:
space:
mode:
authorChristian Brauner <brauner@kernel.org>2026-08-20 01:09:29 +0200
committerChristian Brauner <brauner@kernel.org>2026-09-22 13:24:59 +0200
commit98a2606e329542625a67d4d980778581148c7e0a (patch)
treed240f77836cff33176324a8ac90917690e1e3605 /tools/perf/scripts/python
parentaf7e6acf00bfc028073b4cea2e9d313703987144 (diff)
coredump: clean up coredump state handling
Right now coredump state handling is messy. The binfmt->core_dump:: methods return 1 when the coredump method did anything at all which means that a partial write counts as having dumped core. This is fine as the state is really only used to indicate that a coredump event occurred in the exit status of the task. That should obviously be indicated even if the actual writeout of the coredump failed. But it means the coredump method of the binary formats is different from all the other coredump helpers. And there's no way to communicate to userspace that a coredump was truncated. We'll add support for that in a second. For now, clean this up. Add a flag member into struct coredump_params. Let the coredump method raise COREDUMP_STATE_STARTED. This is what coredump_finish() will end up using to splice in the coredump bit into the exit status. This allows us to let the return value mean success or failure and align it with the other coredump helpers. We also start raising COREDUMP_STATE_TRUNCATED. This will be used in the next patches to communicate truncation to userspace via the coredump socket. No functional changes. Link: https://patch.msgid.link/20260820-work-coredump-sparse-v2-12-ba32dd718c51@kernel.org Signed-off-by: Christian Brauner (Amutable) <brauner@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions