From: Mulyadi Santosa <mulyadi.santosa@gmail.com>
To: qemu-devel@nongnu.org
Cc: ricciantonio@gmail.com
Subject: Re: [Qemu-devel] question about syscall
Date: Wed, 11 Feb 2009 13:25:16 +0700 [thread overview]
Message-ID: <f284c33d0902102225v1fd9bc18u6a6948b193b44afa@mail.gmail.com> (raw)
In-Reply-To: <dec4146b0902091123n4d7e99f6m16cadac3a7ac8e88@mail.gmail.com>
Hi
On Tue, Feb 10, 2009 at 2:23 AM, Antonio Ricci <ricciantonio@gmail.com> wrote:
> Hi Muladi,
>
> some times ago someone said me to do something like this:
>
> /****************************************************/
> a piece of code handling interrupt in translate.c:
> case 0xcd: /* int N */
>
> val = ldub_code(s->pc++);
> /* asia: start */
> if (val == 0x80){
> gen_op_handle_syscall();
> break;
> }
>
> if (s->vm86 && s->iopl != 3) {
> gen_exception(s, EXCP0D_GPF, pc_start - s->cs_base);
>
> } else {
> gen_interrupt(s, val, pc_start - s->cs_base, s->pc - s->cs_base);
> }
> break;
>
> /*********************************************************/
>
>
> I can't understand why I have to intercept the case 0xcd. Can you explain
> me?
My guess is, 0xcd is the opcode of "int" instruction. Try to check
Intel instruction manual....
regards,
Mulyadi.
prev parent reply other threads:[~2009-02-11 6:25 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-02-07 13:15 [Qemu-devel] question about syscall Antonio Ricci
2009-02-07 13:27 ` Lionel Landwerlin
2009-02-07 17:33 ` Mulyadi Santosa
2009-02-09 19:23 ` Antonio Ricci
2009-02-11 6:25 ` Mulyadi Santosa [this message]
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=f284c33d0902102225v1fd9bc18u6a6948b193b44afa@mail.gmail.com \
--to=mulyadi.santosa@gmail.com \
--cc=qemu-devel@nongnu.org \
--cc=ricciantonio@gmail.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).