lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 12 Oct 2022 16:59:29 -0500
From:   Robert Elliott <elliott@....com>
To:     herbert@...dor.apana.org.au, davem@...emloft.net,
        tim.c.chen@...ux.intel.com, ap420073@...il.com, ardb@...nel.org,
        linux-crypto@...r.kernel.org, linux-kernel@...r.kernel.org
Cc:     Robert Elliott <elliott@....com>
Subject: [PATCH v2 17/19] crypto: x86 - standardize suboptimal prints

Reword prints that the module is not being loaded (although
it otherwise qualifies) because performance would be suboptimal
on the particular CPU model.

Although modules are not supposed to print unless they're loaded
and active, this is an existing exception.

Signed-off-by: Robert Elliott <elliott@....com>
---
 arch/x86/crypto/blowfish_glue.c     | 5 +----
 arch/x86/crypto/camellia_glue.c     | 5 +----
 arch/x86/crypto/des3_ede_glue.c     | 2 +-
 arch/x86/crypto/twofish_glue_3way.c | 5 +----
 4 files changed, 4 insertions(+), 13 deletions(-)

diff --git a/arch/x86/crypto/blowfish_glue.c b/arch/x86/crypto/blowfish_glue.c
index 27b7aed9a488..8d4ecf406dee 100644
--- a/arch/x86/crypto/blowfish_glue.c
+++ b/arch/x86/crypto/blowfish_glue.c
@@ -320,10 +320,7 @@ static int __init blowfish_init(void)
 		return -ENODEV;
 
 	if (!force && is_blacklisted_cpu()) {
-		printk(KERN_INFO
-			"blowfish-x86_64: performance on this CPU "
-			"would be suboptimal: disabling "
-			"blowfish-x86_64.\n");
+		pr_info("CPU-optimized crypto module not loaded, crypto optimization performance on this CPU would be suboptimal\n");
 		return -ENODEV;
 	}
 
diff --git a/arch/x86/crypto/camellia_glue.c b/arch/x86/crypto/camellia_glue.c
index 94dd2973bb47..002a1e84b277 100644
--- a/arch/x86/crypto/camellia_glue.c
+++ b/arch/x86/crypto/camellia_glue.c
@@ -1394,10 +1394,7 @@ static int __init camellia_init(void)
 		return -ENODEV;
 
 	if (!force && is_blacklisted_cpu()) {
-		printk(KERN_INFO
-			"camellia-x86_64: performance on this CPU "
-			"would be suboptimal: disabling "
-			"camellia-x86_64.\n");
+		pr_info("CPU-optimized crypto module not loaded, crypto optimization performance on this CPU would be suboptimal\n");
 		return -ENODEV;
 	}
 
diff --git a/arch/x86/crypto/des3_ede_glue.c b/arch/x86/crypto/des3_ede_glue.c
index 7b4dd02007ed..b38ad3ec38e2 100644
--- a/arch/x86/crypto/des3_ede_glue.c
+++ b/arch/x86/crypto/des3_ede_glue.c
@@ -371,7 +371,7 @@ static int __init des3_ede_x86_init(void)
 		return -ENODEV;
 
 	if (!force && is_blacklisted_cpu()) {
-		pr_info("des3_ede-x86_64: performance on this CPU would be suboptimal: disabling des3_ede-x86_64.\n");
+		pr_info("CPU-optimized crypto module not loaded, crypto optimization performance on this CPU would be suboptimal\n");
 		return -ENODEV;
 	}
 
diff --git a/arch/x86/crypto/twofish_glue_3way.c b/arch/x86/crypto/twofish_glue_3way.c
index 2fde637b40c8..29c35d2aaeba 100644
--- a/arch/x86/crypto/twofish_glue_3way.c
+++ b/arch/x86/crypto/twofish_glue_3way.c
@@ -157,10 +157,7 @@ static int __init twofish_3way_init(void)
 		return -ENODEV;
 
 	if (!force && is_blacklisted_cpu()) {
-		printk(KERN_INFO
-			"twofish-x86_64-3way: performance on this CPU "
-			"would be suboptimal: disabling "
-			"twofish-x86_64-3way.\n");
+		pr_info("CPU-optimized crypto module not loaded, crypto optimization performance on this CPU would be suboptimal\n");
 		return -ENODEV;
 	}
 
-- 
2.37.3

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ