Thread (18 messages) 18 messages, 4 authors, 2026-02-03

Re: [PATCH net-next v5 1/4] printk: Add execution context (task name/CPU) to printk_info

From: Breno Leitao <leitao@debian.org>
Date: 2026-02-02 11:50:08
Also in: lkml

Hello Jakub,

On Fri, Jan 30, 2026 at 05:32:43PM -0800, Jakub Kicinski wrote:
On Wed, 28 Jan 2026 06:17:37 -0800 Breno Leitao wrote:
quoted
+config CONSOLE_HAS_EXECUTION_CTX
+	bool
+	help
+	  Selected by console drivers that support execution context
+	  (task name/CPU) in their output. This enables PRINTK_EXECUTION_CTX
+	  to provide the necessary infrastructure.
+
+config PRINTK_EXECUTION_CTX
+	bool "Include execution context (task/CPU) in printk messages"
+	depends on PRINTK && CONSOLE_HAS_EXECUTION_CTX
+	default CONSOLE_HAS_EXECUTION_CTX
AFAIU the double-symbol thing serves no practical purpose?

If none of the console drivers uses the metadata what would be the
point of capturing it?

Conversely if some console driver wants this data there's no option
for the user to disable it.

AFAICT this patch should only add one invisible symbol for capturing
the context and have netcons enable it.
The two-symbol design establishes a clear separation between what console
drivers require and how the printk core implements it.

This approach was discussed here:
https://lore.kernel.org/all/87eco09hgb.fsf@jogness.linutronix.de/ (local)
I don't see a reason at this
stage to prompt users with netcons disabled whether they want
PRINTK_EXECUTION_CTX
Users won't see a prompt when netconsole is disabled. Since
CONSOLE_HAS_EXECUTION_CTX is only selected when NETCONSOLE_DYNAMIC is
enabled, PRINTK_EXECUTION_CTX will be automatically deselected without
prompting. Additionally, CONSOLE_HAS_EXECUTION_CTX is a hidden symbol that
cannot be manually forced.

That said, I'm open to making PRINTK_EXECUTION_CTX invisible as well,
given it is behaving like one already.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help