linux-crypto.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Jason A. Donenfeld" <Jason@zx2c4.com>
To: linux-crypto@vger.kernel.org, ardb@kernel.org,
	herbert@gondor.apana.org.au
Cc: "Jason A. Donenfeld" <Jason@zx2c4.com>,
	John Donnelly <john.p.donnelly@oracle.com>
Subject: [PATCH] crypto: lib/chacha20poly1305 - define empty module exit function
Date: Fri, 15 Jan 2021 18:17:43 +0100	[thread overview]
Message-ID: <20210115171743.1559595-1-Jason@zx2c4.com> (raw)

With no mod_exit function, users are unable to load the module after
use. I'm not aware of any reason why module unloading should be
prohibited for this one, so this commit simply adds an empty exit
function.

Reported-by: John Donnelly <john.p.donnelly@oracle.com>
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
---
 lib/crypto/chacha20poly1305.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/lib/crypto/chacha20poly1305.c b/lib/crypto/chacha20poly1305.c
index 5850f3b87359..c2fcdb98cc02 100644
--- a/lib/crypto/chacha20poly1305.c
+++ b/lib/crypto/chacha20poly1305.c
@@ -362,7 +362,12 @@ static int __init mod_init(void)
 	return 0;
 }
 
+static void __exit mod_exit(void)
+{
+}
+
 module_init(mod_init);
+module_exit(mod_exit);
 MODULE_LICENSE("GPL v2");
 MODULE_DESCRIPTION("ChaCha20Poly1305 AEAD construction");
 MODULE_AUTHOR("Jason A. Donenfeld <Jason@zx2c4.com>");
-- 
2.30.0


             reply	other threads:[~2021-01-15 17:25 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-15 17:17 Jason A. Donenfeld [this message]
2021-01-15 17:25 ` [PATCH] crypto: lib/chacha20poly1305 - define empty module exit function Ard Biesheuvel
2021-01-15 17:44 ` Eric Biggers
2021-01-15 18:06 ` John Donnelly
2021-01-15 19:30 ` [PATCH v2] " Jason A. Donenfeld
2021-01-16  0:28   ` John Donnelly
2021-01-16  0:31     ` Jason A. Donenfeld
2021-01-22  6:21   ` Herbert Xu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210115171743.1559595-1-Jason@zx2c4.com \
    --to=jason@zx2c4.com \
    --cc=ardb@kernel.org \
    --cc=herbert@gondor.apana.org.au \
    --cc=john.p.donnelly@oracle.com \
    --cc=linux-crypto@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).