Commit a9359e8b authored by Breno Leitao's avatar Breno Leitao Committed by Jakub Kicinski

net: netconsole: Remove unnecessary cast from bool

The 'enabled' variable is already a bool, so casting it to its value
is redundant.

Remove the superfluous cast, improving code clarity without changing
functionality.
Signed-off-by: default avatarBreno Leitao <leitao@debian.org>
Link: https://patch.msgid.link/20240709144403.544099-2-leitao@debian.orgSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent 5e724cb6
......@@ -344,7 +344,7 @@ static ssize_t enabled_store(struct config_item *item,
goto out_unlock;
err = -EINVAL;
if ((bool)enabled == nt->enabled) {
if (enabled == nt->enabled) {
pr_info("network logging has already %s\n",
nt->enabled ? "started" : "stopped");
goto out_unlock;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment