Different versions of system calls in assembly language

Matthew Dillon dillon at apollo.backplane.com
Thu Sep 29 09:38:13 PDT 2005


:
:On Thu, Sep 29, 2005 at 08:44:29AM -0700, Matthew Dillon wrote:
::     For historical reasons (meaning that the original authors of the
:
:So that's why there is one marked COMPAT BSD and the other STD BSD.
:
::     Generally speaking, you should not be calling int 0x80 directly
::     but should instead call into libc, but I understand you are trying
:
:Actually, I would happily use the libc call instead.  I declared mmap as an
:extern, and that's the one I got.  Is there a _mmap I should be calling
:instead?  I'm linking to libc, but somehow I'm getting the direct mmap call.
:
:jcm

    No, its just 'mmap'.  I have no idea why you might be getting the 
    wrong one.  Is this from assembly code?  

    Try writing some C code to call mmap, cc -S it, and see what it 
    generates.

					-Matt
					Matthew Dillon 
					<dillon at xxxxxxxxxxxxx>





More information about the Kernel mailing list