mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2025-08-01 03:34:39 +02:00
linuxkm/: accomodate refactoring in kernel 6.2+ of cpu_number
to be an element of the pcpu_hot
`structure.
This commit is contained in:
@@ -322,7 +322,11 @@
|
||||
*/
|
||||
#endif
|
||||
#endif
|
||||
typeof(cpu_number) *cpu_number;
|
||||
#if LINUX_VERSION_CODE < KERNEL_VERSION(6, 2, 0)
|
||||
typeof(cpu_number) *cpu_number;
|
||||
#else
|
||||
typeof(pcpu_hot) *pcpu_hot;
|
||||
#endif
|
||||
typeof(nr_cpu_ids) *nr_cpu_ids;
|
||||
|
||||
#endif /* WOLFSSL_LINUXKM_SIMD_X86 */
|
||||
@@ -459,7 +463,11 @@
|
||||
*/
|
||||
#endif
|
||||
#endif
|
||||
#define cpu_number (*(wolfssl_linuxkm_get_pie_redirect_table()->cpu_number))
|
||||
#if LINUX_VERSION_CODE < KERNEL_VERSION(6, 2, 0)
|
||||
#define cpu_number (*(wolfssl_linuxkm_get_pie_redirect_table()->cpu_number))
|
||||
#else
|
||||
#define pcpu_hot (*(wolfssl_linuxkm_get_pie_redirect_table()->pcpu_hot))
|
||||
#endif
|
||||
#define nr_cpu_ids (*(wolfssl_linuxkm_get_pie_redirect_table()->nr_cpu_ids))
|
||||
#endif
|
||||
|
||||
|
@@ -445,7 +445,11 @@ static int set_up_wolfssl_linuxkm_pie_redirect_table(void) {
|
||||
*/
|
||||
#endif
|
||||
#endif
|
||||
wolfssl_linuxkm_pie_redirect_table.cpu_number = &cpu_number;
|
||||
#if LINUX_VERSION_CODE < KERNEL_VERSION(6, 2, 0)
|
||||
wolfssl_linuxkm_pie_redirect_table.cpu_number = &cpu_number;
|
||||
#else
|
||||
wolfssl_linuxkm_pie_redirect_table.pcpu_hot = &pcpu_hot;
|
||||
#endif
|
||||
wolfssl_linuxkm_pie_redirect_table.nr_cpu_ids = &nr_cpu_ids;
|
||||
#endif
|
||||
|
||||
|
Reference in New Issue
Block a user