On 2026-01-23 08:54, Borislav Petkov wrote:
>
> Hmmm, so, my gut feeling tells me that we need a proper ia32 emu support
> detection in the running kernel. I can't find one after a short grep, maybe it
> should be in /proc/cpuinfo, maybe it should be a syscall which fails when
> IA32_EMULATION is off or maybe ptrace(2) says somewhere in the depths of its
> countless ops that it does support IA32 emulation.
>
> And then you could put that in that helper and then put that helper in
> a header and not copy it in every test...
>
You can probe for it by trapping SIGSEGV and calling int $0x80. Not exactly
pretty, but...
Making it a sysfs entry would allow dynamically control it, too...
-hpa