git: 759aae422e0b - stable/12 - crypto/chacha: Split header into separate _chacha.h

From: David E. O'Brien <obrien_at_FreeBSD.org>
Date: Sat, 12 Feb 2022 22:58:30 UTC
The branch stable/12 has been updated by obrien:

URL: https://cgit.FreeBSD.org/src/commit/?id=759aae422e0b47967c6dd00d540ab4a2bb2c3b0d

commit 759aae422e0b47967c6dd00d540ab4a2bb2c3b0d
Author:     Conrad Meyer <cem@FreeBSD.org>
AuthorDate: 2018-10-20 22:12:53 +0000
Commit:     David E. O'Brien <obrien@FreeBSD.org>
CommitDate: 2022-02-12 21:53:34 +0000

    crypto/chacha: Split header into separate _chacha.h
    
    (cherry picked from commit addfc6364f29525ae66d25bfe5f957b366ff63e8)
---
 sys/crypto/chacha20/_chacha.h | 12 ++++++++++++
 sys/crypto/chacha20/chacha.h  |  5 +----
 2 files changed, 13 insertions(+), 4 deletions(-)

diff --git a/sys/crypto/chacha20/_chacha.h b/sys/crypto/chacha20/_chacha.h
new file mode 100644
index 000000000000..a7217b628d0e
--- /dev/null
+++ b/sys/crypto/chacha20/_chacha.h
@@ -0,0 +1,12 @@
+/* $FreeBSD$ */
+
+#ifndef _CHACHA_H
+#define _CHACHA_H
+
+#include <sys/types.h>
+
+struct chacha_ctx {
+	u_int input[16];
+};
+
+#endif
diff --git a/sys/crypto/chacha20/chacha.h b/sys/crypto/chacha20/chacha.h
index e67cc81264cd..d150093c6f93 100644
--- a/sys/crypto/chacha20/chacha.h
+++ b/sys/crypto/chacha20/chacha.h
@@ -12,10 +12,7 @@ Public domain.
 #define CHACHA_H
 
 #include <sys/types.h>
-
-struct chacha_ctx {
-	u_int input[16];
-};
+#include <crypto/chacha20/_chacha.h>
 
 #define CHACHA_MINKEYLEN 	16
 #define CHACHA_NONCELEN		8