OSDN Git Service

crypto: user - forward declare crypto_nlsk
authorEric Biggers <ebiggers@google.com>
Thu, 10 Jan 2019 20:17:56 +0000 (12:17 -0800)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 18 Jan 2019 10:43:43 +0000 (18:43 +0800)
Move the declaration of crypto_nlsk into internal/cryptouser.h.  This
fixes the following sparse warning:

    crypto/crypto_user_base.c:41:13: warning: symbol 'crypto_nlsk' was not declared. Should it be static?

Cc: Corentin Labbe <clabbe@baylibre.com>
Signed-off-by: Eric Biggers <ebiggers@google.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
crypto/crypto_user_stat.c
include/crypto/internal/cryptouser.h

index 3e9a532..d4d1cb2 100644 (file)
@@ -22,8 +22,6 @@
 
 static DEFINE_MUTEX(crypto_cfg_mutex);
 
-extern struct sock *crypto_nlsk;
-
 struct crypto_dump_info {
        struct sk_buff *in_skb;
        struct sk_buff *out_skb;
index 40623f4..8c602b1 100644 (file)
@@ -1,6 +1,8 @@
 /* SPDX-License-Identifier: GPL-2.0 */
 #include <net/netlink.h>
 
+extern struct sock *crypto_nlsk;
+
 struct crypto_alg *crypto_alg_match(struct crypto_user_alg *p, int exact);
 
 #ifdef CONFIG_CRYPTO_STATS