Messages in this thread | | | Date | Tue, 7 Apr 2020 19:26:30 +0200 | From | Peter Zijlstra <> | Subject | Re: [PATCH V2 9/9] x86/speculation: Remove all ANNOTATE_NOSPEC_ALTERNATIVE directives |
| |
On Tue, Apr 07, 2020 at 07:01:43PM +0200, Alexandre Chartre wrote:
> I think that's the case with smap_save: > > static __always_inline unsigned long smap_save(void) > { > unsigned long flags; > > asm volatile (ALTERNATIVE("", "pushf; pop %0; " __ASM_CLAC, > X86_FEATURE_SMAP) > : "=rm" (flags) : : "memory", "cc"); > > return flags; > } > > The alternative does change the stack but objtool won't complain > because it handles the pushf and pop instruction.
Oh bugger; indeed! That'll wreck unwinding.
| |