Commit 636fd32d authored by Arnd Bergmann's avatar Arnd Bergmann Committed by Paolo Abeni
Browse files

printk: add CONFIG_PRINTK dependency for netconsole



The 'select PRINTK_EXECUTION_CTX' line now causes a harmless warning
when NETCONSOLE_DYNAMIC is enabled but PRINTK is not:

WARNING: unmet direct dependencies detected for PRINTK_EXECUTION_CTX
  Depends on [n]: PRINTK [=n]
  Selected by [y]:
  - NETCONSOLE_DYNAMIC [=y] && NETDEVICES [=y] && NET_CORE [=y] && NETCONSOLE [=y] && SYSFS [=y] && CONFIGFS_FS [=y] && (NETCONSOLE [=y]!=y [=y] || CONFIGFS_FS [=y]!=m [=m])

In that configuration, the netconsole driver is useless anyway, so
avoid this with an added dependency that prevents CONFIG_NETCONSOLE
to be enabled without CONFIG_PRINTK.

Fixes: 60325c27 ("printk: Add execution context (task name/CPU) to printk_info")
Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
Reviewed-by: default avatarSimon Horman <horms@kernel.org>
Link: https://patch.msgid.link/20260213074431.1729627-1-arnd@kernel.org


Signed-off-by: default avatarPaolo Abeni <pabeni@redhat.com>
parent 9874b1ba
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -333,6 +333,7 @@ config MACSEC

config NETCONSOLE
	tristate "Network console logging support"
	depends on PRINTK
	help
	  If you want to log kernel messages over the network, enable this.
	  See <file:Documentation/networking/netconsole.rst> for details.