Re: [PATCH v6 3.2-rc1 28/28] uprobes: introduceUTASK_SSTEP_TRAPPED logic

From: Srikar Dronamraju
Date: Tue Nov 15 2011 - 03:09:56 EST


> >
> > +void __weak abort_xol(struct pt_regs *regs, struct uprobe_task *utask)
> > +{
> > + set_instruction_pointer(regs, utask->vaddr);
> > +}
>
> OK, this is fine on 32bit. But X86_64 should also handle
> UPROBES_FIX_RIP_AX/CX?
>
> IOW, shouldn't we also do
>
> if (uprobe->fixups & UPROBES_FIX_RIP_AX)
> regs->ax = tskinfo->saved_scratch_register;
> else if (uprobe->fixups & UPROBES_FIX_RIP_CX)
> regs->cx = tskinfo->saved_scratch_register;
>
> on 64bit?

Yes, we should be doing this on x86_64. Since abort_xol is a weak
function, I will have x86_64 specific abort_xol.

--
Thanks and Regards
Srikar

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/