On Tue, Mar 04, 2003 at 10:56:25AM -0800, Ian Romanick wrote: > Philip Brown wrote: > > So kernel will be compiled with offset=64bits, user mode will be compiled > > with offset=32bits... boom. > > > > All numeric fields passed through the ioctls, should have fixed, > > identifiable sizes. > > Ah. So this isn't just a 64-bit arch problem. It's a mixed 32/64 > problem. That's different. What happens on Linux is the 32-bit apps go > through some sort of ioctl thunking layer to convert the 32-bit ioctls > to the native 64-bit ioctls. I know that this is done for IA-64 and > PPC64. It will also have to be done for x86-64.
Does this "thunking" happen at the native OS level, or in the linux drm code itself? Reguardless, you still need to fix the issue that the header file drm.h (and probably others) is included by both kernel and application layer, therefore you should fix the type sizes of all values in structs, to ensure that the structs are the same size whether they are included by 64bit or 32bit code. > Can somebody explain exactly how this works on Linux? I'm still a > little fuzzy on it. Is there some way that DRI could handle this > "genericly" for supporting other operating systems? I'm sure that > Solaris and *BSD don't handle it quite the same way that Linux does. > > For Philip, I would suggest getting 64-bit apps to work with a 64-bit > kernel before trying to tackle mixed-mode. You've got enough work to > port DRI to SPARC Solaris as it is! :) Well, I'm not trying THAT monster :-) I'm just targetting Solaris x86 for right now. But figured it's important to point out these issues, while I'm looking at that level of the code. And btw: the xfree server itself is typically a 32bit app, I believe. /usr/openwin/bin/Xsun certainly is. ------------------------------------------------------- This SF.net email is sponsored by: Etnus, makers of TotalView, The debugger for complex code. Debugging C/C++ programs can leave you feeling lost and disoriented. TotalView can help you find your way. Available on major UNIX and Linux platforms. Try it free. www.etnus.com _______________________________________________ Dri-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/dri-devel