Skip to contentSkip to conversation

mmap.2: fix missing text

PATCH Superseded Avinesh Kumar 2 participants 6 messages Aug 25, 2023 – Aug 29, 2023 Man-pages: manual pages for Linux -- Sections 2, 3, 4, 5, and 7

v1 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 mmap.2: fix missing text

---
 man2/mmap.2 | 1 +
 1 file changed, 1 insertion(+)
man2/mmap.2 +1 -0
index d0530be0f..9de6b2796 100644
@@ -629,6 +629,7 @@ and is not a member of the
 group; see the description of
 .I /proc/sys/vm/sysctl_hugetlb_shm_group
 in
+.BR proc (5).
 .TP
 .B ETXTBSY
 .B MAP_DENYWRITE
Signature · 1 line
2.41.0
#1 lore raw

Hi Avinesh,

Quoted 10 lines · Avinesh Kumar
---
 man2/mmap.2 | 1 +
 1 file changed, 1 insertion(+)
man2/mmap.2 +0 -0
index d0530be0f..9de6b2796 100644

man2/mmap.2 and is not a member of the · line 632

Quoted 4 lines
man2/mmap.2 +1 -0
@@ -629,6 +629,7 @@ and is not a member of the
 group; see the description of
 .I /proc/sys/vm/sysctl_hugetlb_shm_group
 in
+.BR proc (5).

Was this text accidentally lost in some patch, or was it never added? If it was there once, please add a "Fixes: ..." tag for it.

Also, proc(5) was recently cut into little sashimi pieces. You want to refer to proc_sys(5).

Cheers,
Alex

Quoted 3 lines
man2/mmap.2 +0 -0
 .TP
 .B ETXTBSY
 .B MAP_DENYWRITE
Signature · 2 lines
<http://www.alejandro-colomar.es/>
GPG key fingerprint: A9348594CE31283A826FBDD8D57633D441E25BB5
#2 lore raw

Hi Alex,

Quoted 15 lines · IST Alejandro Colomar

Hi Avinesh,

Quoted 12 lines · Avinesh Kumar

---

 man2/mmap.2 | 1 +
 1 file changed, 1 insertion(+)
man2/mmap.2 +0 -0
index d0530be0f..9de6b2796 100644
@@ -629,6 +629,7 @@ and is not a member of the
 
Quoted 8 lines

man2/mmap.2 and is not a member of the · line 632

Quoted 5 lines
man2/mmap.2 +1 -0
 group; see the description of
 .I /proc/sys/vm/sysctl_hugetlb_shm_group
 in
 
+.BR proc (5).

Was this text accidentally lost in some patch, or was it never added? If it was there once, please add a "Fixes: ..." tag for it.

I am not sure if it was ever there.

Quoted 3 lines

Also, proc(5) was recently cut into little sashimi pieces. You want to refer to proc_sys(5).

Ah.. Thanks for pointing this out, I just checked that thread. I'll send the updated patch if you are fine with no "Fixes:" tag for this.

Quoted 7 lines

Cheers,
Alex

Quoted 3 lines
man2/mmap.2 +0 -0
 .TP

.B ETXTBSY
.B MAP_DENYWRITE

--
Regards,
Avinesh

#3 lore raw

Hi Avinesh,

Quoted 3 lines · Avinesh Kumar
Quoted 2 lines

Was this text accidentally lost in some patch, or was it never added? If it was there once, please add a "Fixes: ..." tag for it.

I am not sure if it was ever there.

It was never there, it seems.

$ git show 090fdddb43 -- man2/mmap.2
commit 090fdddb4342f92a1dbeba687462f4bcee816232
Author: Michael Kerrisk <[email protected]>
Date:   Mon May 17 15:31:08 2021 +1200

memfd_create.2, mmap.2, shmget.2: Document the EPERM for huge page allocations

This error can occur if the caller is does not have CAP_IPC_LOCK and is not a member of the sysctl_hugetlb_shm_group.

man2/mmap.2 +12 -0
index 03f2eeb2c..4ee2f4f96 100644
@@ -628,6 +628,18 @@ .SH ERRORS
 The operation was prevented by a file seal; see
 .BR fcntl (2).
 .TP
+.B EPERM
+The
+.B MAP_HUGETLB
+flag was specified, but the caller was not privileged (did not have the
+.B CAP_IPC_LOCK
+capability)
+and is not a member of the
+.I sysctl_hugetlb_shm_group
+group; see the description of
+.I /proc/sys/vm/sysctl_hugetlb_shm_group
+in
+.TP
 .B ETXTBSY
 .B MAP_DENYWRITE
 was set but the object specified by
Quoted 5 lines
Quoted 3 lines

Also, proc(5) was recently cut into little sashimi pieces. You want to refer to proc_sys(5).

Ah.. Thanks for pointing this out, I just checked that thread. I'll send the updated patch if you are fine with no "Fixes:" tag for this.

Please add a Fixes mentioning that commit above.

Cheers,
Alex

Signature · 2 lines
<http://www.alejandro-colomar.es/>
GPG key fingerprint: A9348594CE31283A826FBDD8D57633D441E25BB5
#4 lore raw
Quoted 47 lines · Alejandro Colomar

Hi Avinesh,

Quoted 3 lines · Avinesh Kumar
Quoted 2 lines

Was this text accidentally lost in some patch, or was it never added? If it was there once, please add a "Fixes: ..." tag for it.

I am not sure if it was ever there.

It was never there, it seems.

$ git show 090fdddb43 -- man2/mmap.2
commit 090fdddb4342f92a1dbeba687462f4bcee816232
Author: Michael Kerrisk <[email protected]>
Date:   Mon May 17 15:31:08 2021 +1200

memfd_create.2, mmap.2, shmget.2: Document the EPERM for huge page allocations

This error can occur if the caller is does not have CAP_IPC_LOCK and is not a member of the sysctl_hugetlb_shm_group.

man2/mmap.2 +12 -0
index 03f2eeb2c..4ee2f4f96 100644
@@ -628,6 +628,18 @@ .SH ERRORS
 The operation was prevented by a file seal; see
 .BR fcntl (2).
 .TP
+.B EPERM
+The
+.B MAP_HUGETLB
+flag was specified, but the caller was not privileged (did not have the
+.B CAP_IPC_LOCK
+capability)
+and is not a member of the
+.I sysctl_hugetlb_shm_group
+group; see the description of
+.I /proc/sys/vm/sysctl_hugetlb_shm_group
+in
+.TP
 .B ETXTBSY
 .B MAP_DENYWRITE
 was set but the object specified by
Quoted 2 lines
Quoted 2 lines
Quoted 7 lines
Quoted 4 lines
Quoted 2 lines

Also, proc(5) was recently cut into little sashimi pieces. You want to refer to proc_sys(5).

Ah.. Thanks for pointing this out, I just checked that thread. I'll send the updated patch if you are fine with no "Fixes:" tag for this.

Please add a Fixes mentioning that commit above.

Never mind. I'll do it myself while applying.

Fixes 090fdddb4342 ("memfd_create.2, mmap.2, shmget.2: Document the EPERM for huge page allocations")
Quoted 4 lines

Cheers,
Alex

Signature · 2 lines
<http://www.alejandro-colomar.es/>
GPG key fingerprint: A9348594CE31283A826FBDD8D57633D441E25BB5
#5 lore raw
In reply to Alejandro Colomar

Hi Alex,

Quoted 9 lines · IST Alejandro Colomar

Hi Avinesh,

Quoted 4 lines · Avinesh Kumar
Quoted 2 lines

Was this text accidentally lost in some patch, or was it never added? If it was there once, please add a "Fixes: ..." tag for it.

I am not sure if it was ever there.

It was never there, it seems.

Thank you for digging and confirming this. I've send the v2 with "Fixes: ...".

Quoted 42 lines
$ git show 090fdddb43 -- man2/mmap.2
commit 090fdddb4342f92a1dbeba687462f4bcee816232
Author: Michael Kerrisk <[email protected]>
Date:   Mon May 17 15:31:08 2021 +1200

memfd_create.2, mmap.2, shmget.2: Document the EPERM for huge page
allocations

This error can occur if the caller is does not have CAP_IPC_LOCK and is not a member of the sysctl_hugetlb_shm_group.

man2/mmap.2 +12 -0
index 03f2eeb2c..4ee2f4f96 100644
@@ -628,6 +628,18 @@ .SH ERRORS
 The operation was prevented by a file seal; see
 .BR fcntl (2).
 .TP
+.B EPERM
+The
+.B MAP_HUGETLB
+flag was specified, but the caller was not privileged (did not have the
+.B CAP_IPC_LOCK
+capability)
+and is not a member of the
+.I sysctl_hugetlb_shm_group
+group; see the description of
+.I /proc/sys/vm/sysctl_hugetlb_shm_group
+in
+.TP
 .B ETXTBSY
 .B MAP_DENYWRITE
 was set but the object specified by
Quoted 4 lines
Quoted 3 lines

Also, proc(5) was recently cut into little sashimi pieces. You want to refer to proc_sys(5).

Quoted 7 lines
Quoted 2 lines

Ah.. Thanks for pointing this out, I just checked that thread. I'll send the updated patch if you are fine with no "Fixes:" tag for this.

Please add a Fixes mentioning that commit above.

Cheers,
Alex

--
Regards,
Avinesh