From: Andi Kleen <ak@muc.de>
To: Fabiano Ramos <ramos_fabiano@yahoo.com.br>
Cc: linux-kernel@vger.kernel.org
Subject: Re: ptrace in 2.6.5
Date: Mon, 10 May 2004 20:49:39 +0200 [thread overview]
Message-ID: <m365b4kth8.fsf@averell.firstfloor.org> (raw)
In-Reply-To: <1UlcA-6lq-9@gated-at.bofh.it> (Fabiano Ramos's message of "Mon, 10 May 2004 17:50:08 +0200")
Fabiano Ramos <ramos_fabiano@yahoo.com.br> writes:
> Hi All.
>
> Is ptrace(), in singlestep mode, required to stop after a int 0x80?
> When tracing a sequence like
>
> mov ...
> int 0x80
> mov ....
>
> ptrace would notify the tracer after the two movs, but not after the
> int 0x80. I want to know if it is a bug or the expected behaviour.
What happens is that after the int 0x80 the CPU is in ring 0 (you
don't get an trace event in that mode unless you use a kernel debugger).
Then when the kernel returns the last instruction executed before it is an
IRET. But the IRET is also executed still in ring 0 and you should not get
an event for it (you can not even access its code from user space).
So it's expected behaviour.
-Andi
next parent reply other threads:[~2004-05-10 18:49 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <1UlcA-6lq-9@gated-at.bofh.it>
2004-05-10 18:49 ` Andi Kleen [this message]
2004-05-10 19:37 ` ptrace in 2.6.5 Davide Libenzi
2004-05-10 20:24 ` Fabiano Ramos
2004-05-10 21:49 ` OGAWA Hirofumi
2004-05-10 22:47 ` OGAWA Hirofumi
2004-05-10 22:58 ` Daniel Jacobowitz
2004-05-10 23:12 ` Davide Libenzi
2004-05-11 0:40 ` Fabiano Ramos
2004-05-11 6:14 ` Davide Libenzi
2004-05-11 6:27 ` Davide Libenzi
2004-05-11 6:41 ` Davide Libenzi
2004-05-11 14:07 ` Daniel Jacobowitz
2004-05-10 15:46 Fabiano Ramos
2004-05-10 16:10 ` Daniel Jacobowitz
2004-05-10 16:22 ` Fabiano Ramos
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m365b4kth8.fsf@averell.firstfloor.org \
--to=ak@muc.de \
--cc=linux-kernel@vger.kernel.org \
--cc=ramos_fabiano@yahoo.com.br \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.