Subject: What does the edx register do in syscall
To: netbsd-ports <>
From: Brett Lymn <>
List: netbsd-ports
Date: 02/13/1994 16:14:17
Hello folks!

        I am trying to get a vm86 call into the kernel.   One of the
things I need to do is fake up a dummy successful syscall frame.  I
have had a look at the syscall function in trap.c and can see where
the frame is updated depending on the result of the syscall.  The
problem I have is that I can understand why eax and the carry flag are
modified *but* on a successful call the edx is also changed.  Anyone
know why?  Do I have to worry or can I just use the current edx and

NB: This dummy frame is not going to return to a normal process, it is
faked up for the purpose of entering the vm86 mode, if it makes a

Brett Lymn, Computer Systems Administrator, AWA Defence Industries
"Where a calculator on the ENIAC is equipped with 18,000 vaccuum tubes
and weighs 30 tons, computers in the future may have only 1,000 vaccuum
tubes and perhaps weigh 1 1/2 tons."
                -- Popular Mechanics, March 1949