modules/core: fix x86 PIC code compilation

This change fixes HW detection code on x86 when building PIC code.
In this case, "=b" cannot be used for output registers because ebx is used to store the GOT.

This bug is only on the 2.4 branch, and does not affect the master branch.