From dd260d95fd26deedc64f076b554759d09420f006 Mon Sep 17 00:00:00 2001 From: Rasmus Villemoes Date: Mon, 7 Jul 2025 22:36:55 +0200 Subject: limits.h: provide all limit macros for standard [u]intNN_t types Currently, we only have UINT32_MAX and UINT64_MAX in limits.h, and then stdint.h and kernel.h somewhat randomly define UINT8_MAX and INT32_MAX, respectively. Provide a full set of definitions in terms of the min/max macros for the types that [u]intNN_t are defined in terms of, namely the {s,u}NN ones. Try to avoid breaking whatever depended on getting UINT8_MAX from our compat stdint.h by replacing it with an include of limits.h. Signed-off-by: Rasmus Villemoes --- include/linux/kernel.h | 2 -- 1 file changed, 2 deletions(-) (limited to 'include/linux/kernel.h') diff --git a/include/linux/kernel.h b/include/linux/kernel.h index d3d979834ae..e0443ecac84 100644 --- a/include/linux/kernel.h +++ b/include/linux/kernel.h @@ -5,8 +5,6 @@ #include /* for printf/pr_* utilities */ #include -#define INT32_MAX S32_MAX - #define STACK_MAGIC 0xdeadbeef #define REPEAT_BYTE(x) ((~0ul / 0xff) * (x)) -- cgit v1.2.3