public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andi Kleen <ak@suse.de>
To: "Robert Williamson" <robbiew@us.ibm.com>
Cc: linux-kernel@vger.kernel.org, aniruddha.marathe@wipro.com,
	ltp-list@lists.sourceforge.net
Subject: Re: Same syscall is defined to different numbers on 3 different archs(was Re: Makefile  issue)
Date: 07 Apr 2003 17:54:39 +0200	[thread overview]
Message-ID: <p73vfxqxpz4.fsf@oldwotan.suse.de> (raw)
In-Reply-To: <OF51DE965A.FDCB6DBE-ON85256D01.005201B1-86256D01.005610CF@pok.ibm.com.suse.lists.linux.kernel>

"Robert Williamson" <robbiew@us.ibm.com> writes:
> 
> Obviously, we could add additional code to check for the running arch and
> define the syscall accordingly, however I'm not sure this is the correct
> way to go.  I'm copying our list, as well as the kernel mailing list about
> this, because I "think" the system calls should be defined to the same
> numbers across all architectures....but I'm not positive.  BTW,  I attached

No. Linux has traditionally used different syscall numbers for different
architectures. The original ports (alpha etc.) always used the syscall numbers
of the "native" Unix, so the numbering was often completely different.
Newer ports who weren't concered about such compatibility often did 
a renumbering too. For example x86-64 has a completely new 
"cache line optimized" ordering.

What should work on most architectures is 
(most = someone told me it doesn't work properly on IA64)

#include </path/to/kernel/source/include/asm-<arch>/unistd.h>
(you need the version in the kernel source because many glibc packagers
in their infinite wisdom use an old outdated copy of asm/ usually from
the last stable kernel only) 

_syscallN(...) 

-Andi

       reply	other threads:[~2003-04-07 15:44 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <OF51DE965A.FDCB6DBE-ON85256D01.005201B1-86256D01.005610CF@pok.ibm.com.suse.lists.linux.kernel>
2003-04-07 15:54 ` Andi Kleen [this message]
2003-04-07 16:26   ` Same syscall is defined to different numbers on 3 different archs(was Re: Makefile issue) Robert Williamson
2003-04-07 18:08     ` David Mosberger
2003-04-07 18:16       ` Robert Williamson
2003-04-07 18:49         ` David Mosberger
2003-04-08  2:23   ` Werner Almesberger
2003-04-08 13:30     ` [LTP] " Paul Larson
2003-04-08 19:47       ` Werner Almesberger
2003-04-07 15:39 Robert Williamson
2003-04-07 17:38 ` Robert Love

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=p73vfxqxpz4.fsf@oldwotan.suse.de \
    --to=ak@suse.de \
    --cc=aniruddha.marathe@wipro.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=ltp-list@lists.sourceforge.net \
    --cc=robbiew@us.ibm.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