We assign values to the output registers before the input operand is
used, so we have to use =&r to make sure the input operand isn't
clobbered.
Note: "ri" is correct; it cannot safely be a memory operand, because
the stack pointer isn't where the compiler would expect it to be.
Signed-off-by: H. Peter Anvin <[email protected]>
@@ -25,7 +25,7 @@ static inline __constfunc bool cpu_has_eflag(unsigned long flag) 
        "pushf ; "
        "pop %1 ; "
        "popf"
-       : "=r" (f1), "=r" (f2) : "ri" (flag));
+       : "=&r" (f1), "=&r" (f2) : "ri" (flag));
 
     return !!((f1 ^ f2) & flag);
 }