Re: [PATCH] KEYS: Sort out big_key initialisation

From: Joe Perches
Date: Sat Jul 30 2016 - 16:12:48 EST


On Sat, 2016-07-30 at 22:03 +0200, Kirill Marinushkin wrote:
> big_key has two separate initialisation functions, one that registers the
> key type and one that registers the crypto.  If the key type fails to
> register, there's no problem if the crypto registers successfully because
> there's no way to reach the crypto except through the key type.

trivia:

> diff --git a/security/keys/big_key.c b/security/keys/big_key.c
[]
> @@ -9,6 +9,7 @@
>   * 2 of the Licence, or (at your option) any later version.
>   */
>  
> +#define pr_fmt(fmt) "big_key: "fmt

It's much more common to use

#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt