Blaisorblade wrote:
*strange* that a kernel module uses the "_syscall" macro to do a syscall with "int 0x80" while already being in kernelspace...

It's interesting that the module contains the following code:

------------------------
//#define FGL_USE_SCT /* for developer use only */

//...<snip>...


#ifdef FGL_USE_SCT // get direct function pointers from sys_call_table for calling #else /* FGL_USE_SCT */ // call functions indirectly by using the syscall macros, // entrypoints get defined by below constructs

#if !defined(__ia64__)
// the macros do use errno variable
static int errno;
#endif // __ia64__

// int mlock(const void *addr, size_t len);
_syscall2(int, mlock, const void *, addr, size_t, len )
// int munlock(const void *addr, size_t len);
_syscall2(int, munlock, const void *, addr, size_t, len )
#if !defined(__ia64__)
#if !defined(__x86_64__)
// TODO: ia64
// int modify_ldt(int func, void *ptr, unsigned long bytecount);
_syscall3( int, modify_ldt, int, func, void *, ptr, unsigned long, bytecount )
#endif
#endif
#endif /* FGL_USE_SCT */
--------------------------


I actually tried to #define FGL_USE_SCT, but it didn't compile either.


------------------------------------------------------- This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting Tool for open source databases. Create drag-&-drop reports. Save time by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc. Download a FREE copy at http://www.intelliview.com/go/osdn_nl _______________________________________________ User-mode-linux-devel mailing list User-mode-linux-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-devel

Reply via email to