mirror of
https://github.com/LongSoft/UEFITool.git
synced 2025-05-22 03:05:23 -04:00
Revert old patch from common/LZMA/SDK/C/CpuArch.c
This commit is contained in:
parent
65fb4a86b6
commit
b5756f9ccb
1 changed files with 1 additions and 7 deletions
|
@ -907,14 +907,8 @@ static unsigned long MY_getauxval(int aux)
|
|||
#endif
|
||||
// MY_HWCAP_CHECK_FUNC (ASIMD)
|
||||
#elif defined(MY_CPU_ARM)
|
||||
// UEFITool: make sure this code works on various BSD variants
|
||||
#ifdef __linux__
|
||||
#define MY_HWCAP_CHECK_FUNC(name) \
|
||||
BoolInt CPU_IsSupported_ ## name() { return (getauxval(AT_HWCAP2) & (HWCAP2_ ## name)) ? 1 : 0; }
|
||||
#elif defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__DragonFly__)
|
||||
#define MY_HWCAP_CHECK_FUNC(name) \
|
||||
BoolInt CPU_IsSupported_ ## name() { uint32_t hwcaps = 0; elf_aux_info(AT_HWCAP2, &hwcaps, sizeof(hwcaps)); return (hwcaps & (HWCAP2_ ## name)) ? 1 : 0; }
|
||||
#endif
|
||||
BoolInt CPU_IsSupported_ ## name(void) { return (MY_getauxval(AT_HWCAP2) & (HWCAP2_ ## name)); }
|
||||
MY_HWCAP_CHECK_FUNC_2(NEON, NEON)
|
||||
#endif
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue