On Sat, 2018-01-06 at 11:49 +0000, David Woodhouse wrote: > > +#if defined(CONFIG_X86_64) && defined(RETPOLINE) > +/* > + * Since the inline asm uses the %V modifier which is only in newer GCC, > + * the 64-bit one is dependent on RETPOLINE not CONFIG_RETPOLINE. > + */ > +# define NOSPEC_CALL ALTERNATIVE(                              \ > +       "call *%[thunk_target]\n",                              \ > +       "call __x86.indirect_thunk.%V[thunk_target]\n",         \ > +       X86_FEATURE_RETPOLINE) > +# define THUNK_TARGET(addr) [thunk_target] "r" (addr) > +#elif defined(CONFIG_X86_64) && defined(CONFIG_RETPOLINE)                  ^^^^^^^^^^^^^  Arse. That'll invalidate my 32-bit test runs somewhat. I knew I should have also repeated the "deliberately break the ASM and check it crashes" tests. V6 coming in a little while, with 32-bit fixed properly... > +/* > + * For i386 we use the original ret-equivalent retpoline, because > + * otherwise we'll run out of registers. We don't care about CET > + * here, anyway. > + */