]>
Commit | Line | Data |
---|---|---|
c11b1abf | 1 | .\" Copyright (C) 2007 Michael Kerrisk <mtk.manpages@gmail.com> |
09de4bf1 MK |
2 | .\" with some input from Stepan Kasal <kasal@ucw.cz> |
3 | .\" | |
4 | .\" Some content retained from an earlier version of this page: | |
fea681da MK |
5 | .\" Copyright (C) 1998 Andries Brouwer (aeb@cwi.nl) |
6 | .\" Modifications for 2.2 and 2.4 Copyright (C) 2002 Ian Redfern | |
7 | .\" <redferni@logica.com> | |
8 | .\" | |
93015253 | 9 | .\" %%%LICENSE_START(VERBATIM) |
fea681da MK |
10 | .\" Permission is granted to make and distribute verbatim copies of this |
11 | .\" manual provided the copyright notice and this permission notice are | |
12 | .\" preserved on all copies. | |
13 | .\" | |
14 | .\" Permission is granted to copy and distribute modified versions of this | |
15 | .\" manual under the conditions for verbatim copying, provided that the | |
16 | .\" entire resulting derived work is distributed under the terms of a | |
17 | .\" permission notice identical to this one. | |
18 | .\" | |
19 | .\" Since the Linux kernel and libraries are constantly changing, this | |
20 | .\" manual page may be incorrect or out-of-date. The author(s) assume no | |
21 | .\" responsibility for errors or omissions, or for damages resulting from | |
22 | .\" the use of the information contained herein. The author(s) may not | |
23 | .\" have taken the same level of care in the production of this manual, | |
24 | .\" which is licensed free of charge, as they might when working | |
25 | .\" professionally. | |
26 | .\" | |
27 | .\" Formatted or processed versions of this manual, if unaccompanied by | |
28 | .\" the source, must acknowledge the copyright and authors of this work. | |
4b72fb64 | 29 | .\" %%%LICENSE_END |
fea681da | 30 | .\" |
bf253d9b | 31 | .TH SYSCALLS 2 2014-04-18 "Linux" "Linux Programmer's Manual" |
fea681da | 32 | .SH NAME |
09de4bf1 | 33 | syscalls \- Linux system calls |
fea681da | 34 | .SH SYNOPSIS |
09de4bf1 | 35 | Linux system calls. |
fea681da MK |
36 | .SH DESCRIPTION |
37 | The system call is the fundamental interface between an application | |
c13182ef | 38 | and the Linux kernel. |
7d50a840 MK |
39 | .SS System calls and library wrapper functions |
40 | System calls are generally not invoked directly, | |
61d7d93c MK |
41 | but rather via wrapper functions in glibc (or perhaps some other library). |
42 | For details of direct invocation of a system call, see | |
43 | .BR intro (2). | |
7d50a840 MK |
44 | Often, but not always, the name of the wrapper function is the same |
45 | as the name of the system call that it invokes. | |
46 | For example, glibc contains a function | |
47 | .BR truncate () | |
48 | which invokes the underlying "truncate" system call. | |
fea681da | 49 | |
7d50a840 | 50 | Often the glibc wrapper function is quite thin, doing little work |
c8bd05f9 MK |
51 | other than copying arguments to the right registers |
52 | before invoking the system call, | |
53 | and then setting | |
54 | .I errno | |
55 | appropriately after the system call has returned. | |
56 | (These are the same steps that are performed by | |
57 | .BR syscall (2), | |
58 | which can be used to invoke system calls | |
59 | for which no wrapper function is provided.) | |
60 | Note: system calls indicate a failure by returning a negative error | |
61 | number to the caller; | |
62 | when this happens, | |
63 | the wrapper function negates the returned error number | |
64 | (to make it positive), copies it to | |
65 | .IR errno , | |
66 | and returns \-1 to the caller of the wrapper. | |
7d50a840 MK |
67 | |
68 | Sometimes, however, the wrapper function does some extra work | |
69 | before invoking the system call. | |
70 | For example, nowadays there are (for reasons described below) two | |
71 | related system calls, | |
72 | .BR truncate (2) | |
73 | and | |
74 | .BR truncate64 (2), | |
75 | and the glibc | |
76 | .BR truncate () | |
61d7d93c MK |
77 | wrapper function checks which of those system calls |
78 | are provided by the kernel and determines which should be employed. | |
7d50a840 | 79 | .SS System call list |
1ce7088e | 80 | Below is a list of the Linux system calls. |
09de4bf1 MK |
81 | In the list, the |
82 | .I Kernel | |
83 | column indicates the kernel version | |
84 | for those system calls that were new in Linux 2.2, | |
85 | or have appeared since that kernel version. | |
86 | Note the following points: | |
87 | .IP * 3 | |
88 | Where no kernel version is indicated, | |
dc2f5549 MK |
89 | the system call appeared in kernel 1.0 or earlier. |
90 | .IP * | |
91 | Where a system call is marked "1.2" | |
92 | this means the system call probably appeared in a 1.1.x kernel version, | |
93 | and first appeared in a stable kernel with 1.2. | |
94 | (Development of the 1.2 kernel was initiated from a branch of kernel | |
95 | 1.0.6 via the 1.1.x unstable kernel series.) | |
96 | .IP * | |
97 | Where a system call is marked "2.0" | |
98 | this means the system call probably appeared in a 1.3.x kernel version, | |
99 | and first appeared in a stable kernel with 2.0. | |
100 | (Development of the 2.0 kernel was initiated from a branch of kernel | |
101 | 1.2.x, somewhere around 1.2.10, | |
102 | via the 1.3.x unstable kernel series.) | |
d6ce4960 MK |
103 | .\" Was kernel 2.0 started from a branch of 1.2.10? |
104 | .\" At least from the timestamps of the tarballs of | |
105 | .\" of 1.2.10 and 1.3.0, that's how it looks, but in | |
e0bf9127 | 106 | .\" fact the diff doesn't seem very clear, the |
d6ce4960 MK |
107 | .\" 1.3.0 .tar.bz is much bigger (2.0 MB) than the |
108 | .\" 1.2.10 .tar.bz2 (1.8 MB), and AEB points out the | |
109 | .\" timestamps of some files in 1.3.0 seem to be older | |
110 | .\" than those in 1.2.10. All of this suggests | |
111 | .\" that there might not have been a clean branch point. | |
09de4bf1 MK |
112 | .IP * |
113 | Where a system call is marked "2.2" | |
114 | this means the system call probably appeared in a 2.1.x kernel version, | |
115 | and first appeared in a stable kernel with 2.2.0. | |
f9e4d811 MK |
116 | (Development of the 2.2 kernel was initiated from a branch of kernel |
117 | 2.0.21 via the 2.1.x unstable kernel series.) | |
09de4bf1 MK |
118 | .IP * |
119 | Where a system call is marked "2.4" | |
120 | this means the system call probably appeared in a 2.3.x kernel version, | |
121 | and first appeared in a stable kernel with 2.4.0. | |
f9e4d811 MK |
122 | (Development of the 2.4 kernel was initiated from a branch of |
123 | kernel 2.2.8 via the 2.3.x unstable kernel series.) | |
09de4bf1 MK |
124 | .IP * |
125 | Where a system call is marked "2.6" | |
126 | this means the system call probably appeared in a 2.5.x kernel version, | |
127 | and first appeared in a stable kernel with 2.6.0. | |
f9e4d811 MK |
128 | (Development of kernel 2.6 was initiated from a branch |
129 | of kernel 2.4.15 via the 2.5.x unstable kernel series.) | |
09de4bf1 MK |
130 | .IP * |
131 | Starting with kernel 2.6.0, the development model changed, | |
132 | and new system calls may appear in each 2.6.x release. | |
f9e4d811 MK |
133 | In this case, the exact version number where the system call appeared |
134 | is shown. | |
c39f51b0 MK |
135 | This convention continues with the 3.x kernel series, |
136 | which followed on from kernel 2.6.39. | |
f9e4d811 MK |
137 | .IP * |
138 | In some cases, a system call was added to a stable kernel | |
139 | series after it branched from the previous stable kernel | |
140 | series, and then backported into the earlier stable kernel series. | |
141 | For example some system calls that appeared in 2.6.x were also backported | |
142 | into a 2.4.x release after 2.4.15. | |
143 | When this is so, the version where the system call appeared | |
09de4bf1 | 144 | in both of the major kernel series is listed. |
09de4bf1 | 145 | .PP |
bf253d9b | 146 | The list of system calls that are available as at kernel 3.15 |
09de4bf1 MK |
147 | (or in a few cases only on older kernels) is as follows: |
148 | .\" | |
149 | .\" Looking at scripts/checksyscalls.sh in the kernel source is | |
929f1ff7 | 150 | .\" instructive about x86 specifics. |
09de4bf1 | 151 | .\" |
56f2caff | 152 | .ad l |
09de4bf1 | 153 | .TS |
7d50a840 MK |
154 | l l l |
155 | --- | |
09de4bf1 | 156 | l l l. |
e2f9e1be | 157 | \fBSystem call\fP \fBKernel\fP \fBNotes\fP |
3fffa7b6 | 158 | |
dc2f5549 | 159 | \fB_llseek\fP(2) 1.2 |
8717e79e MK |
160 | \fB_newselect\fP(2) 2.0 |
161 | \fB_sysctl\fP(2) 2.0 | |
162 | \fBaccept\fP(2) 2.0 See notes on \fBsocketcall\fP(2) | |
53e819d0 | 163 | \fBaccept4\fP(2) 2.6.28 |
8717e79e MK |
164 | \fBaccess\fP(2) 1.0 |
165 | \fBacct\fP(2) 1.0 | |
09de4bf1 | 166 | \fBadd_key\fP(2) 2.6.11 |
8717e79e MK |
167 | \fBadjtimex\fP(2) 1.0 |
168 | \fBalarm\fP(2) 1.0 | |
f9e4d811 | 169 | \fBalloc_hugepages\fP(2) 2.5.36 Removed in 2.5.44 |
8717e79e | 170 | \fBbdflush\fP(2) 1.2 T{ |
b6bc918e MK |
171 | Deprecated (does nothing) |
172 | .br | |
173 | since 2.6 | |
56f2caff | 174 | T} |
8717e79e MK |
175 | \fBbind\fP(2) 2.0 See notes on \fBsocketcall\fP(2) |
176 | \fBbrk\fP(2) 1.0 | |
929f1ff7 | 177 | \fBcacheflush\fP(2) 1.2 Not on x86 |
09de4bf1 MK |
178 | \fBcapget\fP(2) 2.2 |
179 | \fBcapset\fP(2) 2.2 | |
8717e79e MK |
180 | \fBchdir\fP(2) 1.0 |
181 | \fBchmod\fP(2) 1.0 | |
182 | \fBchown\fP(2) 2.2 T{ | |
b6bc918e MK |
183 | See \fBchown\fP(2) for |
184 | .br | |
185 | version details | |
8717e79e | 186 | T} |
09de4bf1 | 187 | \fBchown32\fP(2) 2.4 |
8717e79e | 188 | \fBchroot\fP(2) 1.0 |
b9cad55b | 189 | \fBclock_adjtime\fP(2) 2.6.39 |
09de4bf1 MK |
190 | \fBclock_getres\fP(2) 2.6 |
191 | \fBclock_gettime\fP(2) 2.6 | |
192 | \fBclock_nanosleep\fP(2) 2.6 | |
193 | \fBclock_settime\fP(2) 2.6 | |
8717e79e MK |
194 | \fBclone\fP(2) 1.0 |
195 | \fBclose\fP(2) 1.0 | |
196 | \fBconnect\fP(2) 2.0 See notes on \fBsocketcall\fP(2) | |
197 | \fBcreat\fP(2) 1.0 | |
56f2caff | 198 | \fBcreate_module\fP(2) Removed in 2.6 |
8717e79e MK |
199 | \fBdelete_module\fP(2) 1.0 |
200 | \fBdup\fP(2) 1.0 | |
201 | \fBdup2\fP(2) 1.0 | |
eb153420 | 202 | \fBdup3\fP(2) 2.6.27 |
09de4bf1 | 203 | \fBepoll_create\fP(2) 2.6 |
eb153420 | 204 | \fBepoll_create1\fP(2) 2.6.27 |
09de4bf1 MK |
205 | \fBepoll_ctl\fP(2) 2.6 |
206 | \fBepoll_pwait\fP(2) 2.6.19 | |
207 | \fBepoll_wait\fP(2) 2.6 | |
208 | \fBeventfd\fP(2) 2.6.22 | |
eb153420 | 209 | \fBeventfd2\fP(2) 2.6.27 |
8717e79e MK |
210 | \fBexecve\fP(2) 1.0 |
211 | \fBexit\fP(2) 1.0 | |
30fa088c | 212 | \fBexit_group\fP(2) 2.6 |
09de4bf1 | 213 | \fBfaccessat\fP(2) 2.6.16 |
7d50a840 MK |
214 | \fBfadvise64\fP(2) 2.6 |
215 | .\" Implements \fBposix_fadvise\fP(2) | |
216 | \fBfadvise64_64\fP(2) 2.6 | |
6397da8c | 217 | \fBfallocate\fP(2) 2.6.23 |
3610ae93 MK |
218 | \fBfanotify_init\fP(2) 2.6.37 |
219 | \fBfanotify_mark\fP(2) 2.6.37 | |
220 | .\" The fanotify calls were added in Linux 2.6.36, | |
221 | .\" but disabled while the API was finalized. | |
8717e79e MK |
222 | \fBfchdir\fP(2) 1.0 |
223 | \fBfchmod\fP(2) 1.0 | |
09de4bf1 | 224 | \fBfchmodat\fP(2) 2.6.16 |
8717e79e | 225 | \fBfchown\fP(2) 1.0 |
09de4bf1 MK |
226 | \fBfchown32\fP(2) 2.4 |
227 | \fBfchownat\fP(2) 2.6.16 | |
8717e79e | 228 | \fBfcntl\fP(2) 1.0 |
09de4bf1 | 229 | \fBfcntl64\fP(2) 2.4 |
8717e79e | 230 | \fBfdatasync\fP(2) 2.0 |
09de4bf1 | 231 | \fBfgetxattr\fP(2) 2.6; 2.4.18 |
ecbb4bb7 | 232 | \fBfinit_module\fP(2) 3.8 |
09de4bf1 | 233 | \fBflistxattr\fP(2) 2.6; 2.4.18 |
dc2f5549 | 234 | \fBflock\fP(2) 2.0 |
8717e79e | 235 | \fBfork\fP(2) 1.0 |
f9e4d811 | 236 | \fBfree_hugepages\fP(2) 2.5.36 Removed in 2.5.44 |
09de4bf1 MK |
237 | \fBfremovexattr\fP(2) 2.6; 2.4.18 |
238 | \fBfsetxattr\fP(2) 2.6; 2.4.18 | |
8717e79e | 239 | \fBfstat\fP(2) 1.0 |
09de4bf1 | 240 | \fBfstat64\fP(2) 2.4 |
f6b8bc07 | 241 | \fBfstatat64\fP(2) 2.6.16 |
8717e79e | 242 | \fBfstatfs\fP(2) 1.0 |
09de4bf1 | 243 | \fBfstatfs64\fP(2) 2.6 |
8717e79e MK |
244 | \fBfsync\fP(2) 1.0 1.0 |
245 | \fBftruncate\fP(2) 1.0 | |
09de4bf1 | 246 | \fBftruncate64\fP(2) 2.4 |
30fa088c | 247 | \fBfutex\fP(2) 2.6 |
09de4bf1 | 248 | \fBfutimesat\fP(2) 2.6.16 |
56f2caff | 249 | \fBget_kernel_syms\fP(2) Removed in 2.6 |
09de4bf1 MK |
250 | \fBget_mempolicy\fP(2) 2.6.6 |
251 | \fBget_robust_list\fP(2) 2.6.17 | |
30fa088c | 252 | \fBget_thread_area\fP(2) 2.6 |
09de4bf1 MK |
253 | \fBgetcpu\fP(2) 2.6.19 |
254 | \fBgetcwd\fP(2) 2.2 | |
dc2f5549 | 255 | \fBgetdents\fP(2) 2.0 |
09de4bf1 | 256 | \fBgetdents64\fP(2) 2.4 |
8717e79e | 257 | \fBgetegid\fP(2) 1.0 |
09de4bf1 | 258 | \fBgetegid32\fP(2) 2.4 |
8717e79e | 259 | \fBgeteuid\fP(2) 1.0 |
09de4bf1 | 260 | \fBgeteuid32\fP(2) 2.4 |
8717e79e | 261 | \fBgetgid\fP(2) 1.0 |
09de4bf1 | 262 | \fBgetgid32\fP(2) 2.4 |
8717e79e | 263 | \fBgetgroups\fP(2) 1.0 |
09de4bf1 | 264 | \fBgetgroups32\fP(2) 2.4 |
8717e79e MK |
265 | \fBgetitimer\fP(2) 1.0 |
266 | \fBgetpeername\fP(2) 2.0 See notes on \fBsocketcall\fP(2) | |
929f1ff7 | 267 | \fBgetpagesize\fP(2) 2.0 Not on x86 |
8717e79e MK |
268 | \fBgetpgid\fP(2) 1.0 |
269 | \fBgetpgrp\fP(2) 1.0 | |
270 | \fBgetpid\fP(2) 1.0 | |
271 | \fBgetppid\fP(2) 1.0 | |
272 | \fBgetpriority\fP(2) 1.0 | |
09de4bf1 MK |
273 | \fBgetresgid\fP(2) 2.2 |
274 | \fBgetresgid32\fP(2) 2.4 | |
275 | \fBgetresuid\fP(2) 2.2 | |
276 | \fBgetresuid32\fP(2) 2.4 | |
8717e79e MK |
277 | \fBgetrlimit\fP(2) 1.0 |
278 | \fBgetrusage\fP(2) 1.0 | |
dc2f5549 | 279 | \fBgetsid\fP(2) 2.0 |
8717e79e MK |
280 | \fBgetsockname\fP(2) 2.0 See notes on \fBsocketcall\fP(2) |
281 | \fBgetsockopt\fP(2) 2.0 See notes on \fBsocketcall\fP(2) | |
09de4bf1 | 282 | \fBgettid\fP(2) 2.4.11 |
8717e79e MK |
283 | \fBgettimeofday\fP(2) 1.0 |
284 | \fBgetuid\fP(2) 1.0 | |
09de4bf1 | 285 | \fBgetuid32\fP(2) 2.4 |
018991f6 | 286 | .\" \fBgetunwind\fP(2) 2.4.8 ia64; DEPRECATED |
09de4bf1 | 287 | \fBgetxattr\fP(2) 2.6; 2.4.18 |
8717e79e | 288 | \fBinit_module\fP(2) 1.0 |
09de4bf1 MK |
289 | \fBinotify_add_watch\fP(2) 2.6.13 |
290 | \fBinotify_init\fP(2) 2.6.13 | |
eb153420 | 291 | \fBinotify_init1\fP(2) 2.6.27 |
09de4bf1 | 292 | \fBinotify_rm_watch\fP(2) 2.6.13 |
30fa088c MK |
293 | \fBio_cancel\fP(2) 2.6 |
294 | \fBio_destroy\fP(2) 2.6 | |
295 | \fBio_getevents\fP(2) 2.6 | |
296 | \fBio_setup\fP(2) 2.6 | |
297 | \fBio_submit\fP(2) 2.6 | |
8717e79e MK |
298 | \fBioctl\fP(2) 1.0 |
299 | \fBioperm\fP(2) 1.0 | |
300 | \fBiopl\fP(2) 1.0 | |
09de4bf1 MK |
301 | \fBioprio_get\fP(2) 2.6.13 |
302 | \fBioprio_set\fP(2) 2.6.13 | |
8717e79e | 303 | \fBipc\fP(2) 1.0 |
7d50a840 | 304 | .\" Implements System V IPC calls |
8eec4a23 | 305 | \fBkcmp\fP(2) 3.5 |
29cb9035 | 306 | \fBkern_features\fP(2) 3.7 Sparc64 |
38291c52 MK |
307 | .\" FIXME: document kern_features(): |
308 | .\" commit 517ffce4e1a03aea979fe3a18a3dd1761a24fafb | |
3ed3a507 MK |
309 | \fBkexec_load\fP(2) 2.6.13 |
310 | .\" The entry in the syscall table was reserved starting in 2.6.7 | |
7d50a840 | 311 | .\" Was named sys_kexec_load() from 2.6.7 to 2.6.16 |
09de4bf1 | 312 | \fBkeyctl\fP(2) 2.6.11 |
8717e79e MK |
313 | \fBkill\fP(2) 1.0 |
314 | \fBlchown\fP(2) 1.0 T{ | |
b6bc918e MK |
315 | See \fBchown\fP(2) for |
316 | .br | |
317 | version details | |
8717e79e | 318 | T} |
09de4bf1 MK |
319 | \fBlchown32\fP(2) 2.4 |
320 | \fBlgetxattr\fP(2) 2.6; 2.4.18 | |
8717e79e | 321 | \fBlink\fP(2) 1.0 |
09de4bf1 | 322 | \fBlinkat\fP(2) 2.6.16 |
8717e79e | 323 | \fBlisten\fP(2) 2.0 See notes on \fBsocketcall\fP(2) |
09de4bf1 MK |
324 | \fBlistxattr\fP(2) 2.6; 2.4.18 |
325 | \fBllistxattr\fP(2) 2.6; 2.4.18 | |
09de4bf1 MK |
326 | \fBlookup_dcookie\fP(2) 2.6 |
327 | \fBlremovexattr\fP(2) 2.6; 2.4.18 | |
8717e79e | 328 | \fBlseek\fP(2) 1.0 |
09de4bf1 | 329 | \fBlsetxattr\fP(2) 2.6; 2.4.18 |
8717e79e | 330 | \fBlstat\fP(2) 1.0 |
09de4bf1 MK |
331 | \fBlstat64\fP(2) 2.4 |
332 | \fBmadvise\fP(2) 2.4 | |
09de4bf1 MK |
333 | \fBmbind\fP(2) 2.6.6 |
334 | .\" \fBmemory_ordering\fP(2) ??? Sparc64 | |
335 | \fBmigrate_pages\fP(2) 2.6.16 | |
336 | \fBmincore\fP(2) 2.4 | |
8717e79e | 337 | \fBmkdir\fP(2) 1.0 |
09de4bf1 | 338 | \fBmkdirat\fP(2) 2.6.16 |
8717e79e | 339 | \fBmknod\fP(2) 1.0 |
09de4bf1 | 340 | \fBmknodat\fP(2) 2.6.16 |
8717e79e MK |
341 | \fBmlock\fP(2) 2.0 |
342 | \fBmlockall\fP(2) 2.0 | |
343 | \fBmmap\fP(2) 1.0 | |
09de4bf1 | 344 | \fBmmap2\fP(2) 2.4 |
8717e79e MK |
345 | \fBmodify_ldt\fP(2) 1.0 |
346 | \fBmount\fP(2) 1.0 | |
09de4bf1 | 347 | \fBmove_pages\fP(2) 2.6.18 |
8717e79e | 348 | \fBmprotect\fP(2) 1.0 |
7d50a840 MK |
349 | \fBmq_getsetattr\fP(2) 2.6.6 |
350 | .\" Implements \fBmq_getattr\fP(3) and \fBmq_setattr\fP(3) | |
09de4bf1 MK |
351 | \fBmq_notify\fP(2) 2.6.6 |
352 | \fBmq_open\fP(2) 2.6.6 | |
353 | \fBmq_timedreceive\fP(2) 2.6.6 | |
354 | \fBmq_timedsend\fP(2) 2.6.6 | |
8717e79e | 355 | \fBmq_unlink\fP(2) 2.6.6 |
dc2f5549 | 356 | \fBmremap\fP(2) 2.0 |
8717e79e MK |
357 | \fBmsgctl\fP(2) 2.0 See notes on \fBipc\fP(2) |
358 | \fBmsgget\fP(2) 2.0 See notes on \fBipc\fP(2) | |
359 | \fBmsgrcv\fP(2) 2.0 See notes on \fBipc\fP(2) | |
360 | \fBmsgsnd\fP(2) 2.0 See notes on \fBipc\fP(2) | |
dc2f5549 | 361 | \fBmsync\fP(2) 2.0 |
af4c9a82 MK |
362 | .\" \fBmultiplexer\fP(2) ?? __NR_multiplexer reserved on |
363 | .\" PowerPC, but unimplemented? | |
8717e79e MK |
364 | \fBmunlock\fP(2) 2.0 |
365 | \fBmunlockall\fP(2) 2.0 | |
366 | \fBmunmap\fP(2) 1.0 | |
b9cad55b | 367 | \fBname_to_handle_at\fP(2) 2.6.39 |
dc2f5549 | 368 | \fBnanosleep\fP(2) 2.0 |
18a97acf | 369 | \fBnfsservctl\fP(2) 2.2 Removed in 3.1 |
8717e79e MK |
370 | \fBnice\fP(2) 1.0 |
371 | \fBoldfstat\fP(2) 1.0 | |
372 | \fBoldlstat\fP(2) 1.0 | |
373 | \fBoldolduname\fP(2) 1.0 | |
374 | \fBoldstat\fP(2) 1.0 | |
375 | \fBolduname\fP(2) 1.0 | |
376 | \fBopen\fP(2) 1.0 | |
b9cad55b | 377 | \fBopen_by_handle_at\fP(2) 2.6.39 |
09de4bf1 | 378 | \fBopenat\fP(2) 2.6.16 |
8717e79e | 379 | \fBpause\fP(2) 1.0 |
929f1ff7 MK |
380 | \fBpciconfig_iobase\fP(2) 2.2.15; 2.4 Not on x86 |
381 | .\" Alpha, PowerPC, ARM; not x86 | |
382 | \fBpciconfig_read\fP(2) 2.0.26; 2.2 Not on x86 | |
383 | .\" , PowerPC, ARM; not x86 | |
384 | \fBpciconfig_write\fP(2) 2.0.26; 2.2 Not on x86 | |
385 | .\" , PowerPC, ARM; not x86 | |
56f2caff | 386 | \fBperf_event_open\fP(2) 2.6.31 T{ |
b6bc918e MK |
387 | Was called perf_counter_open() |
388 | .br | |
389 | in 2.6.31; renamed in 2.6.32 | |
56f2caff | 390 | T} |
dc2f5549 | 391 | \fBpersonality\fP(2) 1.2 |
7ddff6a4 MK |
392 | \fBperfctr\fP(2) 2.2 Sparc; removed in 2.6.34 |
393 | .\" commit c7d5a0050773e98d1094eaa9f2a1a793fafac300 removed perfctr() | |
3d1761ac | 394 | \fBperfmonctl\fP(2) 2.4 ia64 |
8717e79e | 395 | \fBpipe\fP(2) 1.0 |
eb153420 | 396 | \fBpipe2\fP(2) 2.6.27 |
dc2f5549 | 397 | \fBpivot_root\fP(2) 2.4 |
8717e79e | 398 | \fBpoll\fP(2) 2.0.36; 2.2 |
c071b8e0 | 399 | \fBppc_rtas\fP(2) PowerPC only |
09de4bf1 MK |
400 | \fBppoll\fP(2) 2.6.16 |
401 | \fBprctl\fP(2) 2.2 | |
56f2caff | 402 | \fBpread64\fP(2) T{ |
b6bc918e MK |
403 | Added as "pread" in 2.2; |
404 | .br | |
405 | renamed "pread64" in 2.6 | |
56f2caff | 406 | T} |
0877a26b | 407 | \fBpreadv\fP(2) 2.6.30 |
940795c0 | 408 | \fBprlimit\fP(2) 2.6.36 |
f06f5014 DP |
409 | \fBprocess_vm_readv\fP(2) 3.2 |
410 | \fBprocess_vm_writev\fP(2) 3.2 | |
7d50a840 MK |
411 | \fBpselect6\fP(2) 2.6.16 |
412 | .\" Implements \fBpselect\fP(2) | |
8717e79e | 413 | \fBptrace\fP(2) 1.0 |
56f2caff | 414 | \fBpwrite64\fP(2) T{ |
b6bc918e MK |
415 | Added as "pwrite" in 2.2; |
416 | .br | |
417 | renamed "pwrite64" in 2.6 | |
56f2caff | 418 | T} |
0877a26b | 419 | \fBpwritev\fP(2) 2.6.30 |
13f66890 | 420 | \fBquery_module\fP(2) 2.2 Removed in 2.6 |
8717e79e MK |
421 | \fBquotactl\fP(2) 1.0 |
422 | \fBread\fP(2) 1.0 | |
09de4bf1 | 423 | \fBreadahead\fP(2) 2.4.13 |
8717e79e | 424 | \fBreaddir\fP(2) 1.0 |
7d50a840 | 425 | .\" Supersedes \fBgetdents\fP(2) |
8717e79e | 426 | \fBreadlink\fP(2) 1.0 |
09de4bf1 | 427 | \fBreadlinkat\fP(2) 2.6.16 |
dc2f5549 | 428 | \fBreadv\fP(2) 2.0 |
8717e79e MK |
429 | \fBreboot\fP(2) 1.0 |
430 | \fBrecv\fP(2) 2.0 See notes on \fBsocketcall\fP(2) | |
431 | \fBrecvfrom\fP(2) 2.0 See notes on \fBsocketcall\fP(2) | |
432 | \fBrecvmsg\fP(2) 2.0 See notes on \fBsocketcall\fP(2) | |
285bf67e | 433 | \fBrecvmmsg\fP(2) 2.6.33 |
09de4bf1 MK |
434 | \fBremap_file_pages\fP(2) 2.6 |
435 | \fBremovexattr\fP(2) 2.6; 2.4.18 | |
8717e79e | 436 | \fBrename\fP(2) 1.0 |
09de4bf1 | 437 | \fBrenameat\fP(2) 2.6.16 |
bf253d9b | 438 | \fBrenameat2\fP(2) 3.15 |
09de4bf1 MK |
439 | \fBrequest_key\fP(2) 2.6.11 |
440 | \fBrestart_syscall\fP(2) 2.6 | |
8717e79e | 441 | \fBrmdir\fP(2) 1.0 |
09de4bf1 MK |
442 | \fBrt_sigaction\fP(2) 2.2 |
443 | \fBrt_sigpending\fP(2) 2.2 | |
444 | \fBrt_sigprocmask\fP(2) 2.2 | |
7d50a840 | 445 | \fBrt_sigqueueinfo\fP(2) 2.2 |
09de4bf1 MK |
446 | \fBrt_sigreturn\fP(2) 2.2 |
447 | \fBrt_sigsuspend\fP(2) 2.2 | |
448 | \fBrt_sigtimedwait\fP(2) 2.2 | |
285bf67e | 449 | \fBrt_tgsigqueueinfo\fP(2) 2.6.31 |
993d1ce3 | 450 | \fBs390_runtime_instr\fP(2) 3.7 s390 only |
dc2f5549 MK |
451 | \fBsched_get_priority_max\fP(2) 2.0 |
452 | \fBsched_get_priority_min\fP(2) 2.0 | |
30fa088c | 453 | \fBsched_getaffinity\fP(2) 2.6 |
70415818 | 454 | \fBsched_getattr\fP(2) 3.14 |
dc2f5549 MK |
455 | \fBsched_getparam\fP(2) 2.0 |
456 | \fBsched_getscheduler\fP(2) 2.0 | |
457 | \fBsched_rr_get_interval\fP(2) 2.0 | |
30fa088c | 458 | \fBsched_setaffinity\fP(2) 2.6 |
70415818 | 459 | \fBsched_setattr\fP(2) 3.14 |
dc2f5549 MK |
460 | \fBsched_setparam\fP(2) 2.0 |
461 | \fBsched_setscheduler\fP(2) 2.0 | |
462 | \fBsched_yield\fP(2) 2.0 | |
8717e79e MK |
463 | \fBselect\fP(2) 1.0 |
464 | \fBsemctl\fP(2) 2.0 See notes on \fBipc\fP(2) | |
465 | \fBsemget\fP(2) 2.0 See notes on \fBipc\fP(2) | |
466 | \fBsemop\fP(2) 2.0 See notes on \fBipc\fP(2) | |
09de4bf1 | 467 | \fBsemtimedop\fP(2) 2.6; 2.4.22 |
8717e79e | 468 | \fBsend\fP(2) 2.0 See notes on \fBsocketcall\fP(2) |
09de4bf1 MK |
469 | \fBsendfile\fP(2) 2.2 |
470 | \fBsendfile64\fP(2) 2.6; 2.4.19 | |
3e55b0bd | 471 | \fBsendmmsg\fP(2) 3.0 |
8717e79e MK |
472 | \fBsendmsg\fP(2) 2.0 See notes on \fBsocketcall\fP(2) |
473 | \fBsendto\fP(2) 2.0 See notes on \fBsocketcall\fP(2) | |
09de4bf1 MK |
474 | \fBset_mempolicy\fP(2) 2.6.6 |
475 | \fBset_robust_list\fP(2) 2.6.17 | |
30fa088c | 476 | \fBset_thread_area\fP(2) 2.6 |
09de4bf1 | 477 | \fBset_tid_address\fP(2) 2.6 |
9947a8d7 MK |
478 | .\" See http://lkml.org/lkml/2005/8/1/83 |
479 | .\" "[PATCH] remove sys_set_zone_reclaim()" | |
8717e79e | 480 | \fBsetdomainname\fP(2) 1.0 |
dc2f5549 | 481 | \fBsetfsgid\fP(2) 1.2 |
09de4bf1 | 482 | \fBsetfsgid32\fP(2) 2.4 |
dc2f5549 | 483 | \fBsetfsuid\fP(2) 1.2 |
09de4bf1 | 484 | \fBsetfsuid32\fP(2) 2.4 |
8717e79e | 485 | \fBsetgid\fP(2) 1.0 |
09de4bf1 | 486 | \fBsetgid32\fP(2) 2.4 |
8717e79e | 487 | \fBsetgroups\fP(2) 1.0 |
09de4bf1 | 488 | \fBsetgroups32\fP(2) 2.4 |
8717e79e MK |
489 | \fBsethostname\fP(2) 1.0 |
490 | \fBsetitimer\fP(2) 1.0 | |
3e55b0bd | 491 | \fBsetns\fP(2) 3.0 |
8717e79e MK |
492 | \fBsetpgid\fP(2) 1.0 |
493 | \fBsetpriority\fP(2) 1.0 | |
494 | \fBsetregid\fP(2) 1.0 | |
09de4bf1 MK |
495 | \fBsetregid32\fP(2) 2.4 |
496 | \fBsetresgid\fP(2) 2.2 | |
497 | \fBsetresgid32\fP(2) 2.4 | |
498 | \fBsetresuid\fP(2) 2.2 | |
499 | \fBsetresuid32\fP(2) 2.4 | |
8717e79e | 500 | \fBsetreuid\fP(2) 1.0 |
09de4bf1 | 501 | \fBsetreuid32\fP(2) 2.4 |
8717e79e MK |
502 | \fBsetrlimit\fP(2) 1.0 |
503 | \fBsetsid\fP(2) 1.0 | |
504 | \fBsetsockopt\fP(2) 2.0 See notes on \fBsocketcall\fP(2) | |
505 | \fBsettimeofday\fP(2) 1.0 | |
506 | \fBsetuid\fP(2) 1.0 | |
09de4bf1 MK |
507 | \fBsetuid32\fP(2) 2.4 |
508 | \fBsetup\fP(2) Removed in 2.2 | |
509 | \fBsetxattr\fP(2) 2.6; 2.4.18 | |
8717e79e MK |
510 | \fBsgetmask\fP(2) 1.0 |
511 | \fBshmat\fP(2) 2.0 See notes on \fBipc\fP(2) | |
512 | \fBshmctl\fP(2) 2.0 See notes on \fBipc\fP(2) | |
513 | \fBshmdt\fP(2) 2.0 See notes on \fBipc\fP(2) | |
514 | \fBshmget\fP(2) 2.0 See notes on \fBipc\fP(2) | |
515 | \fBshutdown\fP(2) 2.0 See notes on \fBsocketcall\fP(2) | |
516 | \fBsigaction\fP(2) 1.0 | |
09de4bf1 | 517 | \fBsigaltstack\fP(2) 2.2 |
8717e79e | 518 | \fBsignal\fP(2) 1.0 |
09de4bf1 | 519 | \fBsignalfd\fP(2) 2.6.22 |
eb153420 | 520 | \fBsignalfd4\fP(2) 2.6.27 |
8717e79e MK |
521 | \fBsigpending\fP(2) 1.0 |
522 | \fBsigprocmask\fP(2) 1.0 | |
523 | \fBsigreturn\fP(2) 1.0 | |
524 | \fBsigsuspend\fP(2) 1.0 | |
525 | \fBsocket\fP(2) 2.0 See notes on \fBsocketcall\fP(2) | |
526 | \fBsocketcall\fP(2) 1.0 | |
7d50a840 | 527 | .\" Implements BSD socket calls |
8717e79e | 528 | \fBsocketpair\fP(2) 2.0 See notes on \fBsocketcall\fP(2) |
09de4bf1 | 529 | \fBsplice\fP(2) 2.6.17 |
f9e4d811 MK |
530 | \fBspu_create\fP(2) 2.6.16 PowerPC only |
531 | \fBspu_run\fP(2) 2.6.16 PowerPC only | |
8717e79e MK |
532 | \fBssetmask\fP(2) 1.0 |
533 | \fBstat\fP(2) 1.0 | |
09de4bf1 | 534 | \fBstat64\fP(2) 2.4 |
8717e79e | 535 | \fBstatfs\fP(2) 1.0 |
09de4bf1 | 536 | \fBstatfs64\fP(2) 2.6 |
8717e79e | 537 | \fBstime\fP(2) 1.0 |
56f2caff BIG |
538 | \fBsubpage_prot\fP(2) 2.6.25 PowerPC if |
539 | CONFIG_PPC_64K_PAGES | |
8717e79e MK |
540 | \fBswapoff\fP(2) 1.0 |
541 | \fBswapon\fP(2) 1.0 | |
542 | \fBsymlink\fP(2) 1.0 | |
09de4bf1 | 543 | \fBsymlinkat\fP(2) 2.6.16 |
8717e79e | 544 | \fBsync\fP(2) 1.0 |
09de4bf1 | 545 | \fBsync_file_range\fP(2) 2.6.17 |
56f2caff | 546 | \fBsync_file_range2\fP(2) 2.6.22 T{ |
b6bc918e MK |
547 | Architecture-specific |
548 | variant of \fBsync_file_range\fP(2) | |
56f2caff | 549 | T} |
83225c1f MK |
550 | .\" PowerPC, ARM, tile |
551 | .\" First appeared on ARM, as arm_sync_file_range(), but later renamed | |
af4c9a82 | 552 | .\" \fBsys_debug_setcontext\fP(2) ??? PowerPC if CONFIG_PPC32 |
dc43a891 | 553 | \fBsyncfs\fP(2) 2.6.39 |
dc2f5549 | 554 | \fBsysfs\fP(2) 1.2 |
8717e79e MK |
555 | \fBsysinfo\fP(2) 1.0 |
556 | \fBsyslog\fP(2) 1.0 | |
7d50a840 | 557 | .\" glibc interface is \fBklogctl\fP(3) |
09de4bf1 MK |
558 | \fBtee\fP(2) 2.6.17 |
559 | \fBtgkill\fP(2) 2.6 | |
8717e79e | 560 | \fBtime\fP(2) 1.0 |
09de4bf1 MK |
561 | \fBtimer_create\fP(2) 2.6 |
562 | \fBtimer_delete\fP(2) 2.6 | |
563 | \fBtimer_getoverrun\fP(2) 2.6 | |
564 | \fBtimer_gettime\fP(2) 2.6 | |
565 | \fBtimer_settime\fP(2) 2.6 | |
0df29603 MK |
566 | \fBtimerfd_create\fP(2) 2.6.25 |
567 | \fBtimerfd_gettime\fP(2) 2.6.25 | |
568 | \fBtimerfd_settime\fP(2) 2.6.25 | |
8717e79e | 569 | \fBtimes\fP(2) 1.0 |
09de4bf1 | 570 | \fBtkill\fP(2) 2.6; 2.4.22 |
8717e79e | 571 | \fBtruncate\fP(2) 1.0 |
09de4bf1 MK |
572 | \fBtruncate64\fP(2) 2.4 |
573 | \fBugetrlimit\fP(2) 2.4 | |
8717e79e MK |
574 | \fBumask\fP(2) 1.0 |
575 | \fBumount\fP(2) 1.0 | |
09de4bf1 MK |
576 | .\" sys_oldumount() -- __NR_umount |
577 | \fBumount2\fP(2) 2.2 | |
578 | .\" sys_umount() -- __NR_umount2 | |
8717e79e MK |
579 | \fBuname\fP(2) 1.0 |
580 | \fBunlink\fP(2) 1.0 | |
09de4bf1 MK |
581 | \fBunlinkat\fP(2) 2.6.16 |
582 | \fBunshare\fP(2) 2.6.16 | |
8717e79e MK |
583 | \fBuselib\fP(2) 1.0 |
584 | \fBustat\fP(2) 1.0 | |
585 | \fButime\fP(2) 1.0 | |
09de4bf1 | 586 | \fButimensat\fP(2) 2.6.22 |
d3ea5e99 | 587 | \fButimes\fP(2) 2.2 |
823c799b | 588 | \fButrap_install\fP(2) 2.2 Sparc |
38291c52 MK |
589 | .\" FIXME: document utrap_install() |
590 | .\" There's a man page for Solaris 5.11 | |
8717e79e MK |
591 | \fBvfork\fP(2) 2.2 |
592 | \fBvhangup\fP(2) 1.0 | |
b6bc918e MK |
593 | \fBvm86old\fP(2) 1.0 T{ |
594 | Was "vm86"; renamed in | |
595 | 2.0.28/2.2 | |
596 | T} | |
8717e79e | 597 | \fBvm86\fP(2) 2.0.28; 2.2 |
09de4bf1 | 598 | \fBvmsplice\fP(2) 2.6.17 |
8717e79e | 599 | \fBwait4\fP(2) 1.0 |
09de4bf1 | 600 | \fBwaitid\fP(2) 2.6.10 |
8717e79e MK |
601 | \fBwaitpid\fP(2) 1.0 |
602 | \fBwrite\fP(2) 1.0 | |
dc2f5549 | 603 | \fBwritev\fP(2) 2.0 |
09de4bf1 | 604 | .TE |
56f2caff | 605 | .ad |
09de4bf1 | 606 | .PP |
929f1ff7 | 607 | On many platforms, including x86-32, socket calls are all multiplexed |
7d50a840 MK |
608 | (via glibc wrapper functions) through |
609 | .BR socketcall (2) | |
610 | and similarly System V IPC calls are multiplexed through | |
611 | .BR ipc (2). | |
0597933f | 612 | |
09de4bf1 | 613 | Although slots are reserved for them in the system call table, |
e0bf9127 | 614 | the following system calls are not implemented in the standard kernel: |
09de4bf1 MK |
615 | .BR afs_syscall (2), \" __NR_afs_syscall is 53 on Linux 2.6.22/i386 |
616 | .BR break (2), \" __NR_break is 17 on Linux 2.6.22/i386 | |
617 | .BR ftime (2), \" __NR_ftime is 35 on Linux 2.6.22/i386 | |
618 | .BR getpmsg (2), \" __NR_getpmsg is 188 on Linux 2.6.22/i386 | |
619 | .BR gtty (2), \" __NR_gtty is 32 on Linux 2.6.22/i386 | |
620 | .BR idle (2), \" __NR_idle is 112 on Linux 2.6.22/i386 | |
621 | .BR lock (2), \" __NR_lock is 53 on Linux 2.6.22/i386 | |
622 | .BR madvise1 (2), \" __NR_madvise1 is 219 on Linux 2.6.22/i386 | |
623 | .BR mpx (2), \" __NR_mpx is 66 on Linux 2.6.22/i386 | |
3b777aff | 624 | .BR phys (2), \" Slot has been reused |
09de4bf1 MK |
625 | .BR prof (2), \" __NR_prof is 44 on Linux 2.6.22/i386 |
626 | .BR profil (2), \" __NR_profil is 98 on Linux 2.6.22/i386 | |
627 | .BR putpmsg (2), \" __NR_putpmsg is 189 on Linux 2.6.22/i386 | |
f9e4d811 MK |
628 | .\" __NR_security is 223 on Linux 2.4/i386; absent on 2.6/i386, present |
629 | .\" on a couple of 2.6 architectures | |
630 | .BR security (2), \" __NR_security is 223 on Linux 2.4/i386 | |
0597933f | 631 | .\" The security call is for future use. |
09de4bf1 | 632 | .BR stty (2), \" __NR_stty is 31 on Linux 2.6.22/i386 |
af4c9a82 | 633 | .BR tuxcall (2), \" __NR_tuxcall is 184 on x86_64, also on PPC and alpha |
09de4bf1 MK |
634 | .BR ulimit (2), \" __NR_ulimit is 58 on Linux 2.6.22/i386 |
635 | and | |
636 | .BR vserver (2) \" __NR_vserver is 273 on Linux 2.6.22/i386 | |
fea681da | 637 | (see also |
fea681da MK |
638 | .BR unimplemented (2)). |
639 | However, | |
640 | .BR ftime (3), | |
641 | .BR profil (3) | |
642 | and | |
643 | .BR ulimit (3) | |
644 | exist as library routines. | |
09de4bf1 MK |
645 | The slot for |
646 | .BR phys (2) | |
647 | is in use since kernel 2.1.116 for | |
648 | .BR umount (2); | |
e0bf9127 | 649 | .BR phys (2) |
09de4bf1 | 650 | will never be implemented. |
09de4bf1 MK |
651 | The |
652 | .BR getpmsg (2) | |
653 | and | |
654 | .BR putpmsg (2) | |
655 | calls are for kernels patched to support STREAMS, | |
656 | and may never be in the standard kernel. | |
98309d3f MK |
657 | |
658 | There was briefly | |
659 | .BR set_zone_reclaim (2), | |
660 | added in Linux 2.6.13, and removed in 2.6.16; | |
7fac88a9 | 661 | this system call was never available to user space. |
0597933f | 662 | .SH NOTES |
09de4bf1 | 663 | .PP |
fea681da MK |
664 | Roughly speaking, the code belonging to the system call |
665 | with number __NR_xxx defined in | |
666 | .I /usr/include/asm/unistd.h | |
66a9882e | 667 | can be found in the Linux kernel source in the routine |
63aa9df0 | 668 | .IR sys_xxx (). |
fea681da MK |
669 | (The dispatch table for i386 can be found in |
670 | .IR /usr/src/linux/arch/i386/kernel/entry.S .) | |
671 | There are many exceptions, however, mostly because | |
672 | older system calls were superseded by newer ones, | |
c13182ef MK |
673 | and this has been treated somewhat unsystematically. |
674 | On platforms with | |
6c1544c1 | 675 | proprietary operating-system emulation, |
a797afac | 676 | such as parisc, sparc, sparc64, and alpha, |
fea681da MK |
677 | there are many additional system calls; mips64 also contains a full |
678 | set of 32-bit system calls. | |
fea681da | 679 | |
09de4bf1 MK |
680 | Over time, changes to the interfaces of some system calls have been |
681 | necessary. | |
682 | One reason for such changes was the need to increase the size of | |
683 | structures or scalar values passed to the system call. | |
7d50a840 MK |
684 | Because of these changes, there are now various groups |
685 | of related system calls | |
686 | (e.g., | |
687 | .BR truncate (2) | |
688 | and | |
e04e8187 | 689 | .BR truncate64 (2)) |
7d50a840 MK |
690 | which perform similar tasks, but which vary in |
691 | details such as the size of their arguments. | |
692 | (As noted earlier, applications are generally unaware of this: | |
693 | the glibc wrapper functions do some work to ensure that the right | |
694 | system call is invoked, and that ABI compatibility is | |
695 | preserved for old binaries.) | |
09de4bf1 MK |
696 | Examples of systems calls that exist in multiple versions are |
697 | the following: | |
698 | .IP * 3 | |
7d50a840 | 699 | By now there are three different versions of |
09de4bf1 MK |
700 | .BR stat (2): |
701 | .IR sys_stat () | |
702 | (slot | |
703 | .IR __NR_oldstat ), | |
704 | .IR sys_newstat () | |
705 | (slot | |
706 | .IR __NR_stat ), | |
fea681da | 707 | and |
92a5f983 | 708 | .IR sys_stat64 () |
09de4bf1 MK |
709 | (slot |
710 | .IR __NR_stat64 ), | |
711 | with the last being the most current. | |
f9e4d811 | 712 | .\" e.g., on 2.6.22/i386: __NR_oldstat 18, __NR_stat 106, __NR_stat64 195 |
09de4bf1 MK |
713 | .\" The stat system calls deal with three different data structures, |
714 | .\" defined in include/asm-i386/stat.h: __old_kernel_stat, stat, stat64 | |
715 | A similar story applies for | |
716 | .BR lstat (2) | |
717 | and | |
718 | .BR fstat (2). | |
719 | .IP * | |
720 | Similarly, the defines | |
721 | .IR __NR_oldolduname , | |
722 | .IR __NR_olduname , | |
723 | and | |
0daa9e92 | 724 | .I __NR_uname |
09de4bf1 MK |
725 | refer to the routines |
726 | .IR sys_olduname (), | |
727 | .IR sys_uname () | |
728 | and | |
729 | .IR sys_newuname (). | |
730 | .IP * | |
7d50a840 | 731 | In Linux 2.0, a new version of |
09de4bf1 MK |
732 | .BR vm86 (2) |
733 | appeared, with the old and the new kernel routines being named | |
734 | .IR sys_vm86old () | |
735 | and | |
736 | .IR sys_vm86 (). | |
737 | .IP * | |
7d50a840 | 738 | In Linux 2.4, a new version of |
09de4bf1 MK |
739 | .BR getrlimit (2) |
740 | appeared, with the old and the new kernel routines being named | |
741 | .IR sys_old_getrlimit () | |
742 | (slot | |
743 | .IR __NR_getrlimit ) | |
744 | and | |
745 | .IR sys_getrlimit () | |
746 | (slot | |
747 | .IR __NR_ugetrlimit ). | |
748 | .IP * | |
749 | Linux 2.4 increased the size of user and group IDs from 16 to 32 bits. | |
5024580d | 750 | .\" 64-bit off_t changes: ftruncate64, *stat64, |
09de4bf1 MK |
751 | .\" fcntl64 (because of the flock structure), getdents64, *statfs64 |
752 | To support this change, a range of system calls were added | |
753 | (e.g., | |
754 | .BR chown32 (2), | |
755 | .BR getuid32 (2), | |
756 | .BR getgroups32 (2), | |
757 | .BR setresuid32 (2)), | |
758 | superseding earlier calls of the same name without the | |
759 | "32" suffix. | |
760 | .IP * | |
761 | Linux 2.4 added support for applications on 32-bit architectures | |
762 | to access large files (i.e., files for which the sizes and | |
763 | file offsets can't be represented in 32 bits.) | |
764 | To support this change, replacements were required for system calls | |
765 | that deal with file offsets and sizes. | |
766 | Thus the following system calls were added: | |
767 | .BR fcntl64 (2), | |
768 | .BR ftruncate64 (2), | |
769 | .BR getdents64 (2), | |
770 | .BR stat64 (2), | |
771 | .BR statfs64 (2), | |
772 | and their analogs that work with file descriptors or | |
773 | symbolic links. | |
774 | These system calls supersede the older system calls | |
775 | which, except in the case of the "stat" calls, | |
776 | have the same name without the "64" suffix. | |
ca92ce95 | 777 | |
09de4bf1 MK |
778 | On newer platforms that only have 64-bit file access and 32-bit uids |
779 | (e.g., alpha, ia64, s390x) there are no *64 or *32 calls. | |
780 | Where the *64 and *32 calls exist, the other versions are obsolete. | |
781 | .IP * | |
782 | The | |
783 | .I rt_sig* | |
784 | calls were added in kernel 2.2 to support the addition | |
785 | of real-time signals (see | |
786 | .BR signal (7)). | |
787 | These system calls supersede the older system calls of the same | |
788 | name without the "rt_" prefix. | |
789 | .IP * | |
7d50a840 MK |
790 | The |
791 | .BR select (2) | |
fea681da | 792 | and |
7d50a840 | 793 | .BR mmap (2) |
c4bb193f | 794 | system calls use five or more arguments, |
208088b5 | 795 | which caused problems in the way |
c4bb193f | 796 | argument passing on the i386 used to be set up. |
7d50a840 | 797 | Thus, while other architectures have |
09de4bf1 MK |
798 | .IR sys_select () |
799 | and | |
800 | .IR sys_mmap () | |
801 | corresponding to | |
0daa9e92 | 802 | .I __NR_select |
09de4bf1 MK |
803 | and |
804 | .IR __NR_mmap , | |
805 | on i386 one finds | |
806 | .IR old_select () | |
807 | and | |
808 | .IR old_mmap () | |
809 | (routines that use a pointer to a | |
c4bb193f MK |
810 | argument block) instead. |
811 | These days passing five arguments | |
09de4bf1 | 812 | is not a problem any more, and there is a |
0daa9e92 | 813 | .I __NR__newselect |
7d50a840 MK |
814 | .\" (used by libc 6) |
815 | that corresponds directly to | |
09de4bf1 MK |
816 | .IR sys_select () |
817 | and similarly | |
7d50a840 MK |
818 | .IR __NR_mmap2 . |
819 | .\" .PP | |
820 | .\" Two system call numbers, | |
821 | .\" .IR __NR__llseek | |
822 | .\" and | |
823 | .\" .IR __NR__sysctl | |
824 | .\" have an additional underscore absent in | |
825 | .\" .IR sys_llseek () | |
826 | .\" and | |
827 | .\" .IR sys_sysctl (). | |
e0bf9127 | 828 | .\" |
7d50a840 MK |
829 | .\" In kernel 2.1.81, |
830 | .\" .BR lchown (2) | |
e0bf9127 | 831 | .\" and |
7d50a840 MK |
832 | .\" .BR chown (2) |
833 | .\" were swapped; that is, | |
834 | .\" .BR lchown (2) | |
835 | .\" was added with the semantics that were then current for | |
836 | .\" .BR chown (2), | |
837 | .\" and the semantics of the latter call were changed to what | |
838 | .\" they are today. | |
09de4bf1 | 839 | .SH SEE ALSO |
b73bf0ae | 840 | .BR intro (2), |
09de4bf1 | 841 | .BR syscall (2), |
de9ed3a3 | 842 | .BR unimplemented (2), |
951ae9c0 MF |
843 | .BR libc (7), |
844 | .BR vdso (7) |