On Thursday, August 03, 2006 12:31:24 AM -0400 Jeffrey Hutzelman <[EMAIL PROTECTED]> wrote:

On Wednesday, August 02, 2006 10:19:39 AM -0400 Derrick J Brashear
<[EMAIL PROTECTED]> wrote:

You could also use something like:

        # include <asm/unistd.h>

        static inline _syscall2(long, keyctl, int, option, void*, arg2)

        long serial = keyctl(KEYCTL_JOIN_SESSION_KEYRING, NULL);

Is keyctl() exported in the kernel now? Otherwise, this won't work for
us.

No; you misunderstand.  _syscall2() is a macro which emits the complete
definition of a 2-argument syscall.  The above expands to something like

static inline long keyctl(int option, void* arg2) {
  return _syscall(SYS_keyctl, option, arg2);
}

except the function body is slightly more complicated.

But like Chas, I don't expect that construct to work in the kernel.

Hm; actually, I see David says that will work in the kernel. I guess I can believe that.

-- Jeff
_______________________________________________
OpenAFS-devel mailing list
[email protected]
https://lists.openafs.org/mailman/listinfo/openafs-devel

Reply via email to