This is a brief introduction about how Linux kernel handles the
send system call.
This study is based on kernel version 3.7.2, which is the latest stable kernel when writing this study.
How system call is defined
In the latest kernel, the system call is defined using the
SYSCALL_DEFINEx macro, in which
x is the number of arguments. For example, in order to find the definition of
asmlinkage long sys_sendto(int, void __user *, size_t, unsigned, struct sockaddr __user *, int);, you need to
SYSCALL_DEFINE6 because it has 6 arguments.
The definition of the system call
send can be found at