Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

security/keys: make big_key.c explicitly non-modular

The Kconfig currently controlling compilation of this code is:

config BIG_KEYS
bool "Large payload keys"

...meaning that it currently is not being built as a module by anyone.

Lets remove the modular code that is essentially orphaned, so that
when reading the driver there is no doubt it is builtin-only.

Since module_init translates to device_initcall in the non-modular
case, the init ordering remains unchanged with this commit.

We also delete the MODULE_LICENSE tag since all that information
is already contained at the top of the file in the comments.

Cc: James Morris <james.l.morris@oracle.com>
Cc: "Serge E. Hallyn" <serge@hallyn.com>
Cc: keyrings@vger.kernel.org
Cc: linux-security-module@vger.kernel.org
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Signed-off-by: David Howells <dhowells@redhat.com>

authored by

Paul Gortmaker and committed by
David Howells
a1f2bdf3 d846e78e

+1 -14
+1 -14
security/keys/big_key.c
··· 9 9 * 2 of the Licence, or (at your option) any later version. 10 10 */ 11 11 12 - #include <linux/module.h> 13 12 #include <linux/init.h> 14 13 #include <linux/seq_file.h> 15 14 #include <linux/file.h> ··· 16 17 #include <linux/err.h> 17 18 #include <keys/user-type.h> 18 19 #include <keys/big_key-type.h> 19 - 20 - MODULE_LICENSE("GPL"); 21 20 22 21 /* 23 22 * Layout of key payload words. ··· 209 212 return ret; 210 213 } 211 214 212 - /* 213 - * Module stuff 214 - */ 215 215 static int __init big_key_init(void) 216 216 { 217 217 return register_key_type(&key_type_big_key); 218 218 } 219 - 220 - static void __exit big_key_cleanup(void) 221 - { 222 - unregister_key_type(&key_type_big_key); 223 - } 224 - 225 - module_init(big_key_init); 226 - module_exit(big_key_cleanup); 219 + device_initcall(big_key_init);