From 9a1f977e39d8e9fcb6a9cb2a612f4743e802221d Mon Sep 17 00:00:00 2001
From: Anton Kling <anton@kling.gg>
Date: Fri, 10 Nov 2023 15:47:08 +0100
Subject: Kernel Style: Change uint*_t -> u*

---
 kernel/crypto/ChaCha20/chacha20.c |  4 ++--
 kernel/crypto/ChaCha20/chacha20.h | 12 ++++++------
 2 files changed, 8 insertions(+), 8 deletions(-)

(limited to 'kernel/crypto')

diff --git a/kernel/crypto/ChaCha20/chacha20.c b/kernel/crypto/ChaCha20/chacha20.c
index 5bf7aa2..0f74844 100644
--- a/kernel/crypto/ChaCha20/chacha20.c
+++ b/kernel/crypto/ChaCha20/chacha20.c
@@ -6,10 +6,10 @@
 	 a += b, d ^= a, d = ROTL(d, 8), c += d, b ^= c, b = ROTL(b, 7))
 #define ROUNDS 20
 
-void chacha_block(uint32_t out[16], uint32_t const in[16])
+void chacha_block(u32 out[16], u32 const in[16])
 {
 	int i;
-	uint32_t x[16];
+	u32 x[16];
 
 	for (i = 0; i < 16; ++i)
 		x[i] = in[i];
diff --git a/kernel/crypto/ChaCha20/chacha20.h b/kernel/crypto/ChaCha20/chacha20.h
index 17532f3..3278783 100644
--- a/kernel/crypto/ChaCha20/chacha20.h
+++ b/kernel/crypto/ChaCha20/chacha20.h
@@ -1,15 +1,15 @@
 #ifndef CHACHA20_H
 #define CHACHA20_H
-#include <stdint.h>
+#include <typedefs.h>
 
 #define KEY 4
-#define KEY_SIZE 8*sizeof(uint32_t)
+#define KEY_SIZE 8*sizeof(u32)
 #define COUNT 12
-#define COUNT_SIZE sizeof(uint32_t)
+#define COUNT_SIZE sizeof(u32)
 #define COUNT_MAX (0x100000000-1) // 2^32 - 1
 #define NONCE 13
-#define NONCE_SIZE 2*sizeof(uint32_t)
-#define BLOCK_SIZE 16*sizeof(uint32_t)
+#define NONCE_SIZE 2*sizeof(u32)
+#define BLOCK_SIZE 16*sizeof(u32)
 
-void chacha_block(uint32_t out[16], uint32_t const in[16]);
+void chacha_block(u32 out[16], u32 const in[16]);
 #endif
-- 
cgit v1.2.3