All of lore.kernel.org
 help / color / mirror / Atom feed
From: Alejandro Colomar <alx@kernel.org>
To: linux-man@vger.kernel.org
Cc: Alejandro Colomar <alx@kernel.org>,
	 Florian Weimer <fweimer@redhat.com>,
	Carlos O'Donell <carlos@redhat.com>
Subject: [PATCH 1/2] process_madvise.2: Document the glibc wrapper
Date: Sun, 25 Feb 2024 13:23:22 +0100	[thread overview]
Message-ID: <20240225122250.441157-2-alx@kernel.org> (raw)

[-- Attachment #1: Type: text/plain, Size: 1847 bytes --]

$ grepc -n process_madvise /usr/include/
/usr/include/x86_64-linux-gnu/bits/mman_ext.h:25:
extern __ssize_t process_madvise (int __pid_fd, const struct iovec *__iov,
				  size_t __count, int __advice,
				  unsigned __flags)
  __THROW;

Reported-by: Florian Weimer <fweimer@redhat.com>
Cc: Carlos O'Donell <carlos@redhat.com>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
---
 man2/process_madvise.2 | 20 +++++---------------
 1 file changed, 5 insertions(+), 15 deletions(-)

diff --git a/man2/process_madvise.2 b/man2/process_madvise.2
index 53fd57598..ed8739663 100644
--- a/man2/process_madvise.2
+++ b/man2/process_madvise.2
@@ -13,23 +13,12 @@ .SH LIBRARY
 .RI ( libc ", " \-lc )
 .SH SYNOPSIS
 .nf
-.BR "#include <sys/mman.h>" "      /* Definition of " MADV_* " constants */"
-.BR "#include <sys/syscall.h>" "   /* Definition of " SYS_* " constants */"
-.BR "#include <sys/uio.h>" "       /* Definition of " "struct iovec" " type */"
-.B #include <unistd.h>
+.B #include <sys/mman.h>
 .P
-.BI "ssize_t syscall(SYS_process_madvise, int " pidfd ,
-.BI "                const struct iovec *" iovec ", size_t " vlen \
-", int " advice ,
-.BI "                unsigned int " flags ");"
+.BI "ssize_t process_madvise(int " pidfd ", const struct iovec *" iovec ,
+.BI "                        size_t " vlen ", int " advice \
+", unsigned int " flags );
 .fi
-.P
-.IR Note :
-glibc provides no wrapper for
-.BR process_madvise (),
-necessitating the use of
-.BR syscall (2).
-.\" FIXME: See <https://sourceware.org/bugzilla/show_bug.cgi?id=27380>
 .SH DESCRIPTION
 The
 .BR process_madvise ()
@@ -187,6 +176,7 @@ .SH STANDARDS
 Linux.
 .SH HISTORY
 Linux 5.10.
+glibc 2.36.
 .\" commit ecb8ac8b1f146915aa6b96449b66dd48984caacc
 .P
 Support for this system call is optional,
-- 
2.43.0


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

             reply	other threads:[~2024-02-25 12:23 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-25 12:23 Alejandro Colomar [this message]
2024-02-25 12:23 ` [PATCH 2/2] process_madvise.2: Rename parameter, and use array syntax Alejandro Colomar
2024-02-27 22:16 ` [PATCH 1/2] process_madvise.2: Document the glibc wrapper Guillem Jover
2024-02-27 23:14   ` Alejandro Colomar

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240225122250.441157-2-alx@kernel.org \
    --to=alx@kernel.org \
    --cc=carlos@redhat.com \
    --cc=fweimer@redhat.com \
    --cc=linux-man@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.