Article Title: What is Linux kernel system call. Linux is a technology channel of the IT lab in China. Includes basic categories such as desktop applications, Linux system management, kernel research, embedded systems, and open source.
Linux kernel system call)
All operating systems have some built-in functions in their kernel, which can be used to complete some system-level functions. In Linux, such a function is called "system call". systemcall is used in English. These functions represent a type of conversion from the user space to the island and space. for example, if you call the open function in the user space, sys_open is called in the kernel space. All system calls supported by an installed system can be seen in the/usr/include/bits/syscall. h file. Below are the first lines of the file in my system:
[Hwang @ langchao hwang] $ head/usr/include/bits/syscall. h
/* Generated at libc build time from kernel syscall list .*/
# Ifndef _ SYSCALL_H
# Error "Never use directly; include instead ."
# Endif
# Define SYS_stime _ NR_stime
# Define SYS_getresuid _ NR_getresuid
# Define SYS_rt_sigqueueinfo _ NR_rt_sigqueueinfo
# Define SYS_mmap2 _ NR_mmap2
Each system call has a defined number used to construct these system calls. The kernel manages these system calls through 0x80 interruption. The numbers and parameters corresponding to these system calls are sent to some registers during the call.
The number called by the system is actually a serial number, indicating its position in the system's array sys_call_table.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.