Received: by 2002:a05:6358:489b:b0:bb:da1:e618 with SMTP id x27csp271504rwn; Wed, 14 Sep 2022 20:41:30 -0700 (PDT) X-Google-Smtp-Source: AA6agR4GuxiNJlqsT+2z3qaoHR6P317vipMVAOnY6KqtD3M+tCEU8D5y7AyKUQJYXxic+eJvSUXh X-Received: by 2002:a17:907:60d3:b0:77e:5e9b:8ec with SMTP id hv19-20020a17090760d300b0077e5e9b08ecmr11553731ejc.640.1663213289868; Wed, 14 Sep 2022 20:41:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1663213289; cv=none; d=google.com; s=arc-20160816; b=ozSNDUDBNJKHc93WUMz8uJW23PXfL4Bt6tVkY9UhJARn8H0zJyDT0oGVT0XTybjZFK vaFgpQSj/GObe/0P8Q11BpJJGAP04oa/5sJ/bRDwLyG/24DndJ04Pne+2McXcpdgYNmd UV96fPoP7BfXS0yBttnClLSg0syKGgcsVOoOSgdn7t+jANc3IUNHfFNc67GLWsCoHzJM PpI+yDF5UhlYoZw90LMM/wA8qfQhZO5OmMvCdvCTA1BPfsPz1r2RQLP3FxdU+XCncsKo ZVX4YWeMOj3dcifud8Xht7Ynv12ICQHIStPCoe+jdIrf3bhulUoN6N7m/wuH1uhSH/w4 lA4w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:subject:cc:to:from; bh=hNNZK3vfrFYV1XmgAhS6Ib0NrYmYMw9aO7dpMIwI9Ew=; b=xLrhViIFzOxRzIJbt2Du2DwoD3QoYDWN5XFWgrwSz9fWjiinvWXEnHAfrPR+8Q4mQl VapW8ffLlyFI3KrOW2+5OihpaahFIwhukjVCOMydle1ax3BPHYYGZBaHomvnKuR61x1a lX180k7BkhUDxCKd4DcqU9OkyL45yXj3jW1G0+grNOtENVNe4PRGMhqcXTDzHw4JtXP8 EBG3fdBS7ngnU5Co/UiFk+VnC7j1oBtuE5FTkeSvJWvmCAAHlfQDaNfGCa4tiFkB5/CJ Aqhc4wjLEciXSVc2AZfCztpGp4kXS2dQPde2sTCUwv1lE5NuQtFHPTxtSgmL3ymdaM6M jZcw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id r23-20020aa7da17000000b0044e8b287219si10243001eds.179.2022.09.14.20.41.05; Wed, 14 Sep 2022 20:41:29 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229832AbiIODku (ORCPT + 99 others); Wed, 14 Sep 2022 23:40:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54260 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230363AbiIODk1 (ORCPT ); Wed, 14 Sep 2022 23:40:27 -0400 Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E9719630D; Wed, 14 Sep 2022 20:39:50 -0700 (PDT) Received: from dggpeml500023.china.huawei.com (unknown [172.30.72.54]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4MSjWg58ntzNmGp; Thu, 15 Sep 2022 11:35:11 +0800 (CST) Received: from ubuntu1804.huawei.com (10.67.174.58) by dggpeml500023.china.huawei.com (7.185.36.114) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31; Thu, 15 Sep 2022 11:39:48 +0800 From: Xiu Jianfeng To: , , , , CC: , Subject: [PATCH] crypto: add __init/__exit annotations to init/exit funcs Date: Thu, 15 Sep 2022 11:36:15 +0800 Message-ID: <20220915033615.12478-1-xiujianfeng@huawei.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.67.174.58] X-ClientProxiedBy: dggems703-chm.china.huawei.com (10.3.19.180) To dggpeml500023.china.huawei.com (7.185.36.114) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org Add missing __init/__exit annotations to init/exit funcs. Signed-off-by: Xiu Jianfeng --- crypto/async_tx/raid6test.c | 4 ++-- crypto/curve25519-generic.c | 4 ++-- crypto/dh.c | 4 ++-- crypto/ecdh.c | 4 ++-- crypto/ecdsa.c | 4 ++-- crypto/rsa.c | 4 ++-- crypto/sm2.c | 4 ++-- 7 files changed, 14 insertions(+), 14 deletions(-) diff --git a/crypto/async_tx/raid6test.c b/crypto/async_tx/raid6test.c index c9d218e53bcb..9719c7520661 100644 --- a/crypto/async_tx/raid6test.c +++ b/crypto/async_tx/raid6test.c @@ -189,7 +189,7 @@ static int test(int disks, int *tests) } -static int raid6_test(void) +static int __init raid6_test(void) { int err = 0; int tests = 0; @@ -236,7 +236,7 @@ static int raid6_test(void) return 0; } -static void raid6_test_exit(void) +static void __exit raid6_test_exit(void) { } diff --git a/crypto/curve25519-generic.c b/crypto/curve25519-generic.c index bd88fd571393..d055b0784c77 100644 --- a/crypto/curve25519-generic.c +++ b/crypto/curve25519-generic.c @@ -72,12 +72,12 @@ static struct kpp_alg curve25519_alg = { .max_size = curve25519_max_size, }; -static int curve25519_init(void) +static int __init curve25519_init(void) { return crypto_register_kpp(&curve25519_alg); } -static void curve25519_exit(void) +static void __exit curve25519_exit(void) { crypto_unregister_kpp(&curve25519_alg); } diff --git a/crypto/dh.c b/crypto/dh.c index 4406aeb1ff61..99c3b2ef7adc 100644 --- a/crypto/dh.c +++ b/crypto/dh.c @@ -893,7 +893,7 @@ static struct crypto_template crypto_ffdhe_templates[] = {}; #endif /* CONFIG_CRYPTO_DH_RFC7919_GROUPS */ -static int dh_init(void) +static int __init dh_init(void) { int err; @@ -911,7 +911,7 @@ static int dh_init(void) return 0; } -static void dh_exit(void) +static void __exit dh_exit(void) { crypto_unregister_templates(crypto_ffdhe_templates, ARRAY_SIZE(crypto_ffdhe_templates)); diff --git a/crypto/ecdh.c b/crypto/ecdh.c index e4857d534344..80afee3234fb 100644 --- a/crypto/ecdh.c +++ b/crypto/ecdh.c @@ -200,7 +200,7 @@ static struct kpp_alg ecdh_nist_p384 = { static bool ecdh_nist_p192_registered; -static int ecdh_init(void) +static int __init ecdh_init(void) { int ret; @@ -227,7 +227,7 @@ static int ecdh_init(void) return ret; } -static void ecdh_exit(void) +static void __exit ecdh_exit(void) { if (ecdh_nist_p192_registered) crypto_unregister_kpp(&ecdh_nist_p192); diff --git a/crypto/ecdsa.c b/crypto/ecdsa.c index b3a8a6b572ba..fbd76498aba8 100644 --- a/crypto/ecdsa.c +++ b/crypto/ecdsa.c @@ -332,7 +332,7 @@ static struct akcipher_alg ecdsa_nist_p192 = { }; static bool ecdsa_nist_p192_registered; -static int ecdsa_init(void) +static int __init ecdsa_init(void) { int ret; @@ -359,7 +359,7 @@ static int ecdsa_init(void) return ret; } -static void ecdsa_exit(void) +static void __exit ecdsa_exit(void) { if (ecdsa_nist_p192_registered) crypto_unregister_akcipher(&ecdsa_nist_p192); diff --git a/crypto/rsa.c b/crypto/rsa.c index 0e555ee4addb..c50f2d2a4d06 100644 --- a/crypto/rsa.c +++ b/crypto/rsa.c @@ -327,7 +327,7 @@ static struct akcipher_alg rsa = { }, }; -static int rsa_init(void) +static int __init rsa_init(void) { int err; @@ -344,7 +344,7 @@ static int rsa_init(void) return 0; } -static void rsa_exit(void) +static void __exit rsa_exit(void) { crypto_unregister_template(&rsa_pkcs1pad_tmpl); crypto_unregister_akcipher(&rsa); diff --git a/crypto/sm2.c b/crypto/sm2.c index f3e1592965c0..ed9307dac3d1 100644 --- a/crypto/sm2.c +++ b/crypto/sm2.c @@ -441,12 +441,12 @@ static struct akcipher_alg sm2 = { }, }; -static int sm2_init(void) +static int __init sm2_init(void) { return crypto_register_akcipher(&sm2); } -static void sm2_exit(void) +static void __exit sm2_exit(void) { crypto_unregister_akcipher(&sm2); } -- 2.17.1