Again:syscall from modules

From: Trond Myklebust (trond.myklebust@fys.uio.no)
Date: Tue Dec 25 2001 - 13:37:27 EST


>>>>> " " == Amber Palekar <amber_palekar@yahoo.com> writes:

> Hi,
 
>> Just use sock_sendmsg() and sock_recvmsg() directly. They are
>> both exported in netsyms.c.
> Is there any specific reason behind not exporting
> sys_sendto and sys_recvfrom ??

Why would you want to do that when you already have a better kernel
interface available?

The sys_sendto, sys_recvfrom references the sockets by file handle,
something which requires an extra lookup operation to map the file
handle to socket struct.
OTOH sock_sendmsg(), sock_recvmesg() provides exactly the same
functionality, but takes a pointer to the kernel socket structure as
the argument.

Cheers,
  Trond
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Mon Dec 31 2001 - 21:00:11 EST