All of lore.kernel.org
 help / color / mirror / Atom feed
From: leilei175 <leilei175@gmail.com>
To: Keir Fraser <keir.fraser@eu.citrix.com>
Cc: "xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>,
	"Jayaraman, Bhaskar" <Bhaskar.Jayaraman@lsi.com>
Subject: Re: how can I find code of hypercall?
Date: Wed, 11 Mar 2009 20:37:15 +0800	[thread overview]
Message-ID: <49B7B07B.60302@gmail.com> (raw)
In-Reply-To: <C5DD423F.4C68%keir.fraser@eu.citrix.com>

Hi, keir and Jayaraman,
Thanks for your explanation

Keir Fraser wrote:
> On 11/03/2009 10:08, "Jayaraman, Bhaskar" <Bhaskar.Jayaraman@lsi.com> wrote:
>
>   
>> I've done this on an HVM. For Intel, you can go to platform-pci and dump the
>> hypercall page on the console 4 bytes at a time. Each 4 byte value on the
>> hypercall page constitutes an Intel x86 instruction, and you should find
>> something like this: -
>> 0xc1010f00 
>> 0xccccccc3 
>>     
>
> You know x86 instructions are not fixed-length, right? Actually the
> instruction sequence is:
>  0xb8 <imm32>   : mov imm32,%eax (5-byte instruction)
>  0x0f 0x01 0xc1 : vmcall (3-byte instruction)
>  0xc3           : ret (1-byte instruction)
>
> See xen/arch/x86/hvm/vmx/vmx.c:vmx_init_hypercall_page().
>
>  -- Keir
>
>
>
>   

      parent reply	other threads:[~2009-03-11 12:37 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-03-11  9:52 how can I find code of hypercall? leilei175
2009-03-11 10:08 ` Jayaraman, Bhaskar
2009-03-11 10:26   ` Keir Fraser
2009-03-11 11:46     ` Jayaraman, Bhaskar
2009-03-11 14:16       ` Goswin von Brederlow
2009-03-11 12:37     ` leilei175 [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=49B7B07B.60302@gmail.com \
    --to=leilei175@gmail.com \
    --cc=Bhaskar.Jayaraman@lsi.com \
    --cc=keir.fraser@eu.citrix.com \
    --cc=xen-devel@lists.xensource.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 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.