]> git.ipfire.org Git - thirdparty/man-pages.git/blame - man2/delete_module.2
sync
[thirdparty/man-pages.git] / man2 / delete_module.2
CommitLineData
c4d4162c
MK
1.\" Copyright (C) 1996 Free Software Foundation, Inc.
2.\" This file is distributed according to the GNU General Public License.
3.\" See the file COPYING in the top level source directory for details.
4.\"
5.\" 2006-02-09, some reformatting by Luc Van Oostenryck; some
6.\" reformatting and rewordings by mtk
7.\"
8.TH DELETE_MODULE 2 "2002" Linux "Linux Module Support"
9.SH NAME
10delete_module \- delete a loadable module entry
11.SH SYNOPSIS
12.nf
13.B #include <linux/module.h>
14.sp
15.BI "int delete_module(const char *" name );
16.fi
17.SH DESCRIPTION
18.BR delete_module ()
19attempts to remove an unused loadable module entry.
20If
21.I name
22is NULL,
23all unused modules marked auto-clean will be removed.
24This system call requires privilege.
25.SH "RETURN VALUE"
26On success, zero is returned. On error, \-1 is returned and
27.I errno
28is set appropriately.
29.SH ERRORS
30.TP
31.B EBUSY
32The module is in use.
33.TP
34.B EFAULT
35.I name
36is outside the program's accessible address space.
37.TP
38.B EINVAL
39.I name
40was an empty string.
41.TP
42.B ENOENT
43No module by that name exists.
44.TP
45.B EPERM
46The caller was not privileged
47(did not have the
48.B CAP_SYS_MODULE
49capability).
50.SH "CONFORMING TO"
51.BR delete_module ()
52is Linux specific.
53.SH "SEE ALSO"
54.BR create_module (2),
55.BR init_module (2),
56.BR query_module (2)