2019-03-19 13:52:27

by Yue Haibing

[permalink] [raw]
Subject: [PATCH -next] crypto: ccp - Make ccp_register_rsa_alg static

From: YueHaibing <[email protected]>

Fix sparse warning:

drivers/crypto/ccp/ccp-crypto-rsa.c:251:5:
warning: symbol 'ccp_register_rsa_alg' was not declared. Should it be static?

Signed-off-by: YueHaibing <[email protected]>
---
drivers/crypto/ccp/ccp-crypto-rsa.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/crypto/ccp/ccp-crypto-rsa.c b/drivers/crypto/ccp/ccp-crypto-rsa.c
index 05850df..0b8aab00 100644
--- a/drivers/crypto/ccp/ccp-crypto-rsa.c
+++ b/drivers/crypto/ccp/ccp-crypto-rsa.c
@@ -248,7 +248,8 @@ static struct ccp_rsa_def rsa_algs[] = {
}
};

-int ccp_register_rsa_alg(struct list_head *head, const struct ccp_rsa_def *def)
+static int ccp_register_rsa_alg(struct list_head *head,
+ const struct ccp_rsa_def *def)
{
struct ccp_crypto_akcipher_alg *ccp_alg;
struct akcipher_alg *alg;
--
2.7.4




2019-03-19 18:40:35

by Gary R Hook

[permalink] [raw]
Subject: Re: [PATCH -next] crypto: ccp - Make ccp_register_rsa_alg static

On 3/19/19 8:50 AM, Yue Haibing wrote:
> From: YueHaibing <[email protected]>
>
> Fix sparse warning:
>
> drivers/crypto/ccp/ccp-crypto-rsa.c:251:5:
> warning: symbol 'ccp_register_rsa_alg' was not declared. Should it be static?
>
> Signed-off-by: YueHaibing <[email protected]>

Acked-by: Gary R Hook <[email protected].

> ---
> drivers/crypto/ccp/ccp-crypto-rsa.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/crypto/ccp/ccp-crypto-rsa.c b/drivers/crypto/ccp/ccp-crypto-rsa.c
> index 05850df..0b8aab00 100644
> --- a/drivers/crypto/ccp/ccp-crypto-rsa.c
> +++ b/drivers/crypto/ccp/ccp-crypto-rsa.c
> @@ -248,7 +248,8 @@ static struct ccp_rsa_def rsa_algs[] = {
> }
> };
>
> -int ccp_register_rsa_alg(struct list_head *head, const struct ccp_rsa_def *def)
> +static int ccp_register_rsa_alg(struct list_head *head,
> + const struct ccp_rsa_def *def)
> {
> struct ccp_crypto_akcipher_alg *ccp_alg;
> struct akcipher_alg *alg;
>

2019-03-28 06:08:06

by Herbert Xu

[permalink] [raw]
Subject: Re: [PATCH -next] crypto: ccp - Make ccp_register_rsa_alg static

On Tue, Mar 19, 2019 at 09:50:35PM +0800, Yue Haibing wrote:
> From: YueHaibing <[email protected]>
>
> Fix sparse warning:
>
> drivers/crypto/ccp/ccp-crypto-rsa.c:251:5:
> warning: symbol 'ccp_register_rsa_alg' was not declared. Should it be static?
>
> Signed-off-by: YueHaibing <[email protected]>
> ---
> drivers/crypto/ccp/ccp-crypto-rsa.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)

Patch applied. Thanks.
--
Email: Herbert Xu <[email protected]>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt