All of lore.kernel.org
 help / color / mirror / Atom feed
From: rohan.puri15@gmail.com (rohan puri)
To: kernelnewbies@lists.kernelnewbies.org
Subject: Doubt regarding asmlinkage
Date: Thu, 8 Sep 2011 09:10:49 +0530	[thread overview]
Message-ID: <CALJfu6PYT1k_yicGqkrS_p-2P14e0xw9v6FyDxd35CvQ-WT4Jw@mail.gmail.com> (raw)
In-Reply-To: <CAGdaadZAuuygih0BZv13VBM8769ty3TRCswAeq8EjtmhmsXjLQ@mail.gmail.com>

Hi Mulyadi,

Thanks for the response. I do agree with the issue concerning the no.of
registers available are less for 32 bit to that of 64 bit.

But even in this case if parameters are more than the no of register for 32
bit, then also before executing int 80h interrupt it stores the parameters
in the register and after that system call dispatcher puts them on the
kernel stack of that process. So, how the case where more than no of
registers are the parameters to the system call is handled.

Regards,
Rohan.

On Thu, Sep 8, 2011 at 8:12 AM, Mulyadi Santosa
<mulyadi.santosa@gmail.com>wrote:

> Hi Rohan :)
>
> On Wed, Sep 7, 2011 at 19:09, rohan puri <rohan.puri15@gmail.com> wrote:
> > Doubt i have is whats the need for 32-bit intel arch to put parameters on
> > stack and not registers in a way similar to x86_64?
>
> well, if you need to pass so many parameters, then x86 32 bit
> registers can not cope with that. You only have EAX, EBX, ECX, EDX,
> ESI, EDI as far as I could remember.
>
> probably in 64 bit, registers is way more so it's still possible to
> put them in registers, which is of course the fastest way to access
> them.
>
> --
> regards,
>
> Mulyadi Santosa
> Freelance Linux trainer and consultant
>
> blog: the-hydra.blogspot.com
> training: mulyaditraining.blogspot.com
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20110908/cd314fe5/attachment.html 

  reply	other threads:[~2011-09-08  3:40 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CALJfu6OcCd7vdcEG+=PYAY2MrKyqHw7p5O2KNN7s0s7pxO5R+w@mail.gmail.com>
2011-09-07 12:09 ` Doubt regarding asmlinkage rohan puri
2011-09-08  2:42   ` Mulyadi Santosa
2011-09-08  3:40     ` rohan puri [this message]
2011-09-08  4:20       ` Mulyadi Santosa
2011-09-08  5:13         ` rohan puri
2011-09-08  7:17           ` Pei Lin
2011-09-08  9:19             ` rohan puri
2011-09-08 11:58               ` Pei Lin
2011-09-08 12:09                 ` rohan puri

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=CALJfu6PYT1k_yicGqkrS_p-2P14e0xw9v6FyDxd35CvQ-WT4Jw@mail.gmail.com \
    --to=rohan.puri15@gmail.com \
    --cc=kernelnewbies@lists.kernelnewbies.org \
    /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.