Linux Documentation
 help / color / mirror / Atom feed
* [PATCH] docs: submitting-patches: Limit backtrace trimming to timestamps
@ 2026-11-26  8:12 Leon Romanovsky
  2026-11-26  9:45 ` Geert Uytterhoeven
  0 siblings, 1 reply; 3+ messages in thread
From: Leon Romanovsky @ 2026-11-26  8:12 UTC (permalink / raw)
  To: Jonathan Corbet, Shuah Khan, Randy Dunlap; +Cc: workflows, linux-doc

From: Leon Romanovsky <leonro@nvidia.com>

AI tools tend to trim backtraces too far. Taint flags, module lists and
module names disappear, which hides that an out-of-tree module was
involved or that an in-kernel API was misused, especially a driver API
that is not meant for general use.

Ask authors to remove only the timestamps and drop the example, which
shows a trace reduced to bare function names. Timestamps are the one
part of a dump that adds only noise.

Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
---
 Documentation/process/submitting-patches.rst | 20 ++++----------------
 1 file changed, 4 insertions(+), 16 deletions(-)

diff --git a/Documentation/process/submitting-patches.rst b/Documentation/process/submitting-patches.rst
index 85ba046d66fbf..56b1b38ac59cf 100644
--- a/Documentation/process/submitting-patches.rst
+++ b/Documentation/process/submitting-patches.rst
@@ -763,22 +763,10 @@ phrase``, it is important to be both succinct as well as descriptive.
 Backtraces in commit messages
 """""""""""""""""""""""""""""
 
-Backtraces help document the call chain leading to a problem. However,
-not all backtraces are helpful. For example, early boot call chains are
-unique and obvious. Copying the full dmesg output verbatim, however,
-adds distracting information like timestamps, module lists, register and
-stack dumps.
-
-Therefore, the most useful backtraces should distill the relevant
-information from the dump, which makes it easier to focus on the real
-issue. Here is an example of a well-trimmed backtrace::
-
-  unchecked MSR access error: WRMSR to 0xd51 (tried to write 0x0000000000000064)
-  at rIP: 0xffffffffae059994 (native_write_msr+0x4/0x20)
-  Call Trace:
-  mba_wrmsr
-  update_domains
-  rdtgroup_mkdir
+Backtraces help document the call chain leading to a problem. Remove
+only the timestamps and keep the rest of the dump unchanged. Taint
+flags, module lists and module names show whether an out-of-tree module
+was involved or an in-kernel API was misused.
 
 Commentary
 ^^^^^^^^^^

---
base-commit: b6a9fa34ce4187cb69d3c588a4bbffc31ce5db8f
change-id: 20261125-backtrace-timestamps-29880a2f1cab

Best regards,
--  
Leon Romanovsky <leon@kernel.org>


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

* Re: [PATCH] docs: submitting-patches: Limit backtrace trimming to timestamps
  2026-11-26  8:12 [PATCH] docs: submitting-patches: Limit backtrace trimming to timestamps Leon Romanovsky
@ 2026-11-26  9:45 ` Geert Uytterhoeven
  2026-11-26 10:03   ` Leon Romanovsky
  0 siblings, 1 reply; 3+ messages in thread
From: Geert Uytterhoeven @ 2026-11-26  9:45 UTC (permalink / raw)
  To: Leon Romanovsky
  Cc: Jonathan Corbet, Shuah Khan, Randy Dunlap, workflows, linux-doc

On Thu, 26 Nov 2026 at 09:13, Leon Romanovsky <leon@kernel.org> wrote:
> From: Leon Romanovsky <leonro@nvidia.com>
>
> AI tools tend to trim backtraces too far. Taint flags, module lists and
> module names disappear, which hides that an out-of-tree module was
> involved or that an in-kernel API was misused, especially a driver API
> that is not meant for general use.
>
> Ask authors to remove only the timestamps and drop the example, which
> shows a trace reduced to bare function names. Timestamps are the one
> part of a dump that adds only noise.
>
> Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
> ---
>  Documentation/process/submitting-patches.rst | 20 ++++----------------
>  1 file changed, 4 insertions(+), 16 deletions(-)
>
> diff --git a/Documentation/process/submitting-patches.rst b/Documentation/process/submitting-patches.rst
> index 85ba046d66fbf..56b1b38ac59cf 100644
> --- a/Documentation/process/submitting-patches.rst
> +++ b/Documentation/process/submitting-patches.rst
> @@ -763,22 +763,10 @@ phrase``, it is important to be both succinct as well as descriptive.
>  Backtraces in commit messages
>  """""""""""""""""""""""""""""
>
> -Backtraces help document the call chain leading to a problem. However,
> -not all backtraces are helpful. For example, early boot call chains are
> -unique and obvious. Copying the full dmesg output verbatim, however,
> -adds distracting information like timestamps, module lists, register and
> -stack dumps.
> -
> -Therefore, the most useful backtraces should distill the relevant
> -information from the dump, which makes it easier to focus on the real
> -issue. Here is an example of a well-trimmed backtrace::
> -
> -  unchecked MSR access error: WRMSR to 0xd51 (tried to write 0x0000000000000064)
> -  at rIP: 0xffffffffae059994 (native_write_msr+0x4/0x20)
> -  Call Trace:
> -  mba_wrmsr
> -  update_domains
> -  rdtgroup_mkdir
> +Backtraces help document the call chain leading to a problem. Remove
> +only the timestamps and keep the rest of the dump unchanged. Taint
> +flags, module lists and module names show whether an out-of-tree module
> +was involved or an in-kernel API was misused.

Please don't move the burden of distilling the relevant information
from the (single) sender to the (multiple) receivers.

Gr{oetje,eeting}s,

                        Geert

-- 
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

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

* Re: [PATCH] docs: submitting-patches: Limit backtrace trimming to timestamps
  2026-11-26  9:45 ` Geert Uytterhoeven
@ 2026-11-26 10:03   ` Leon Romanovsky
  0 siblings, 0 replies; 3+ messages in thread
From: Leon Romanovsky @ 2026-11-26 10:03 UTC (permalink / raw)
  To: Geert Uytterhoeven
  Cc: Jonathan Corbet, Shuah Khan, Randy Dunlap, workflows, linux-doc

On Thu, Nov 26, 2026 at 10:45:17AM +0100, Geert Uytterhoeven wrote:
> On Thu, 26 Nov 2026 at 09:13, Leon Romanovsky <leon@kernel.org> wrote:
> > From: Leon Romanovsky <leonro@nvidia.com>
> >
> > AI tools tend to trim backtraces too far. Taint flags, module lists and
> > module names disappear, which hides that an out-of-tree module was
> > involved or that an in-kernel API was misused, especially a driver API
> > that is not meant for general use.
> >
> > Ask authors to remove only the timestamps and drop the example, which
> > shows a trace reduced to bare function names. Timestamps are the one
> > part of a dump that adds only noise.
> >
> > Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
> > ---
> >  Documentation/process/submitting-patches.rst | 20 ++++----------------
> >  1 file changed, 4 insertions(+), 16 deletions(-)
> >
> > diff --git a/Documentation/process/submitting-patches.rst b/Documentation/process/submitting-patches.rst
> > index 85ba046d66fbf..56b1b38ac59cf 100644
> > --- a/Documentation/process/submitting-patches.rst
> > +++ b/Documentation/process/submitting-patches.rst
> > @@ -763,22 +763,10 @@ phrase``, it is important to be both succinct as well as descriptive.
> >  Backtraces in commit messages
> >  """""""""""""""""""""""""""""
> >
> > -Backtraces help document the call chain leading to a problem. However,
> > -not all backtraces are helpful. For example, early boot call chains are
> > -unique and obvious. Copying the full dmesg output verbatim, however,
> > -adds distracting information like timestamps, module lists, register and
> > -stack dumps.
> > -
> > -Therefore, the most useful backtraces should distill the relevant
> > -information from the dump, which makes it easier to focus on the real
> > -issue. Here is an example of a well-trimmed backtrace::
> > -
> > -  unchecked MSR access error: WRMSR to 0xd51 (tried to write 0x0000000000000064)
> > -  at rIP: 0xffffffffae059994 (native_write_msr+0x4/0x20)
> > -  Call Trace:
> > -  mba_wrmsr
> > -  update_domains
> > -  rdtgroup_mkdir
> > +Backtraces help document the call chain leading to a problem. Remove
> > +only the timestamps and keep the rest of the dump unchanged. Taint
> > +flags, module lists and module names show whether an out-of-tree module
> > +was involved or an in-kernel API was misused.
> 
> Please don't move the burden of distilling the relevant information
> from the (single) sender to the (multiple) receivers.

Kernel dump stacks have evolved over the years into their current form. They
contain different kinds of information, and you will often look for different
clues when working on different patches, even within the same subsystem.

The coding style guidance currently documented in Documentation contradicts
even with the basic debugging aid Greg describes here:
https://lwn.net/Articles/1103714/:

  Tainting (or not) on manual driver binding
  	...
	Early in the 7.4 merge window, Greg Kroah-Hartman applied a patch that caused
	the kernel to be marked as tainted whenever user space manually binds or unbinds
	a device driver to a device. This change was meant to be a defense against
	a flood of spurious bug reports generated by fuzzers,
	...

A commit message should help people understand why a patch is needed. This
one instead seems designed to persuade an AI to merge it without providing
enough information.

For reference, see this discussion of how AI fabricates reports today and
will do so in the future:
https://lore.kernel.org/workflows/20261116200515.352387-1-sashal@kernel.org/

Thanks

> 
> Gr{oetje,eeting}s,
> 
>                         Geert
> 
> -- 
> Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
> 
> In personal conversations with technical people, I call myself a hacker. But
> when I'm talking to journalists I just say "programmer" or something like that.
>                                 -- Linus Torvalds

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

end of thread, other threads:[~2026-11-26 10:03 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-26  8:12 [PATCH] docs: submitting-patches: Limit backtrace trimming to timestamps Leon Romanovsky
2026-11-26  9:45 ` Geert Uytterhoeven
2026-11-26 10:03   ` Leon Romanovsky

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