x86/alternatives: Use optimized NOPs for padding
authorBorislav Petkov <bp@suse.de>
Sat, 10 Jan 2015 19:34:07 +0000 (20:34 +0100)
committerBorislav Petkov <bp@suse.de>
Mon, 23 Feb 2015 12:44:12 +0000 (13:44 +0100)
Alternatives allow now for an empty old instruction. In this case we go
and pad the space with NOPs at assembly time. However, there are the
optimal, longer NOPs which should be used. Do that at patching time by
adding alt_instr.padlen-sized NOPs at the old instruction address.

Cc: Andy Lutomirski <luto@amacapital.net>
Signed-off-by: Borislav Petkov <bp@suse.de>
arch/x86/kernel/alternative.c

Simple merge