Date: Thu, 29 Apr 1999 09:30:48 +0800 From: Stephen Hocking-Senior Programmer PGS Tensor Perth <shocking@prth.pgs.com> To: Dag-Erling Smorgrav <des@flood.ping.uio.no> Cc: hackers@freebsd.org Subject: Re: Porting Linux Device drivers Message-ID: <199904290130.JAA12353@ariadne.tensor.pgs.com> In-Reply-To: Your message of "28 Apr 1999 11:00:41 %2B0200." <xzplnfd5dc6.fsf@flood.ping.uio.no>
next in thread | previous in thread | raw e-mail | index | archive | help
> shocking@prth.pgs.com (Stephen Hocking-Senior Programmer PGS Tensor Perth) writes: > > The problem I'm having is that I'm using the glide Linux > > binaries to test the device, and the positive return values are being > > trapped somewhere and turned into -1, an obvious failure which the > > Linux glide library interprets as an error, spitting the dummy. > > The userland part of the syscall mechanism stores the returned value > in errno and returns ((ret == 0) ? p_retval[0] : -1). Hence, if you > want to return a specific value, store it in p_retval[0] and return 0 > to indicate success. Aaagh, I just found out where I goofed when trying to do this. That bit now works. What happens now is that a passed structure from the glide lib's ioctl calls doesn't seem to agree with the definition I have in the driver. Sigh. Stephen -- The views expressed above are not those of PGS Tensor. "We've heard that a million monkeys at a million keyboards could produce the Complete Works of Shakespeare; now, thanks to the Internet, we know this is not true." Robert Wilensky, University of California To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199904290130.JAA12353>