Re: [newbie] Re: Is it possible to directly call do_path_lookup() in kernel?

2007-01-24 Thread Xin Zhao
Thanks for your reply. But more details are appreciated. Actually I checked linkage.h before I sent last email. Looks like "fastcall" is used to direct the compiler to put the first 3 parameters into registers instead of stack. But I just don't understand why that causes "general protection fault

[newbie] Re: Is it possible to directly call do_path_lookup() in kernel?

2007-01-23 Thread Oleg Verych
On 2007-01-24, Xin Zhao wrote: > Archived-At: Hallo. > I just successfully called do_path_lookup() in my kernel module. I > just removed the "fastcall" from the declaration of do_path_lookup(), > then the problem disappeared. I don't quite un

Re: Is it possible to directly call do_path_lookup() in kernel?

2007-01-23 Thread Xin Zhao
I just successfully called do_path_lookup() in my kernel module. I just removed the "fastcall" from the declaration of do_path_lookup(), then the problem disappeared. I don't quite understand "fastcall" though. Can someone explain it? Thanks, -x On 1/23/07, Xin Zhao <[EMAIL PROTECTED]> wrote:

Is it possible to directly call do_path_lookup() in kernel?

2007-01-23 Thread Xin Zhao
Hi, I tried to call the following code in a kernel module: error = do_path_lookup(AT_FDCWD, "/etc/profile.d/glib2.csh", LOOKUP_PARENT, &nd); I exported the function do_path_lookup() using "EXPORT_SYMBOL_GPL(do_path_lookup);" But do_path_lookup() caused the "general protection fault: 00