hwf-x86: fix use of wrong operand type
* src/hwf-x86.c (get_cpuid): Use xchg for swapping %ebx back and forth between operand register.
HW feature routine was giving wrong results with certain compiler &
compiler flag combinations on i386. Issue was that "=g" operand was
used which caused problem if compiler allocated %ebx register for
this operand. CPUID assembly block attempts to save %ebx as in older
GCC versions this register was fixed for GOT pointer use and could
not be modified otherwise (could not be used as operand or clobber).
(cherry picked from commit ec87511d9cd2dc31434e939b6351d74a38d4ceaa)
- Reported-by: Iru Cai <vimacs@disroot.org>
- Signed-off-by: Jussi Kivilinna <jussi.kivilinna@iki.fi>