summaryrefslogtreecommitdiff
path: root/Documentation/process/debugging/driver_development_debugging_guide.rst
diff options
context:
space:
mode:
authorRandy Dunlap <rdunlap@infradead.org>2024-11-30 00:11:06 -0800
committerJonathan Corbet <corbet@lwn.net>2024-12-11 09:07:40 -0700
commit126437fc26be0629585f956b890e6314f56cd63b (patch)
tree4608bda5325ac60baff0293854a0ff95bf09bca2 /Documentation/process/debugging/driver_development_debugging_guide.rst
parent28884915e6b14c9af4ddbb5f89d64edd863494c0 (diff)
docs: debugging: add more info about devcoredump
Correct a few small things in the devcoredump synopsis and then add the devcoredump APIs to it. Fixes: a037699da0a1 ("docs: Add debugging section to process") Signed-off-by: Randy Dunlap <rdunlap@infradead.org> Cc: Sebastian Fricke <sebastian.fricke@collabora.com> Cc: Jonathan Corbet <corbet@lwn.net> Cc: linux-doc@vger.kernel.org Cc: Johannes Berg <johannes@sipsolutions.net> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: workflows@vger.kernel.org Signed-off-by: Jonathan Corbet <corbet@lwn.net> Link: https://lore.kernel.org/r/20241130081107.552503-1-rdunlap@infradead.org
Diffstat (limited to 'Documentation/process/debugging/driver_development_debugging_guide.rst')
-rw-r--r--Documentation/process/debugging/driver_development_debugging_guide.rst20
1 files changed, 16 insertions, 4 deletions
diff --git a/Documentation/process/debugging/driver_development_debugging_guide.rst b/Documentation/process/debugging/driver_development_debugging_guide.rst
index aef204094205..46becda8764b 100644
--- a/Documentation/process/debugging/driver_development_debugging_guide.rst
+++ b/Documentation/process/debugging/driver_development_debugging_guide.rst
@@ -207,17 +207,29 @@ resources, that can cause performance disruptions or even OOM kills.
device coredump
---------------
-Prerequisite: ``#include <linux/devcoredump.h>``
+Prerequisite: ``CONFIG_DEV_COREDUMP`` & ``#include <linux/devcoredump.h>``
Provides the infrastructure for a driver to provide arbitrary data to userland.
It is most often used in conjunction with udev or similar userland application
to listen for kernel uevents, which indicate that the dump is ready. Udev has
rules to copy that file somewhere for long-term storage and analysis, as by
-default, the data for the dump is automatically cleaned up after 5 minutes.
-That data is analyzed with driver-specific tools or GDB.
+default, the data for the dump is automatically cleaned up after a default
+5 minutes. That data is analyzed with driver-specific tools or GDB.
+
+A device coredump can be created with a vmalloc area, with read/free
+methods, or as a scatter/gather list.
You can find an example implementation at:
`drivers/media/platform/qcom/venus/core.c
-<https://elixir.bootlin.com/linux/v6.11.6/source/drivers/media/platform/qcom/venus/core.c#L30>`__
+<https://elixir.bootlin.com/linux/v6.11.6/source/drivers/media/platform/qcom/venus/core.c#L30>`__,
+in the Bluetooth HCI layer, in several wireless drivers, and in several
+DRM drivers.
+
+devcoredump interfaces
+~~~~~~~~~~~~~~~~~~~~~~
+
+.. kernel-doc:: include/linux/devcoredump.h
+
+.. kernel-doc:: drivers/base/devcoredump.c
**Copyright** ©2024 : Collabora