On Fri, 3 May 2019 12:22:47 +0200 Peter Zijlstra <peterz@xxxxxxxxxxxxx> wrote: > Given that the entry_*.S changes for this functionality are somewhat > tricky, make sure the paths are tested every boot, instead of on the > rare occasion when we trip an INT3 while rewriting text. > > Getting the INT3 frame setup even slightly wrong will make this come > unstuck something spectacular. > > Requested-by: Andy Lutomirski <luto@xxxxxxxxxx> > Signed-off-by: Peter Zijlstra (Intel) <peterz@xxxxxxxxxxxxx> > --- > arch/x86/kernel/alternative.c | 81 ++++++++++++++++++++++++++++++++++++++++--- > 1 file changed, 77 insertions(+), 4 deletions(-) I'll add this to my queue, as I tested this on x86_32 and 64. I also put in a printk("HERE in int3_magic\n") to make sure it really did get there (although, the BUG_ON should be good enough). The printk will be removed from the official commit. It was just for my peace of mind. -- Steve