forked from wolfSSL/wolfssl
Merge pull request #3265 from SparkiDev/cpuid_set
Allow the CPU Id flags to be programmatically set
This commit is contained in:
@ -108,4 +108,19 @@
|
|||||||
cpuid_set_flags();
|
cpuid_set_flags();
|
||||||
return cpuid_flags;
|
return cpuid_flags;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void cpuid_select_flags(word32 flags)
|
||||||
|
{
|
||||||
|
cpuid_flags = flags;
|
||||||
|
}
|
||||||
|
|
||||||
|
void cpuid_set_flag(word32 flag)
|
||||||
|
{
|
||||||
|
cpuid_flags |= flag;
|
||||||
|
}
|
||||||
|
|
||||||
|
void cpuid_clear_flag(word32 flag)
|
||||||
|
{
|
||||||
|
cpuid_flags &= ~flag;
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@ -54,6 +54,11 @@
|
|||||||
|
|
||||||
void cpuid_set_flags(void);
|
void cpuid_set_flags(void);
|
||||||
word32 cpuid_get_flags(void);
|
word32 cpuid_get_flags(void);
|
||||||
|
|
||||||
|
/* Public APIs to modify flags. */
|
||||||
|
WOLFSSL_API void cpuid_select_flags(word32 flags);
|
||||||
|
WOLFSSL_API void cpuid_set_flag(word32 flag);
|
||||||
|
WOLFSSL_API void cpuid_clear_flag(word32 flag);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
|
Reference in New Issue
Block a user