* [PATCH] delete_module.2: SYNOPSIS: Fix prototype parameter types
@ 2020-12-30 21:41 Alejandro Colomar
2020-12-30 22:36 ` Michael Kerrisk (man-pages)
0 siblings, 1 reply; 2+ messages in thread
From: Alejandro Colomar @ 2020-12-30 21:41 UTC (permalink / raw)
To: mtk.manpages; +Cc: Alejandro Colomar, linux-man
The Linux kernel uses 'unsigned int' instead of 'int' for the
'flags' parameter. As glibc provides no wrapper, use the same
type the kernel uses.
......
$ syscall='delete_module';
$ find linux/ -type f -name '*.c' \
|xargs pcregrep -Mn "(?s)^[\w_]*SYSCALL_DEFINE.\(${syscall},.*?\)";
linux/kernel/module.c:977:
SYSCALL_DEFINE2(delete_module, const char __user *, name_user,
unsigned int, flags)
Signed-off-by: Alejandro Colomar <alx.manpages@gmail.com>
---
man2/delete_module.2 | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/man2/delete_module.2 b/man2/delete_module.2
index e63545d51..1030e9698 100644
--- a/man2/delete_module.2
+++ b/man2/delete_module.2
@@ -27,7 +27,7 @@
delete_module \- unload a kernel module
.SH SYNOPSIS
.nf
-.BI "int delete_module(const char *" name ", int " flags );
+.BI "int delete_module(const char *" name ", unsigned int " flags );
.fi
.PP
.IR Note :
--
2.29.2
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] delete_module.2: SYNOPSIS: Fix prototype parameter types
2020-12-30 21:41 [PATCH] delete_module.2: SYNOPSIS: Fix prototype parameter types Alejandro Colomar
@ 2020-12-30 22:36 ` Michael Kerrisk (man-pages)
0 siblings, 0 replies; 2+ messages in thread
From: Michael Kerrisk (man-pages) @ 2020-12-30 22:36 UTC (permalink / raw)
To: Alejandro Colomar; +Cc: mtk.manpages, linux-man
Hi ALex,
On 12/30/20 10:41 PM, Alejandro Colomar wrote:
> The Linux kernel uses 'unsigned int' instead of 'int' for the
> 'flags' parameter. As glibc provides no wrapper, use the same
> type the kernel uses> ......
>
> $ syscall='delete_module';
> $ find linux/ -type f -name '*.c' \
> |xargs pcregrep -Mn "(?s)^[\w_]*SYSCALL_DEFINE.\(${syscall},.*?\)";
> linux/kernel/module.c:977:
> SYSCALL_DEFINE2(delete_module, const char __user *, name_user,
> unsigned int, flags)
>
> Signed-off-by: Alejandro Colomar <alx.manpages@gmail.com>
Thanks. Patch applied.
Cheers,
Michael
> ---
> man2/delete_module.2 | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/man2/delete_module.2 b/man2/delete_module.2
> index e63545d51..1030e9698 100644
> --- a/man2/delete_module.2
> +++ b/man2/delete_module.2
> @@ -27,7 +27,7 @@
> delete_module \- unload a kernel module
> .SH SYNOPSIS
> .nf
> -.BI "int delete_module(const char *" name ", int " flags );
> +.BI "int delete_module(const char *" name ", unsigned int " flags );
> .fi
> .PP
> .IR Note :
>
--
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
Linux/UNIX System Programming Training: http://man7.org/training/
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-12-30 22:37 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-12-30 21:41 [PATCH] delete_module.2: SYNOPSIS: Fix prototype parameter types Alejandro Colomar
2020-12-30 22:36 ` Michael Kerrisk (man-pages)
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox