public inbox for linux-doc@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Documentation: Provide hints on how to debug Python GDB scripts
@ 2026-03-26 23:32 Florian Fainelli
  2026-03-27 17:50 ` Radu Rendec
  2026-03-30 16:15 ` Jonathan Corbet
  0 siblings, 2 replies; 3+ messages in thread
From: Florian Fainelli @ 2026-03-26 23:32 UTC (permalink / raw)
  To: linux-kernel, akpm
  Cc: tglx, radu, Florian Fainelli, Jonathan Corbet, Shuah Khan,
	Illia Ostapyshyn, open list:DOCUMENTATION PROCESS,
	open list:DOCUMENTATION

By default GDB does not print a full stack of its integrated Python
interpreter, thus making the debugging of GDB scripts more painful than
it has to be.

Suggested-by: Radu Rendec <radu@rendec.net>
Signed-off-by: Florian Fainelli <florian.fainelli@broadcom.com>
---
 Documentation/process/debugging/gdb-kernel-debugging.rst | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/Documentation/process/debugging/gdb-kernel-debugging.rst b/Documentation/process/debugging/gdb-kernel-debugging.rst
index 9475c759c722..53e225760a4d 100644
--- a/Documentation/process/debugging/gdb-kernel-debugging.rst
+++ b/Documentation/process/debugging/gdb-kernel-debugging.rst
@@ -173,3 +173,12 @@ this is just a snapshot of the initial version::
 
 Detailed help can be obtained via "help <command-name>" for commands and "help
 function <function-name>" for convenience functions.
+
+Debugging GDB scripts
+---------------------
+
+GDB does not enable a full Python backtrace which can make debugging GDB
+scripts more difficult than necessary. The following will allow for printing a
+full backtrace of the python environment::
+
+ (gdb) set python print-stack full
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] Documentation: Provide hints on how to debug Python GDB scripts
  2026-03-26 23:32 [PATCH] Documentation: Provide hints on how to debug Python GDB scripts Florian Fainelli
@ 2026-03-27 17:50 ` Radu Rendec
  2026-03-30 16:15 ` Jonathan Corbet
  1 sibling, 0 replies; 3+ messages in thread
From: Radu Rendec @ 2026-03-27 17:50 UTC (permalink / raw)
  To: Florian Fainelli, linux-kernel, akpm
  Cc: tglx, Jonathan Corbet, Shuah Khan, Illia Ostapyshyn,
	open list:DOCUMENTATION PROCESS, open list:DOCUMENTATION

On Thu, 2026-03-26 at 16:32 -0700, Florian Fainelli wrote:
> By default GDB does not print a full stack of its integrated Python
> interpreter, thus making the debugging of GDB scripts more painful than
> it has to be.
> 
> Suggested-by: Radu Rendec <radu@rendec.net>
> Signed-off-by: Florian Fainelli <florian.fainelli@broadcom.com>
> ---
>  Documentation/process/debugging/gdb-kernel-debugging.rst | 9 +++++++++
>  1 file changed, 9 insertions(+)
> 
> diff --git a/Documentation/process/debugging/gdb-kernel-debugging.rst b/Documentation/process/debugging/gdb-kernel-debugging.rst
> index 9475c759c722..53e225760a4d 100644
> --- a/Documentation/process/debugging/gdb-kernel-debugging.rst
> +++ b/Documentation/process/debugging/gdb-kernel-debugging.rst
> @@ -173,3 +173,12 @@ this is just a snapshot of the initial version::
>  
>  Detailed help can be obtained via "help <command-name>" for commands and "help
>  function <function-name>" for convenience functions.
> +
> +Debugging GDB scripts
> +---------------------
> +
> +GDB does not enable a full Python backtrace which can make debugging GDB
> +scripts more difficult than necessary. The following will allow for printing a
> +full backtrace of the python environment::
> +
> + (gdb) set python print-stack full

Reviewed-by: Radu Rendec <radu@rendec.net>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] Documentation: Provide hints on how to debug Python GDB scripts
  2026-03-26 23:32 [PATCH] Documentation: Provide hints on how to debug Python GDB scripts Florian Fainelli
  2026-03-27 17:50 ` Radu Rendec
@ 2026-03-30 16:15 ` Jonathan Corbet
  1 sibling, 0 replies; 3+ messages in thread
From: Jonathan Corbet @ 2026-03-30 16:15 UTC (permalink / raw)
  To: Florian Fainelli, linux-kernel, akpm
  Cc: tglx, radu, Florian Fainelli, Shuah Khan, Illia Ostapyshyn,
	open list:DOCUMENTATION PROCESS, open list:DOCUMENTATION

Florian Fainelli <florian.fainelli@broadcom.com> writes:

> By default GDB does not print a full stack of its integrated Python
> interpreter, thus making the debugging of GDB scripts more painful than
> it has to be.
>
> Suggested-by: Radu Rendec <radu@rendec.net>
> Signed-off-by: Florian Fainelli <florian.fainelli@broadcom.com>
> ---
>  Documentation/process/debugging/gdb-kernel-debugging.rst | 9 +++++++++
>  1 file changed, 9 insertions(+)
>
> diff --git a/Documentation/process/debugging/gdb-kernel-debugging.rst b/Documentation/process/debugging/gdb-kernel-debugging.rst
> index 9475c759c722..53e225760a4d 100644
> --- a/Documentation/process/debugging/gdb-kernel-debugging.rst
> +++ b/Documentation/process/debugging/gdb-kernel-debugging.rst
> @@ -173,3 +173,12 @@ this is just a snapshot of the initial version::
>  
>  Detailed help can be obtained via "help <command-name>" for commands and "help
>  function <function-name>" for convenience functions.
> +
> +Debugging GDB scripts
> +---------------------
> +
> +GDB does not enable a full Python backtrace which can make debugging GDB
> +scripts more difficult than necessary. The following will allow for printing a
> +full backtrace of the python environment::
> +
> + (gdb) set python print-stack full

Applied, thanks.

jon

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2026-03-30 16:15 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-26 23:32 [PATCH] Documentation: Provide hints on how to debug Python GDB scripts Florian Fainelli
2026-03-27 17:50 ` Radu Rendec
2026-03-30 16:15 ` Jonathan Corbet

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox