public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Jiri Slaby <jslaby@suse.cz>
To: Xin Tong <xerox.time.tech@gmail.com>
Cc: linux-kernel <linux-kernel@vger.kernel.org>,
	Jiri Slaby <jirislaby@gmail.com>
Subject: Re: syscall descriptor table
Date: Fri, 06 Apr 2012 10:24:44 +0200	[thread overview]
Message-ID: <4F7EA84C.7050700@suse.cz> (raw)
In-Reply-To: <CALKntY2MONLeRvXs2xdamSAQeWDs4ERHjWuCxNL8_QRrHwVhqg@mail.gmail.com>

On 04/05/2012 11:55 PM, Xin Tong wrote:
> Can anyone please describe to me how x86 syscall works ( i.e. how it
> is dispatched to the correct function) on x86 ?
> 
> mov $1, %eax   ;; __NR_exit = 1
> mov $42, %ebx  ;; status = 42
> sysenter       ;; perform the syscall!
> 
> what does the sysenter instruction do ? what is the difference aganst int 0x80.

Please refer to some processor manual. For example: Intel 64 and IA-32
Architectures Software Developer’s Manual. For the entry point see
ia32_sysenter_target in arch/x86/kernel/entry_32.S for x86_32 or
arch/x86/ia32/ia32entry.S for x86_64 with 32-bit binary.

regards,
-- 
js
suse labs


      reply	other threads:[~2012-04-06  8:24 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-05 21:55 syscall descriptor table Xin Tong
2012-04-06  8:24 ` Jiri Slaby [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=4F7EA84C.7050700@suse.cz \
    --to=jslaby@suse.cz \
    --cc=jirislaby@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=xerox.time.tech@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