Re: m68k, signals and single-stepping

Al Viro
2010-09-30T12:05:05Z

On Thu, Sep 30, 2010 at 10:21:47AM +0200, Andreas Schwab wrote:
> Geert Uytterhoeven <geert@linux-m68k.org> writes:
>
> >> So what's that SIGTRAP on exit from syscall in single-stepping mode for?
>
> The trace exception is low priority exception that is executed after all
> other exceptions are processed. So if the cpu single steps over a trap
> insns, the trace exception processing is started when the trap exception
> processing is complete, which is just before the cpu starts executing
> the trap exception handler in the kernel. You want the SIGTRAP to be
> sent to the user process, so you have to delay sending it until the
> kernel returns to user space.

Um... What's wrong with doing that from trap_c()?