From d722276c506a66f4ee97c44a87969fdf577f7ffa Mon Sep 17 00:00:00 2001 From: Daniel Pouzzner Date: Sun, 7 Jan 2024 11:16:43 -0600 Subject: [PATCH] linuxkm/module_hooks.c: add proper gating for my_fpregs_[un]lock(). --- linuxkm/module_hooks.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/linuxkm/module_hooks.c b/linuxkm/module_hooks.c index d270edac7a..8ee34dff61 100644 --- a/linuxkm/module_hooks.c +++ b/linuxkm/module_hooks.c @@ -350,6 +350,8 @@ static int my_preempt_count(void) { return preempt_count(); } +#if defined(WOLFSSL_LINUXKM_SIMD_X86) && defined(WOLFSSL_COMMERCIAL_LICENSE) + /* ditto for fpregs_lock/fpregs_unlock */ #ifdef WOLFSSL_LINUXKM_USE_SAVE_VECTOR_REGISTERS static void my_fpregs_lock(void) { @@ -359,7 +361,10 @@ static void my_fpregs_lock(void) { static void my_fpregs_unlock(void) { fpregs_unlock(); } -#endif + +#endif /* WOLFSSL_LINUXKM_SIMD_X86 && WOLFSSL_COMMERCIAL_LICENSE */ + +#endif /* USE_WOLFSSL_LINUXKM_PIE_REDIRECT_TABLE */ static int set_up_wolfssl_linuxkm_pie_redirect_table(void) { memset(