hc
2024-02-20 102a0743326a03cd1a1202ceda21e175b7d3575c
kernel/crypto/ansi_cprng.c
....@@ -1,18 +1,13 @@
1
+// SPDX-License-Identifier: GPL-2.0-or-later
12 /*
23 * PRNG: Pseudo Random Number Generator
34 * Based on NIST Recommended PRNG From ANSI X9.31 Appendix A.2.4 using
45 * AES 128 cipher
56 *
67 * (C) Neil Horman <nhorman@tuxdriver.com>
7
- *
8
- * This program is free software; you can redistribute it and/or modify it
9
- * under the terms of the GNU General Public License as published by the
10
- * Free Software Foundation; either version 2 of the License, or (at your
11
- * any later version.
12
- *
13
- *
148 */
159
10
+#include <crypto/internal/cipher.h>
1611 #include <crypto/internal/rng.h>
1712 #include <linux/err.h>
1813 #include <linux/init.h>
....@@ -472,7 +467,8 @@
472467 MODULE_AUTHOR("Neil Horman <nhorman@tuxdriver.com>");
473468 module_param(dbg, int, 0);
474469 MODULE_PARM_DESC(dbg, "Boolean to enable debugging (0/1 == off/on)");
475
-module_init(prng_mod_init);
470
+subsys_initcall(prng_mod_init);
476471 module_exit(prng_mod_fini);
477472 MODULE_ALIAS_CRYPTO("stdrng");
478473 MODULE_ALIAS_CRYPTO("ansi_cprng");
474
+MODULE_IMPORT_NS(CRYPTO_INTERNAL);