File tree Expand file tree Collapse file tree 2 files changed +15
-5
lines changed
Expand file tree Collapse file tree 2 files changed +15
-5
lines changed Original file line number Diff line number Diff line change @@ -147,9 +147,15 @@ ifeq "$(ENABLED_LINUXKM_PIE)" "yes"
147147 $(WOLFCRYPT_PIE_FILES ) : ccflags-y += $(PIE_FLAGS )
148148 $(WOLFCRYPT_PIE_FILES ) : ccflags-remove-y += -pg \
149149 $(call cc-option,-ftrivial-auto-var-init=zero)
150- ifdef FORCE_GLOBAL_OBJTOOL_OFF
151- undefine CONFIG_OBJTOOL
152- endif
150+ endif
151+
152+ # On some kernels/configs, objtool runs and warns on the linked libwolfssl.o,
153+ # ignoring the below "OBJECT_FILES_NON_STANDARD := y" annotations. This
154+ # mechanism, activated with "make KBUILD_EXTRA_FLAGS=FORCE_GLOBAL_OBJTOOL_OFF=1",
155+ # inhibits objtool completely. This may be necessary on modules compiled with
156+ # assembly accelerations and/or ENABLED_LINUXKM_PIE.
157+ ifdef FORCE_GLOBAL_OBJTOOL_OFF
158+ undefine CONFIG_OBJTOOL
153159endif
154160
155161ifdef KERNEL_EXTRA_CFLAGS_REMOVE
Original file line number Diff line number Diff line change 569569 * the footer "-----END ML_DSA_LEVEL5 PRIVATE KEY-----" */
570570#define DILITHIUM_MAX_BOTH_KEY_PEM_SIZE DILITHIUM_LEVEL3_BOTH_KEY_PEM_SIZE
571571
572- #else
572+ #elif !defined( WOLFSSL_NO_ML_DSA_44 )
573573
574574#define DILITHIUM_MAX_KEY_SIZE DILITHIUM_LEVEL2_KEY_SIZE
575575#define DILITHIUM_MAX_SIG_SIZE DILITHIUM_LEVEL2_SIG_SIZE
583583 * the footer "-----END ML_DSA_LEVEL5 PRIVATE KEY-----" */
584584#define DILITHIUM_MAX_BOTH_KEY_PEM_SIZE DILITHIUM_LEVEL2_BOTH_KEY_PEM_SIZE
585585
586+ #else
587+
588+ #error ML-DSA: All levels disabled.
589+
586590#endif
587591
588592#elif defined(HAVE_LIBOQS )
676680/* PEM size with the header "-----BEGIN ML_DSA_LEVEL5 PRIVATE KEY-----" and
677681 * the footer "-----END ML_DSA_LEVEL5 PRIVATE KEY-----" */
678682#define DILITHIUM_MAX_BOTH_KEY_PEM_SIZE DILITHIUM_LEVEL5_BOTH_KEY_PEM_SIZE
679- #endif
680683
684+ #endif /* HAVE_LIBOQS */
681685
682686
683687#ifdef WOLF_PRIVATE_KEY_ID
You can’t perform that action at this time.
0 commit comments