Add Kernel 6.2 support

This commit is contained in:
ivanovborislav 2023-01-22 10:11:39 +02:00 committed by GitHub
parent 51df588b77
commit e3344be85a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 1 deletions

View File

@ -2910,7 +2910,9 @@ u64 rtw_division64(u64 x, u64 y)
inline u32 rtw_random32(void) inline u32 rtw_random32(void)
{ {
#ifdef PLATFORM_LINUX #ifdef PLATFORM_LINUX
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3, 8, 0)) #if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0))
return get_random_u32();
#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(3, 8, 0))
return prandom_u32(); return prandom_u32();
#elif (LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 18)) #elif (LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 18))
u32 random_int; u32 random_int;