]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
netconsole: fix sysdata_release_enabled_show checking wrong flag
authorBreno Leitao <leitao@debian.org>
Mon, 2 Mar 2026 11:40:46 +0000 (03:40 -0800)
committerJakub Kicinski <kuba@kernel.org>
Wed, 4 Mar 2026 01:23:50 +0000 (17:23 -0800)
sysdata_release_enabled_show() checks SYSDATA_TASKNAME instead of
SYSDATA_RELEASE, causing the configfs release_enabled attribute to
reflect the taskname feature state rather than the release feature
state. This is a copy-paste error from the adjacent
sysdata_taskname_enabled_show() function.

The corresponding _store function already uses the correct
SYSDATA_RELEASE flag.

Fixes: 343f90227070 ("netconsole: implement configfs for release_enabled")
Signed-off-by: Breno Leitao <leitao@debian.org>
Cc: stable@vger.kernel.org
Link: https://patch.msgid.link/20260302-sysdata_release_fix-v1-1-e5090f677c7c@debian.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/netconsole.c

index 2db116fb1a7cdf17cde7afddc614f92b098ec0c2..3c9acd6e49e8665aaafa782fb4b7856a913c3dd4 100644 (file)
@@ -617,7 +617,7 @@ static ssize_t sysdata_release_enabled_show(struct config_item *item,
        bool release_enabled;
 
        dynamic_netconsole_mutex_lock();
-       release_enabled = !!(nt->sysdata_fields & SYSDATA_TASKNAME);
+       release_enabled = !!(nt->sysdata_fields & SYSDATA_RELEASE);
        dynamic_netconsole_mutex_unlock();
 
        return sysfs_emit(buf, "%d\n", release_enabled);