crypto: talitos - be less noisy on startup
authorKim Phillips <kim.phillips@freescale.com>
Mon, 21 Nov 2011 08:13:26 +0000 (16:13 +0800)
committerHerbert Xu <herbert@gondor.apana.org.au>
Mon, 21 Nov 2011 08:21:50 +0000 (16:21 +0800)
talitos prints every algorithm it registers at module load time.
Algorithms are being added that make for an excessively noisy console
(latest HMACs patch makes an SEC 3.1 print 20 lines).
Instead, display the SEC h/w version number, and inform the
user of algorithm registration status in /proc/crypto, like so:

talitos ffe30000.crypto: fsl,sec3.1 algorithms registered in /proc/crypto

Signed-off-by: Kim Phillips <kim.phillips@freescale.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/talitos.c

index 8ce87317310bd05e4a9ec14b6bf583cf42e97f5a..c372a18ed22eff10b7d5023c27bf207a15abe29c 100644 (file)
@@ -2784,12 +2784,13 @@ static int talitos_probe(struct platform_device *ofdev)
                                dev_err(dev, "%s alg registration failed\n",
                                        name);
                                kfree(t_alg);
-                       } else {
+                       } else
                                list_add_tail(&t_alg->entry, &priv->alg_list);
-                               dev_info(dev, "%s\n", name);
-                       }
                }
        }
+       if (!list_empty(&priv->alg_list))
+               dev_info(dev, "%s algorithms registered in /proc/crypto\n",
+                        (char *)of_get_property(np, "compatible", NULL));
 
        return 0;