aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorThorsten Blum <thorsten.blum@linux.dev>2024-12-23 08:54:11 +0100
committerHerbert Xu <herbert@gondor.apana.org.au>2025-01-04 08:52:03 +0800
commit8f904adef62d9bd91dc8952eaf3004b5998cf4da (patch)
tree7ca40f31406633dd928ed2a8db3515cdd91373da
parentcrypto: iaa - Fix IAA disabling that occurs when sync_mode is set to 'async' (diff)
downloadwireguard-linux-8f904adef62d9bd91dc8952eaf3004b5998cf4da.tar.xz
wireguard-linux-8f904adef62d9bd91dc8952eaf3004b5998cf4da.zip
crypto: fips - Use str_enabled_disabled() helper in fips_enable()
Remove hard-coded strings by using the str_enabled_disabled() helper function. Use pr_info() instead of printk(KERN_INFO) to silence a checkpatch warning. Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
-rw-r--r--crypto/fips.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/crypto/fips.c b/crypto/fips.c
index 8a784018ebfc..a58e7750f532 100644
--- a/crypto/fips.c
+++ b/crypto/fips.c
@@ -12,6 +12,7 @@
#include <linux/kernel.h>
#include <linux/sysctl.h>
#include <linux/notifier.h>
+#include <linux/string_choices.h>
#include <generated/utsrelease.h>
int fips_enabled;
@@ -24,8 +25,7 @@ EXPORT_SYMBOL_GPL(fips_fail_notif_chain);
static int fips_enable(char *str)
{
fips_enabled = !!simple_strtol(str, NULL, 0);
- printk(KERN_INFO "fips mode: %s\n",
- fips_enabled ? "enabled" : "disabled");
+ pr_info("fips mode: %s\n", str_enabled_disabled(fips_enabled));
return 1;
}