From owner-freebsd-hackers Tue Apr 23 8: 2:39 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from duke.cs.duke.edu (duke.cs.duke.edu [152.3.140.1]) by hub.freebsd.org (Postfix) with ESMTP id 003DB37B422 for ; Tue, 23 Apr 2002 08:02:34 -0700 (PDT) Received: from grasshopper.cs.duke.edu (grasshopper.cs.duke.edu [152.3.145.30]) by duke.cs.duke.edu (8.9.3/8.9.3) with ESMTP id LAA14954; Tue, 23 Apr 2002 11:02:33 -0400 (EDT) Received: (from gallatin@localhost) by grasshopper.cs.duke.edu (8.11.6/8.9.1) id g3NF23v12047; Tue, 23 Apr 2002 11:02:03 -0400 (EDT) (envelope-from gallatin@cs.duke.edu) From: Andrew Gallatin MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <15557.30571.834026.208654@grasshopper.cs.duke.edu> Date: Tue, 23 Apr 2002 11:02:03 -0400 (EDT) To: Kenneth Culver Cc: freebsd-hackers@freebsd.org Subject: Re: implementing linux mmap2 syscall In-Reply-To: <20020423103655.V28948-100000@alpha.yumyumyum.org> References: <15557.27747.802212.659760@grasshopper.cs.duke.edu> <20020423103655.V28948-100000@alpha.yumyumyum.org> X-Mailer: VM 6.75 under 21.1 (patch 12) "Channel Islands" XEmacs Lucid Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Kenneth Culver writes: > > > Basically, linux_mmap2 takes 6 args, and this looks here like only 5 args are > > > making it in... I checked this because the sixth argument to linux_mmap2() in > > > truss was showing 0x6, but when I printed out that arg from the kernel, it > > > was showing 0x0. Am I correct here? > > > > > > Ken > > > > Yes. According to http://john.fremlin.de/linux/asm/, linux used to > > parse only 5 args but now it parses six. Try adding: > > args[5] = tf->tf_ebp; > > > I don't think that arg is there: > > Apr 23 10:36:13 ken /kernel: tf->tf_ebp = -1077938040 > > Ken My guess is that we're not doing something we should be doing in int0x80_syscall in order to get that last arg. But I do not have enough x86 knowledge to understand how the trapframe is constructed, so I cannot tell what needs to be done. Perhaps somebody with more x86 fu can help. Sorry, Drew To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message